wok-next view sane-backends/receipt @ rev 9780

clex: update to fix WGET_URL (my favorite text mode fm)
author Christophe Lincoln <pankso@slitaz.org>
date Wed May 11 23:06:47 2011 +0200 (2011-05-11)
parents 12dc00e8fec9
children 4d40b2bc1125
line source
1 # SliTaz package receipt.
3 PACKAGE="sane-backends"
4 VERSION="1.0.22"
5 CATEGORY="system-tools"
6 SHORT_DESC="Scanner Access Now Easy."
7 MAINTAINER="pankso@slitaz.org"
8 DEPENDS="libusb-compat jpeg tiff zlib libgphoto2 libv4l libtool"
9 TARBALL="$PACKAGE-$VERSION.tar.gz"
10 WEB_SITE="http://www.sane-project.org/"
11 WGET_URL="ftp://ftp.sane-project.org/pub/sane/$PACKAGE-$VERSION/$TARBALL"
13 # Rules to configure and make the package.
14 compile_rules()
15 {
16 cd $src
17 ./configure \
18 --prefix=/usr \
19 --sysconfdir=/etc \
20 --mandir=/usr/share/man \
21 $CONFIGURE_ARGS &&
22 make &&
23 make -j 1 DESTDIR=$PWD/_pkg install
25 # copy the missing udev rule
26 [ ! -d $PWD/_pkg/etc/udev/rules.d ] && mkdir -p $PWD/_pkg/etc/udev/rules.d
27 cp -a $src/tools/udev/libsane.rules $PWD/_pkg/etc/udev/rules.d/55-sane.rules
28 }
30 # Rules to gen a SliTaz package suitable for Tazpkg.
31 genpkg_rules()
32 {
33 mkdir -p $fs/usr/lib $fs/usr/share \
34 $fs/var/lock/sane $fs/etc/sane.d
36 cp -a $_pkg/etc/sane.d $fs/etc
37 cp -a $_pkg/usr/bin $fs/usr
38 cp -a $_pkg/usr/sbin $fs/usr
39 cp -a $_pkg/usr/lib/*.so* $fs/usr/lib
40 cp -a $_pkg/usr/lib/sane $fs/usr/lib
41 cp -a $_pkg/usr/share/sane $fs/usr/share
43 # fix groups/permissions on /var/lock/sane ; add it to scanner group
44 chmod 775 "$fs/var/lock/sane"
45 chgrp 96 "$fs/var/lock/sane"
47 # fix hp officejets
48 echo "hpaio" >> "$fs/etc/sane.d/dll.conf"
49 }
51 post_install()
52 {
53 local root
54 root=$1
56 tazpkg reconfigure udev --root=$1
58 # add group scanner
59 if ! grep -q scanner $root/etc/group ; then
60 addgroup -g 96 scanner
61 fi
63 echo " ADD yourself to group scanner to use sane: addgroup tux scanner"
64 }
66 post_remove()
67 {
68 delgroup scanner & >/dev/null
69 }