wok-6.x annotate cups/receipt @ rev 14951

Up: ethumb (1.7.8)
author Dominique Corbex <domcox@slitaz.org>
date Thu Aug 08 19:16:02 2013 +0200 (2013-08-08)
parents a6452de6a141
children 78cb1e930abd
rev   line source
pankso@632 1 # SliTaz package receipt.
pankso@632 2
pankso@632 3 PACKAGE="cups"
slaxemulator@14626 4 VERSION="1.6.2"
pankso@632 5 CATEGORY="system-tools"
pankso@632 6 SHORT_DESC="Common UNIX Printing System."
erjo@784 7 MAINTAINER="erjo@slitaz.org"
pankso@632 8 TARBALL="$PACKAGE-$VERSION-source.tar.bz2"
pankso@632 9 WEB_SITE="http://www.cups.org/"
slaxemulator@14626 10 WGET_URL="http://www.cups.org/software/$VERSION/$TARBALL"
jozee@4933 11 TAGS="printer printing"
pankso@632 12
slaxemulator@14621 13 DEPENDS="libssl slitaz-base-files libgcrypt gnutls dbus jpeg libpng tiff zlib \
slaxemulator@14621 14 libcomerr cups-doc libkrb5 libcomerr3 gcc-lib-base libusb-compat libtasn1 acl poppler-apps"
slaxemulator@14621 15 BUILD_DEPENDS="libgcrypt-dev gnutls-dev dbus-dev jpeg-dev libpng-dev \
slaxemulator@14621 16 tiff-dev zlib-dev libtasn1-dev openssl-dev libusb-compat-dev php-dev \
slaxemulator@14621 17 acl-dev poppler-apps"
slaxemulator@14621 18
pankso@632 19 # Rules to configure and make the package.
pankso@632 20 compile_rules()
pankso@632 21 {
pankso@632 22 cd $src
slaxemulator@14621 23 patch -Np1 -i $stuff/install-sh.u
pankso@632 24 ./configure \
pankso@664 25 --prefix=/usr \
pankso@664 26 --sysconfdir=/etc \
pankso@664 27 --localstatedir=/var \
pankso@664 28 --mandir=/usr/share/man \
pankso@2207 29 --enable-static \
pankso@2206 30 --disable-ldap \
pascal@2282 31 --disable-pam \
jozee@2761 32 --disable-gssapi \
jozee@4518 33 --disable-acl \
slaxemulator@6891 34 --disable-slp \
slaxemulator@6891 35 --enable-dbus \
slaxemulator@6891 36 --with-dbusdir=/etc/dbus-1 \
pankso@2206 37 --with-cups-user=nobody \
pankso@2206 38 --with-cups-group=nogroup \
pankso@2206 39 --with-languages="de es fr" \
pascal@11153 40 --with-pdftops=pdftops \
pascal@1660 41 $CONFIGURE_ARGS &&
pascal@1660 42 make &&
slaxemulator@14621 43 make BUILDROOT=$DESTDIR install
pankso@3601 44
pankso@632 45 }
pankso@632 46
pankso@632 47 # Rules to gen a SliTaz package suitable for Tazpkg.
pankso@632 48 genpkg_rules()
pankso@632 49 {
pascal@2565 50 mkdir -p $fs/etc $fs/usr/lib $fs/usr/share/pixmaps
pankso@3601 51
slaxemulator@14621 52 cp -a $install/etc/cups $fs/etc
slaxemulator@14621 53 cp -a $install/etc/dbus* $fs/etc
slaxemulator@14621 54 cp -a $install/usr/bin $fs/usr
slaxemulator@14621 55 cp -a $install/usr/sbin $fs/usr
slaxemulator@14621 56 cp -a $install/usr/lib/*.so* $fs/usr/lib
slaxemulator@14621 57 cp -a $install/usr/lib/cups $fs/usr/lib
slaxemulator@14621 58 cp -a $install/usr/share/cups $fs/usr/share
slaxemulator@14621 59 cp -a $install/usr/share/icons/hicolor/32x32/apps/cups.png $fs/usr/share/pixmaps
slaxemulator@14621 60 cp -a $install/var $fs
pankso@3601 61
jozee@2761 62 # tazwok does not strip files other than .so in usr/lib
pankso@3601 63
jozee@2761 64 for dir in $fs/usr/lib/cups
jozee@2761 65 do
jozee@2761 66 if [ -d "$dir" ]; then
jozee@2761 67 find $dir -type f -exec strip -s '{}' 2>/dev/null \;
jozee@2761 68 fi
jozee@2761 69 done
pankso@3601 70
pankso@632 71 # Daemon script
pankso@9697 72 cp -a $stuff/etc $fs
pascal@14906 73
pascal@14906 74 # Tazpanel link
pascal@14906 75 cp -a $stuff/var $fs
pankso@632 76 }
pankso@632 77
pankso@632 78 # Start cups daemon and edit daemons.conf.
pankso@632 79 post_install()
pankso@632 80 {
pankso@632 81 local root
pankso@632 82 root=$1
pascal@2219 83 if [ -z "$root" ]; then
pascal@2219 84 /etc/init.d/cupsd start || continue
pascal@2219 85 fi
pankso@632 86 if ! grep -q ^CUPSD_OPTIONS $root/etc/daemons.conf; then
pankso@632 87 echo '# Cups printing daemon options.' >> $root/etc/daemons.conf
pankso@632 88 echo 'CUPSD_OPTIONS=""' >> $root/etc/daemons.conf
pankso@632 89 echo '' >> $root/etc/daemons.conf
pankso@632 90 fi
pankso@632 91 }
pankso@632 92
pankso@632 93 # Stop cups daemon before rm.
pankso@632 94 pre_remove()
pankso@632 95 {
slaxemulator@14621 96 local root
slaxemulator@14621 97 root=$1
slaxemulator@14621 98 if [ -z "$root" ]; then
slaxemulator@14621 99 /etc/init.d/cupsd stop
slaxemulator@14621 100 fi
pankso@632 101 }
pascal@8875 102
pascal@8875 103 # Overlap busybox
pascal@8875 104 pre_install()
pascal@8875 105 {
pascal@8875 106 rm -f $1/usr/bin/lpr
pascal@8875 107 }
pascal@8875 108
pascal@8875 109 post_remove()
pascal@8875 110 {
slaxemulator@14621 111 ln -s /bin/busybox $1/usr/bin/lpr
pascal@8875 112 }