wok view hal/receipt @ rev 4811

Up: claws-mail-attremover(1.0.11)
author Eric Joseph-Alexandre <erjo@slitaz.org>
date Tue Jan 19 01:07:01 2010 +0100 (2010-01-19)
parents e72891b14efd
children a75cf5dd7f62
line source
1 # SliTaz package receipt.
3 PACKAGE="hal"
4 VERSION="0.5.13"
5 CATEGORY="x-window"
6 SHORT_DESC="Hardware Abstraction Layer."
7 DEPENDS="dbus dbus-glib slitaz-base-files udev util-linux-ng-blkid"
8 BUILD_DEPENDS="dbus-dev dbus-glib-dev udev-dev udev pciutils util-linux-ng-blkid-dev expat-dev"
9 MAINTAINER="pankso@slitaz.org"
10 TARBALL="$PACKAGE-$VERSION.tar.gz"
11 WEB_SITE="http://www.freedesktop.org/wiki/Software/hal"
12 WGET_URL="http://hal.freedesktop.org/releases/$TARBALL"
14 EXTRA="
15 hald-addon-cpufreq
16 hald-addon-hid-ups
17 hald-addon-imac-backlight
18 hald-addon-ipw-killswitch
19 hald-probe-video4linux
20 hald-probe-net-bluetooth
21 hald-probe-ieee1394-unit
22 hald-probe-pc-floppy
23 hald-probe-printer"
25 # Rules to configure and make the package.
26 compile_rules()
27 {
28 cd $src
29 zcat /usr/share/misc/pci.ids.gz > /usr/share/misc/pci.ids &&
30 #patch -p1 < ../stuff/hal-udev.patch || exit 1 &&
31 ./configure \
32 --prefix=/usr \
33 --libexecdir=/usr/lib/hal \
34 --sysconfdir=/etc \
35 --localstatedir=/var \
36 --mandir=/usr/share/man \
37 --disable-usb-ids \
38 --disable-policy-kit \
39 $CONFIGURE_ARGS &&
40 make &&
41 rm /usr/share/misc/pci.ids &&
42 make DESTDIR=$PWD/_pkg install
43 }
45 # Rules to gen a SliTaz package suitable for Tazpkg.
46 genpkg_rules()
47 {
48 mkdir -p $fs/usr/lib $fs/usr/share
49 cp -a $_pkg/etc $fs
50 cp -a $_pkg/var $fs
51 cp -a $_pkg/usr/bin $fs/usr
52 cp -a $_pkg/usr/sbin $fs/usr
53 cp -a $_pkg/usr/lib/*.so* $fs/usr/lib
54 cp -a $_pkg/usr/lib/hal $fs/usr/lib
55 cp -a $_pkg/usr/share/hal $fs/usr/share
56 chmod -R +x $fs/usr/lib/hal/scripts/*
57 # Remove a few run time lib and strip.
58 for lib in $EXTRA
59 do
60 rm $fs/usr/lib/hal/$lib
61 done
62 strip -s $fs/usr/lib/hal/* 2>/dev/null
63 # Init script
64 cp -a stuff/etc $fs
66 # Policy for ntfs-3g
67 cp -a stuff/policy $fs/usr/share/hal/fdi/
68 chown -R root.root $fs
70 # exclude unwanted fdi files
71 rm $fs/usr/share/hal/fdi/policy/10osvendor/10-cpufreq.fdi
72 rm $fs/usr/share/hal/fdi/policy/10osvendor/10-dockstation.fdi
73 rm $fs/usr/share/hal/fdi/policy/10osvendor/10-imac-backlight.fdi
74 rm $fs/usr/share/hal/fdi/policy/10osvendor/15-storage-luks.fdi
75 rm $fs/usr/share/hal/fdi/policy/10osvendor/30-wol.fdi
76 }
78 pre_install()
79 {
80 local root
81 root=$1
82 # Go for echoing on configuration files if any haldeamon user
83 # was found.
84 if ! grep -q 'haldaemon' $root/etc/passwd; then
85 echo -n "Adding user: messagebus..."
86 echo 'haldaemon:x:26:26:HAL Daemon User:/dev/null:/bin/false' >> $root/etc/passwd
87 echo 'haldaemon:!:14013:0:99999:7:::' >> $root/etc/shadow
88 echo 'haldaemon:x:26:' >> $root/etc/group
89 echo 'haldaemon:!::' >> $root/etc/gshadow
90 status
91 fi
92 if ! grep -q ^HALD_OPTIONS $root/etc/daemons.conf; then
93 echo -n "Configuring $root/etc/daemons.conf..."
94 cat >> $root/etc/daemons.conf << "EOT"
95 # HAL daemon options.
96 HALD_OPTIONS="--daemon=yes"
98 EOT
99 status
100 fi
101 }
103 pre_remove()
104 {
105 /etc/init.d/hald stop
106 deluser haldaemon
107 }