wok-6.x annotate dbus/receipt @ rev 790
Add dbus message BUS from Freedesktop
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Thu May 15 20:46:50 2008 +0200 (2008-05-15) |
parents | |
children | 050151a9f32f |
rev | line source |
---|---|
pankso@790 | 1 # SliTaz package receipt. |
pankso@790 | 2 |
pankso@790 | 3 PACKAGE="dbus" |
pankso@790 | 4 VERSION="1.2.1" |
pankso@790 | 5 CATEGORY="x-window" |
pankso@790 | 6 SHORT_DESC="D-Bus is a message bus system." |
pankso@790 | 7 DEPENDS="expat xorg-libX11" |
pankso@790 | 8 BUILD_DEPENDS="xorg-libX11-dev" |
pankso@790 | 9 MAINTAINER="pankso@slitaz.org" |
pankso@790 | 10 TARBALL="$PACKAGE-$VERSION.tar.gz" |
pankso@790 | 11 WEB_SITE="http://www.freedesktop.org/wiki/Software/dbus" |
pankso@790 | 12 WGET_URL="http://dbus.freedesktop.org/releases/dbus/$TARBALL" |
pankso@790 | 13 |
pankso@790 | 14 # Rules to configure and make the package. |
pankso@790 | 15 compile_rules() |
pankso@790 | 16 { |
pankso@790 | 17 cd $src |
pankso@790 | 18 ./configure \ |
pankso@790 | 19 --prefix=/usr \ |
pankso@790 | 20 --libexecdir=/usr/lib/dbus \ |
pankso@790 | 21 --sysconfdir=/etc \ |
pankso@790 | 22 --localstatedir=/var \ |
pankso@790 | 23 --mandir=/usr/share/man \ |
pankso@790 | 24 $CONFIGURE_ARGS |
pankso@790 | 25 make |
pankso@790 | 26 make DESTDIR=$PWD/_pkg install |
pankso@790 | 27 } |
pankso@790 | 28 |
pankso@790 | 29 # Rules to gen a SliTaz package suitable for Tazpkg. |
pankso@790 | 30 genpkg_rules() |
pankso@790 | 31 { |
pankso@790 | 32 mkdir -p $fs/usr/lib $fs/usr/share |
pankso@790 | 33 cp -a $_pkg/etc $fs |
pankso@790 | 34 cp -a $_pkg/var $fs |
pankso@790 | 35 cp -a $_pkg/usr/bin $fs/usr |
pankso@790 | 36 cp -a $_pkg/usr/lib/*.so* $fs/usr/lib |
pankso@790 | 37 cp -a $_pkg/usr/lib/dbus $fs/usr/lib |
pankso@790 | 38 # Remove helper (600 Kb). |
pankso@790 | 39 rm $fs/usr/lib/dbus/dbus-daemon-launch-helper |
pankso@790 | 40 cp -a $_pkg/usr/share/dbus* $fs/usr/share |
pankso@790 | 41 # Init script |
pankso@790 | 42 cp -a stuff/etc $fs |
pankso@790 | 43 chown -R root.root $fs |
pankso@790 | 44 } |
pankso@790 | 45 |
pankso@790 | 46 pre_install() |
pankso@790 | 47 { |
pankso@790 | 48 local root |
pankso@790 | 49 root=$1 |
pankso@790 | 50 # Go for echoing on configuration files if any messagebus user |
pankso@790 | 51 # was found. |
pankso@790 | 52 if ! grep -q 'messagebus' $root/etc/passwd; then |
pankso@790 | 53 echo -n "Adding user: messagebus..." |
pankso@790 | 54 echo 'messagebus:x:25:25:DBUS Daemon User:/dev/null:/bin/false' >> $root/etc/passwd |
pankso@790 | 55 echo 'messagebus:!:14013:0:99999:7:::' >> $root/etc/shadow |
pankso@790 | 56 echo 'messagebus:x:25:' >> $root/etc/group |
pankso@790 | 57 echo 'messagebus:!::' >> $root/etc/gshadow |
pankso@790 | 58 status |
pankso@790 | 59 fi |
pankso@790 | 60 if ! grep -q ^DBUS_OPTIONS $root/etc/daemons.conf; then |
pankso@790 | 61 echo -n "Configuring $root/etc/daemons.conf..." |
pankso@790 | 62 cat >> $root/etc/daemons.conf << "EOT" |
pankso@790 | 63 # DBUS daemon options. |
pankso@790 | 64 DBUS_OPTIONS="--system" |
pankso@790 | 65 |
pankso@790 | 66 EOT |
pankso@790 | 67 status |
pankso@790 | 68 fi |
pankso@790 | 69 } |
pankso@790 | 70 |
pankso@790 | 71 pre_remove() |
pankso@790 | 72 { |
pankso@790 | 73 /etc/init.d/dbus stop |
pankso@790 | 74 deluser messagebus |
pankso@790 | 75 } |