wok-next view cups/receipt @ rev 18716
cups, cups-pam: remove duplicate files with libcups; misc. edits.
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Thu Dec 17 05:25:15 2015 +0200 (2015-12-17) |
parents | feb2e0c63d21 |
children | ce8561c19cb9 |
line source
1 # SliTaz package receipt.
3 PACKAGE="cups"
4 VERSION="2.0.2"
5 CATEGORY="system-tools"
6 SHORT_DESC="Common UNIX Printing System."
7 MAINTAINER="erjo@slitaz.org"
8 LICENSE="GPL2 LGPL2"
9 TARBALL="$PACKAGE-$VERSION-source.tar.bz2"
10 WEB_SITE="http://www.cups.org/"
11 WGET_URL="http://www.cups.org/software/$VERSION/$TARBALL"
12 TAGS="printer printing"
14 DEPENDS="cups-filters libcups"
15 BUILD_DEPENDS="libgcrypt-dev gnutls-dev dbus-dev jpeg-dev libpng-dev \
16 tiff-dev zlib-dev libtasn1-dev openssl-dev libusb-compat-dev php-dev \
17 acl-dev poppler-apps"
19 # Rules to configure and make the package.
20 compile_rules()
21 {
22 patch -Np1 -i $stuff/install-sh.u
23 ./configure \
24 --prefix=/usr \
25 --sysconfdir=/etc \
26 --localstatedir=/var \
27 --mandir=/usr/share/man \
28 --enable-static \
29 --disable-ldap \
30 --disable-pam \
31 --disable-gssapi \
32 --disable-acl \
33 --disable-slp \
34 --enable-dbus \
35 --with-dbusdir=/etc/dbus-1 \
36 --with-cups-user=nobody \
37 --with-cups-group=nogroup \
38 --with-languages="de es fr pt_BR ru" \
39 --with-pdftops=pdftops \
40 $CONFIGURE_ARGS &&
41 make &&
42 make BUILDROOT=$DESTDIR install
43 cp -f $stuff/cups.desktop $install/usr/share/applications/cups.desktop
44 }
46 # Rules to gen a SliTaz package suitable for Tazpkg.
47 genpkg_rules()
48 {
49 mkdir -p $fs/etc $fs/usr/lib $fs/usr/share
51 cp -a $install/etc/cups $fs/etc
52 cp -a $install/etc/dbus* $fs/etc
53 cp -a $install/usr/bin $fs/usr
54 cp -a $install/usr/sbin $fs/usr
55 cp -a $install/usr/lib/*.so* $fs/usr/lib
56 cp -a $install/usr/lib/cups $fs/usr/lib
57 cp -a $install/usr/share/cups $fs/usr/share
58 cp -a $install/usr/share/icons $fs/usr/share
59 cp -a $install/var $fs
61 # Remove files provided by cups-filters
62 rm -f $fs/usr/share/cups/banners/*
63 rm -f $fs/usr/share/cups/data/testprint
65 # Remove files provided by libcups
66 rm -f $fs/usr/lib/libcups.so*
68 # Daemon script
69 cp -a $stuff/etc $fs
71 # TazPanel link
72 cp -a $stuff/var $fs
73 }
75 post_install()
76 {
77 # Start CUPS daemon and edit daemons.conf
78 if [ -z "$1" -a ! -s /aufs-umount.sh ]; then
79 /etc/init.d/cupsd start || continue
80 fi
81 if ! grep -q ^CUPSD_OPTIONS "$1/etc/daemons.conf"; then
82 cat >> "$1/etc/daemons.conf" <<EOT
83 # CUPS printing daemon options.
84 CUPSD_OPTIONS=""
86 EOT
87 fi
88 }
90 pre_remove()
91 {
92 # Stop CUPS daemon before rm.
93 [ -z "$1" -a -x /etc/init.d/cupsd ] && /etc/init.d/cupsd stop
94 :
95 }
97 post_remove()
98 {
99 ln -s /bin/busybox "$1/usr/bin/lpr"
100 }