wok-current diff hal/receipt @ rev 792
Add hal - Hardware Abstraction Layer
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Thu May 15 20:48:24 2008 +0200 (2008-05-15) |
parents | |
children | f18e16373f51 |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/hal/receipt Thu May 15 20:48:24 2008 +0200 1.3 @@ -0,0 +1,95 @@ 1.4 +# SliTaz package receipt. 1.5 + 1.6 +PACKAGE="hal" 1.7 +VERSION="0.5.11" 1.8 +CATEGORY="x-window" 1.9 +SHORT_DESC="Hardware Abstraction Layer." 1.10 +DEPENDS="dbus dbus-glib" 1.11 +BUILD_DEPENDS="dbus-dev dbus-glib-dev" 1.12 +MAINTAINER="pankso@slitaz.org" 1.13 +TARBALL="$PACKAGE-$VERSION.tar.gz" 1.14 +WEB_SITE="http://www.freedesktop.org/wiki/Software/hal" 1.15 +WGET_URL="http://hal.freedesktop.org/releases/$TARBALL" 1.16 + 1.17 +EXTRA=" 1.18 +hald-addon-cpufreq 1.19 +hald-addon-hid-ups 1.20 +hald-addon-imac-backlight 1.21 +hald-probe-video4linux 1.22 +hald-probe-net-bluetooth 1.23 +hald-probe-ieee1394-unit 1.24 +hald-probe-pc-floppy 1.25 +hald-probe-printer 1.26 +hal-ipw-killswitch-linux" 1.27 + 1.28 +# Rules to configure and make the package. 1.29 +compile_rules() 1.30 +{ 1.31 + cd $src 1.32 + ./configure \ 1.33 + --prefix=/usr \ 1.34 + --libexecdir=/usr/lib/hal \ 1.35 + --sysconfdir=/etc \ 1.36 + --localstatedir=/var \ 1.37 + --mandir=/usr/share/man \ 1.38 + --disable-usb-ids \ 1.39 + --disable-policy-kit \ 1.40 + $CONFIGURE_ARGS 1.41 + make 1.42 + make DESTDIR=$PWD/_pkg install 1.43 +} 1.44 + 1.45 +# Rules to gen a SliTaz package suitable for Tazpkg. 1.46 +genpkg_rules() 1.47 +{ 1.48 + mkdir -p $fs/usr/lib $fs/usr/share 1.49 + cp -a $_pkg/etc $fs 1.50 + cp -a $_pkg/var $fs 1.51 + cp -a $_pkg/usr/bin $fs/usr 1.52 + cp -a $_pkg/usr/sbin $fs/usr 1.53 + cp -a $_pkg/usr/lib/*.so* $fs/usr/lib 1.54 + cp -a $_pkg/usr/lib/hal $fs/usr/lib 1.55 + cp -a $_pkg/usr/share/hal $fs/usr/share 1.56 + chmod -R +x $fs/usr/lib/hal/scripts/* 1.57 + 1.58 + # Remove a few run time lib. 1.59 + for lib in $EXTRA 1.60 + do 1.61 + rm $fs/usr/lib/hal/$lib 1.62 + done 1.63 + 1.64 + # Init script 1.65 + cp -a stuff/etc $fs 1.66 + chown -R root.root $fs 1.67 +} 1.68 + 1.69 +pre_install() 1.70 +{ 1.71 + local root 1.72 + root=$1 1.73 + # Go for echoing on configuration files if any haldeamon user 1.74 + # was found. 1.75 + if ! grep -q 'messagebus' $root/etc/passwd; then 1.76 + echo -n "Adding user: messagebus..." 1.77 + echo 'haldaemon:x:26:26:HAL Daemon User:/dev/null:/bin/false' >> $root/etc/passwd 1.78 + echo 'haldaemon:!:14013:0:99999:7:::' >> $root/etc/shadow 1.79 + echo 'haldaemon:x:26:' >> $root/etc/group 1.80 + echo 'haldaemon:!::' >> $root/etc/gshadow 1.81 + status 1.82 + fi 1.83 + if ! grep -q ^HALD_OPTIONS $root/etc/daemons.conf; then 1.84 + echo -n "Configuring $root/etc/daemons.conf..." 1.85 + cat >> $root/etc/daemons.conf << "EOT" 1.86 +# HAL daemon options. 1.87 +HALD_OPTIONS="--daemon=yes" 1.88 + 1.89 +EOT 1.90 + status 1.91 + fi 1.92 +} 1.93 + 1.94 +pre_remove() 1.95 +{ 1.96 + /etc/init.d/hald stop 1.97 + deluser haldaemon 1.98 +}