wok view cups/receipt @ rev 23924

webgames: update checkers
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sat Aug 22 19:44:06 2020 +0000 (2020-08-22)
parents 091670bbc959
children 5ea0ce1cecc0
line source
1 # SliTaz package receipt.
3 PACKAGE="cups"
4 VERSION="2.3.1"
5 CATEGORY="system-tools"
6 TAGS="printer printing"
7 SHORT_DESC="Common UNIX Printing System."
8 MAINTAINER="erjo@slitaz.org"
9 LICENSE="GPL2 LGPL2"
10 WEB_SITE="https://www.cups.org/"
12 TARBALL="$PACKAGE-$VERSION-source.tar.gz"
13 WGET_URL="https://github.com/apple/$PACKAGE/releases/download/v$VERSION/$TARBALL"
15 DEPENDS="cups-doc cups-filters dbus libcomerr libcups libkrb5 libssl
16 libunistring libusb-compat poppler-apps"
17 BUILD_DEPENDS="acl-dev dbus-dev gnutls-dev jpeg-dev libgcrypt-dev
18 libgnutls libpng-dev libtasn1-dev libunistring-dev libusb-compat-dev
19 openssl-dev php-dev poppler-apps tiff-dev zlib-dev"
21 # Rules to configure and make the package.
22 compile_rules()
23 {
24 # patch -Np1 -i $stuff/install-sh.u
26 export LDFLAGS="$LDFLAGS -lrt"
28 # Set list of wanted locales in LOCALE_PACK
29 . $WOK/slitaz-i18n/stuff/locale-pack.conf
31 # <= 2.0.2 unrecognised
32 # --disable-ldap
33 # --disable-slp
34 # --with-pdftops=pdftops
36 ./configure \
37 --prefix=/usr \
38 --sysconfdir=/etc \
39 --localstatedir=/var \
40 --mandir=/usr/share/man \
41 --enable-static \
42 --disable-pam \
43 --disable-gssapi \
44 --disable-acl \
45 --enable-dbus \
46 --with-dbusdir=/etc/dbus-1 \
47 --with-cups-user=nobody \
48 --with-cups-group=nogroup \
49 --with-languages="$LOCALE_PACK" \
50 $CONFIGURE_ARGS &&
51 make &&
52 make BUILDROOT=$DESTDIR install
54 cp -f $stuff/cups.desktop \
55 $install/usr/share/applications/cups.desktop
56 }
58 # Rules to gen a SliTaz package suitable for Tazpkg.
59 genpkg_rules()
60 {
61 mkdir -p $fs/etc
62 mkdir -p $fs/usr/lib
63 mkdir -p $fs/usr/share
65 cp -a $install/etc/cups $fs/etc
66 cp -a $install/etc/dbus* $fs/etc
67 cp -a $install/usr/bin $fs/usr
68 cp -a $install/usr/sbin $fs/usr
69 cp -a $install/usr/lib/*.so* $fs/usr/lib
70 cp -a $install/usr/lib/cups $fs/usr/lib
71 cp -a $install/usr/share/cups $fs/usr/share
72 cp -a $install/usr/share/icons $fs/usr/share
73 cp -a $install/var $fs
75 # Remove files provided by cups-filters
76 rm -f $fs/usr/share/cups/banners/*
77 rm -f $fs/usr/share/cups/data/testprint
79 # Remove files provided by libcups
80 rm -f $fs/usr/lib/libcups.so*
82 # Daemon script
83 cp -a $stuff/etc $fs
84 sed -i 's|^#Group .*|Group lp|' $fs/etc/cups/cups-files.conf
86 # TazPanel link
87 cp -a $stuff/var $fs
89 sed -i 's|hostname:9100|&\n\n parallel:/dev/usb/lp0|' \
90 $fs/usr/share/cups/templates/choose-uri.tmpl
91 }
93 post_install()
94 {
95 # Start CUPS daemon and edit daemons.conf
96 if [ -z "$1" -a ! -s /aufs-umount.sh ]
97 then
98 /etc/init.d/cupsd start || continue
99 fi
100 rm -f "$1"/var/cache/tazpanel/* 2> /dev/null
101 if ! grep -q ^CUPSD_OPTIONS "$1/etc/daemons.conf"
102 then
103 cat >> "$1/etc/daemons.conf" <<EOT
104 # CUPS printing daemon options.
105 CUPSD_OPTIONS=""
107 EOT
108 fi
109 }
111 pre_remove()
112 {
113 # Stop CUPS daemon before remove.
114 [ -z "$1" -a -x /etc/init.d/cupsd ] && /etc/init.d/cupsd stop
115 :
116 }
118 post_remove()
119 {
120 ln -fs /bin/busybox "$1/usr/bin/lpr"
121 }