IGNOREPATH=/etc:/home:/var:/dev:/boot:/root:/tmp:/usr/local:/bin:/sbin:/mnt:/usr/src STRIPLIB=y STRIPBIN=y VERSION=1.1.19 PROGNAME="cups $VERSION" DESC="\ CUPS (Common UNIX Printing System) \n\ \n\ The Common UNIX Printing System provides a portable printing layer for \n\ UNIX(R)-like operating systems. It has been developed by Easy Software \n\ Products to promote a standard printing solution for all UNIX vendors \n\ and users. CUPS uses the Internet Printing Protocol ("IPP") as the \n\ basis for managing print jobs and queues. The CUPS package includes \n\ System V and Berkeley command-line interfaces, a PostScript RIP \n\ package for supporting non-PostScript printer drivers, and tools for \n\ creating additional printer drivers and other CUPS services." BUILD=1 MAINTAINER="Mark Post " SOURCE=ftp://ftp.gnu.org/pub/gnu/cups PKGNAME=cups-$VERSION-s390-$BUILD TAG=REC compile() { tar -yxvf $CWD/cups-$VERSION-source.tar.bz2 cd cups-$VERSION/ ./configure --disable-pam make } install() { mkdir -p /package-cups/etc/cups mkdir -p /package-cups/var/spool make BUILDROOT=/package-cups install mkdir -p /package-cups/usr/doc mv /package-cups/usr/share/doc/cups /package-cups/usr/doc/cups-$VERSION ( cd /package-cups/usr/doc ln -sf cups-$VERSION cups ) # For full CUPS SMB support, you'll need to install the cups-samba # package from the source in this directory. There's no easy way # to add that to a package build, and the requests aren't pouring in, # so you'll have to install it yourself. It's easy to do. # # However, this will get you the most useful SMB support for free. # Thanks to Boris Kurktchiev for the tip. :-) ( cd /package-cups/usr/lib/cups/backend if [ ! -r smb ]; then ln -sf /usr/bin/smbspool smb fi ) ( cd /package-cups/usr/share/man rm -rf cat? */cat? for dir in fr/man1 fr/man3 fr/man5/ fr/man8/ man1 man3 man5 man8; do ( cd $dir rm -f *.gz gzip -9 * ) done ) ( cd /package-cups/usr/share/man/fr/man1 rm -rf cancel.1 ; ln -sf lp.1.gz cancel-cups.1.gz ) ( cd /package-cups/usr/share/man/man1 rm -rf cancel.1 ; ln -sf lp.1.gz cancel-cups.1.gz ) ( cd /package-cups/usr/share/man/fr/man8 rm -rf disable.8 ; ln -sf enable.8.gz disable.8.gz rm -rf reject.8 ; ln -sf accept.8.gz reject.8.gz ) ( cd /package-cups/usr/share/man/man8 rm -rf disable.8 ; ln -sf enable.8.gz disable.8.gz rm -rf reject.8 ; ln -sf accept.8.gz reject.8.gz ) ( cd /package-cups/usr/share mv man .. ) # Adjust for BSD init scripts. Note that rc.cups will have to be # started from somewhere, like rc.M or rc.inet2. ( cd /package-cups/etc/rc.d mv init.d/cups rc.cups.new rm -r init.d rc?.d ) # Apply no-clobber fix to conffiles: ( cd /package-cups/etc/cups for file in * ; do if [ -f $file ]; then mv $file $file.new fi done ) # Use symlinks to certain binaries so that CUPS and LPRng can coexist: ( cd /package-cups for file in \ usr/bin/cancel \ usr/bin/lp \ usr/bin/lpq \ usr/bin/lpr \ usr/bin/lprm \ usr/bin/lpstat \ usr/sbin/lpc ; do ( mv ${file} ${file}-cups ( cd `dirname ${file}` ; ln -sf `basename ${file}`-cups `basename ${file}` ) ) done # Now fix the associated man pages: mv usr/man/fr/man1/lp.1.gz usr/man/fr/man1/lp-cups.1.gz mv usr/man/fr/man1/lpq.1.gz usr/man/fr/man1/lpq-cups.1.gz mv usr/man/fr/man1/lpr.1.gz usr/man/fr/man1/lpr-cups.1.gz mv usr/man/fr/man1/lprm.1.gz usr/man/fr/man1/lprm-cups.1.gz mv usr/man/fr/man1/lpstat.1.gz usr/man/fr/man1/lpstat-cups.1.gz mv usr/man/fr/man8/lpc.8.gz usr/man/fr/man8/lpc-cups.8.gz mv usr/man/man1/lp.1.gz usr/man/man1/lp-cups.1.gz mv usr/man/man1/lpq.1.gz usr/man/man1/lpq-cups.1.gz mv usr/man/man1/lpr.1.gz usr/man/man1/lpr-cups.1.gz mv usr/man/man1/lprm.1.gz usr/man/man1/lprm-cups.1.gz mv usr/man/man1/lpstat.1.gz usr/man/man1/lpstat-cups.1.gz mv usr/man/man8/lpc.8.gz usr/man/man8/lpc-cups.8.gz ( cd usr/man/fr/man1 ln -sf cancel-cups.1.gz cancel.1.gz ln -sf lp-cups.1.gz lp.1.gz ln -sf lpq-cups.1.gz lpq.1.gz ln -sf lpr-cups.1.gz lpr.1.gz ln -sf lprm-cups.1.gz lprm.1.gz ln -sf lpstat-cups.1.gz lpstat.1.gz ) ( cd usr/man/man1 ln -sf cancel-cups.1.gz cancel.1.gz ln -sf lp-cups.1.gz lp.1.gz ln -sf lpq-cups.1.gz lpq.1.gz ln -sf lpr-cups.1.gz lpr.1.gz ln -sf lprm-cups.1.gz lprm.1.gz ln -sf lpstat-cups.1.gz lpstat.1.gz ) ( cd usr/man/fr/man8 ln -sf lpc-cups.8.gz lpc.8.gz ) ( cd usr/man/man8 ln -sf lpc-cups.8.gz lpc.8.gz ) ) } attributes() { chown -R root.bin $PKG/package-cups/usr/bin/ \ $PKG/package-cups/usr/sbin/ chown lp.sys $PKG/package-cups/usr/bin/lppasswd chmod 644 $PKG/package-cups/etc/rc.d/rc.cups.new chmod 711 $PKG/package-cups/etc/cups/certs/ chmod 710 $PKG/package-cups/var/spool/cups/ chmod 1770 $PKG/package-cups/var/spool/cups/tmp/ } special() { cd $PKG mv package-cups/* ./ rmdir package-cups cd $CTL cat $CWD/slack-desc > slack-desc sed -e 's%package-cups/%%g' doinst.sh > doinst.sh.new cat doinst.sh.new > doinst.sh rm doinst.sh.new zcat $CWD/doinst.sh.gz >> doinst.sh }