wok view foomatic-db-nonfree/receipt @ rev 7217

Up: libfm
author Rohit Joshi <jozee@slitaz.org>
date Wed Nov 10 21:35:12 2010 -0500 (2010-11-10)
parents 2a1979cb49a1
children fb920af78bef
line source
1 # SliTaz package receipt.
3 PACKAGE="foomatic-db-nonfree"
4 VERSION="current"
5 CATEGORY="system-tools"
6 SHORT_DESC="database engine generates PPD files from the data in Foomatic's XML database"
7 MAINTAINER="jozee@slitaz.org"
8 DEPENDS="perl libxml2 foomatic-db"
9 BUILD_DEPENDS="ghostscript-dev cups-dev perl libxml2-dev"
10 TARBALL="$PACKAGE-$VERSION.tar.gz"
11 WEB_SITE="http://www.linuxprinting.org/foomatic.html"
12 WGET_URL="http://www.openprinting.org/download/foomatic/$TARBALL"
13 TAGS="printer driver printing"
15 # Rules to configure and make the package.
16 compile_rules()
17 {
18 mv $WOK/$PACKAGE/$PACKAGE* $WOK/$PACKAGE/$PACKAGE-$VERSION
19 cd $src
20 ./configure \
21 --prefix=/usr \
22 --sysconfdir=/etc \
23 $CONFIGURE_ARGS &&
24 make &&
25 make DESTDIR=$PWD/_pkg install
27 }
29 # Rules to gen a SliTaz package suitable for Tazpkg.
30 genpkg_rules()
31 {
32 mkdir -p $fs/usr/share/licenses/$PACKAGE/
33 cp -a $_pkg/usr/share/foomatic $fs/usr/share
35 # gzip all ppd files
36 find $fs/usr/share/foomatic/db/source -name "*.ppd" | xargs gzip -n9
38 # include non-free license
39 cp -a $src/COPYING $fs/usr/share/licenses/$PACKAGE/
41 }
43 pre_install()
44 {
45 echo ""
46 echo -e "\033[1m PROPRIETARY LICENSE:\033[0m $2"
47 echo "================================================================================"
48 echo "You are installing a package with proprietary license."
49 echo "You must accept the license."
50 echo "================================================================================"
51 echo ""
53 }
55 post_install()
56 {
57 echo ""
58 echo -e "\033[1m FOOMATIC NON-FREE PRINTING LICENSE INFORMATION:\033[0m $2"
59 echo "================================================================================"
60 echo "For installing this package, you have to accept the $PACKAGE license."
61 echo "The license is stored in /usr/share/licenses/$PACKAGE "
62 echo -n "Would you like to read the license (y/N) : "; read anser
63 if [ "$anser" = "y" ]; then
64 cat /usr/share/licenses/"$PACKAGE"/COPYING | more
65 echo ""
66 fi
67 echo "================================================================================"
68 echo -n "Do you accept the license (y/N) : "; read anser
69 if [ "$anser" = "N" ]; then
70 echo "You did not accept the license, Removing the pkg."
71 tazpkg remove "$PACKAGE"
72 fi
74 }