]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Here are Gerben Wierda's files for installation and package
authorwessels <>
Tue, 6 Mar 2001 04:21:23 +0000 (04:21 +0000)
committerwessels <>
Tue, 6 Mar 2001 04:21:23 +0000 (04:21 +0000)
maintenance on Nextstep.

contrib/nextstep/Makefile
contrib/nextstep/Makefile.real
contrib/nextstep/README
contrib/nextstep/Squid.pkg.README
contrib/nextstep/info.in
contrib/nextstep/makepkg
contrib/nextstep/post_install
contrib/nextstep/pre_install

index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..cad56b41a428f3eefba9bcf317fd1f766c5f330b 100644 (file)
@@ -0,0 +1,14 @@
+VERSION=`pwd | sed 's"/contrib/nextstep""' | sed 's/.*-//'`
+ARCHS=`grep 's%@host_cpu@%' ../../config.status | sed "s/s%@host_cpu@%\([nihs]*\)%g/\1/g" | tr a-z A-Z`
+
+pkg:
+       ${MAKE} -f Makefile.real ARCHS=${ARCHS} VERSION=${VERSION} pkg
+
+tar:
+       ${MAKE} -f Makefile.real ARCHS=${ARCHS} VERSION=${VERSION} tar
+
+clean:
+       ${MAKE} -f Makefile.real ARCHS=${ARCHS} VERSION=${VERSION} clean
+
+echo:
+       ${MAKE} -f Makefile.real ARCHS=${ARCHS} VERSION=${VERSION} echo
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..a18b7e5376096e1a9385238b8e3f19323d56a45c 100644 (file)
@@ -0,0 +1,24 @@
+.SUFFIXES: .pkg .tar .info
+
+PRG=Squid
+TIMESTAMP=.pkg_made
+PKGNAME=${PRG}.pkg
+TARNAME=${PRG}-${VERSION}.${ARCHS}.tar.gz
+
+${TIMESTAMP}: /usr/local/squid/bin/squid Squid.pkg.README info.in post_install \
+       pre_install makepkg Makefile.real
+       ./makepkg
+       touch ${TIMESTAMP}
+
+${TARNAME}: ${TIMESTAMP}
+       gnutar zcvf ${TARNAME} ${PKGNAME} ${PRG}-${VERSION}.README
+
+tar: ${TARNAME}
+
+pkg: ${TIMESTAMP}
+
+clean:
+       rm -rf ${PKGNAME} ${TARNAME} ${PRG}-${VERSION}.README ${TIMESTAMP}
+
+echo:
+       echo ${PKGNAME}
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..1559271466de18c2ce1c92a61ed49a8c730a2658 100644 (file)
@@ -0,0 +1,7 @@
+First run 'make install' from directory ../.. Make sure you compile fat.
+
+
+Then run './makepkg' from this directory. This uses the just installed fat
+binaries in a package. And creates a help file.
+
+Or better: after running make install in ../.. run make tar in this directory.
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..a6df6fcc0bab4c777ba7489263c9a4abe6e9560d 100644 (file)
@@ -0,0 +1,21 @@
+This installer package contains the Squid internet cache for OPENSTEP. It has
+been compiled for m68k and i486.
+
+The following has not been checked for Squid 2:
+
+Currently, the Run* scripts in /usr/local/squid/bin do not work because they
+assume a non-standard date program. If you want them to work, compile and
+install the following program as /usr/local/squid/bin/epoch:
+
+#include <stdio.h>
+
+main()
+{
+    long t = time();
+    printf( "%ul\n", t);
+}
+
+And change the "date '+%d%H%M%S'" invocations in the Run* scripts to
+/usr/local/squid/bin/epoch
+
+Gerben Wierda
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..eab41343a32d8ba7f2207642b3ed2ec76b421e1e 100644 (file)
@@ -0,0 +1,7 @@
+Title          Squid - Internet Object cache
+Version                --VERSION-- (--DATE--)
+Description    This package contains all executables, support files and documentation  necessary to run Squid. NOTE: this package should be installed as "root".
+DefaultLocation        /
+Relocatable    NO
+DisableStop    YES
+DiskName       Squid
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..a5cc3f5e612e61f24580aa602585386b92b29069 100644 (file)
@@ -0,0 +1,60 @@
+#!/bin/sh
+# /bin/cp because GNU cp is installed sometimes and has different syntax
+# This file has been changed for Squid 2
+
+failed()
+{
+       # show failed message and exit
+       echo "FAILED ($*)"
+       exit 1
+}
+
+#      check if caller runs as super user:
+[ `/usr/ucb/whoami` = root ] || failed "must be super user"
+
+PRG=Squid
+SRCDIR=`cd ../..;pwd`
+REL=`basename $SRCDIR | sed 's/.*-//'`
+
+# Make info file from info.in:
+cat info.in | sed "s/--VERSION--/$REL/" | sed "s/--DATE--/`date`/" >info
+
+TMPDIR=/tmp/${PRG}
+# Cleanup previous package creation
+rm -rf ${TMPDIR}
+rm -rf ${PRG}.pkg
+
+# Create pre- and post-install scripts for the package, make sure these
+# are executable
+for f in post_install pre_install
+do
+       /bin/cp -p ${f} ${PRG}.${f}
+       chmod 755 ${PRG}.${f}
+done
+/bin/cp -p info ${PRG}.info
+chmod 644 ${PRG}.info
+
+mkdirs ${TMPDIR}/usr/local/squid/etc ${TMPDIR}/usr/local/squid/logs
+/bin/cp -pr /usr/local/squid/bin ${TMPDIR}/usr/local/squid
+/bin/cp -pr /usr/local/squid/etc/squid.conf.default ${TMPDIR}/usr/local/squid/etc
+# SQUID 2 (comment out if Squid 1)
+/bin/cp -pr /usr/local/squid/etc/mime.conf.default ${TMPDIR}/usr/local/squid/etc
+/bin/cp -pr /usr/local/squid/etc/icons ${TMPDIR}/usr/local/squid/etc
+/bin/cp -pr /usr/local/squid/etc/errors ${TMPDIR}/usr/local/squid/etc
+# END SQUID 2
+strip ${TMPDIR}/usr/local/squid/bin/*
+# It turns out that the Run* scripts are sometimes not executable
+chmod 755 ${TMPDIR}/usr/local/squid/bin/*
+/etc/chown -R nobody.other ${TMPDIR}/usr/local/squid
+
+/NextAdmin/Installer.app/package /tmp/${PRG} ${PRG}.info
+/bin/cp ${PRG}.pre_install ${PRG}.pkg
+/bin/cp ${PRG}.post_install ${PRG}.pkg
+/bin/cp -p Squid.pkg.README ${PRG}-${REL}.README
+
+# Cleanup:
+for f in post_install pre_install info
+do
+       rm ${PRG}.${f}
+done
+rm info
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..f0aab8549fcdac4068ce7e279917db192fc45cd5 100644 (file)
@@ -0,0 +1,43 @@
+#!/bin/sh
+
+PATH=
+
+PKG="$1"
+DST="$2"
+
+PKGNAME=`/usr/bin/basename $1`
+
+USAGE="Usage: $PKGNAME.post_install package_path [install_path]"
+
+trap 'echo "FAILED (interrupted by signal)"; exit 1' 1 2 3 4 15
+
+BEGINDATE=`/bin/date`
+#FDATE=`echo $BEGINDATE | /bin/awk '{print $2 "_" $3 "_" $7 "_" $4}'`
+echo $PKGNAME post-installation script starts at $BEGINDATE
+
+failed()
+{
+       # show failed message and exit
+       echo "FAILED ($*)"
+       exit 1
+}
+
+echo
+
+echo "Removing the Installer remains of possible other Squid installations... "
+cd /NextLibrary/Receipts
+/bin/rm -rf Squid-*.pkg
+
+/etc/chown -R nobody.other /usr/local/squid || failed "can't chown $1!"
+/etc/chown root.wheel /usr/local/squid/bin/pinger  || failed "can't chown $1!"
+/bin/chmod 4755 /usr/local/squid/bin/pinger  || failed "can't chmod $1!"
+
+if [ -e/usr/local/squid/etc/mime.conf ]
+then
+       echo "Already have mime.conf"
+else
+       echo "Installing default mime.conf"
+       (cd /usr/local/squid/etc; /bin/cp -p mime.conf.default mime.conf)
+fi
+
+echo "(done)"
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..1b898e612edad7add36023da53d1214b0940511f 100644 (file)
@@ -0,0 +1,29 @@
+#!/bin/sh
+
+PATH=
+
+PKG="$1"
+DST="$2"
+
+PKGNAME=`/usr/bin/basename $1`
+
+USAGE="Usage: $PKGNAME.pre_install package_path [install_path]"
+
+trap 'echo "FAILED (interrupted by signal)"; exit 1' 1 2 3 4 15
+
+BEGINDATE=`/bin/date`
+#FDATE=`echo $BEGINDATE | /bin/awk '{print $2 "_" $3 "_" $7 "_" $4}'`
+echo
+echo $PKGNAME pre-installation script starts at $BEGINDATE
+
+failed()
+{
+       # show failed message and exit
+       echo "FAILED ($*)"
+       exit 1
+}
+
+echo
+
+#      check if caller runs as super user:
+[ `/usr/ucb/whoami` = root ] || failed "must be super user"