wok-next view dbus/receipt @ rev 1527

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