updated on Mon Jan 23 12:00:23 UTC 2012
[aur-mirror.git] / dbus-git / PKGBUILD
blob484140bdb1075c5ae67d6d5a78cbe08476cad508
1 # Contributor: Dave Reisner <d@falconindy.com>
3 pkgname=dbus-git
4 pkgver=20110213
5 pkgrel=1
6 pkgdesc="Freedesktop.org message bus system"
7 url="http://www.freedesktop.org/Software/dbus"
8 arch=('i686' 'x86_64')
9 license=('GPL' 'custom')
10 depends=('libx11' 'expat' 'coreutils' 'filesystem')
11 makedepends=('git')
12 provides=('dbus' 'dbus-core')
13 conflicts=('dbus' 'dbus-core')
14 options=('!libtool' 'emptydirs')
15 install=dbus.install
16 source=('dbus.rc'
17         '30-dbus')
18 md5sums=('08f93dd19cffd1b45ab05c1fd4efb560'
19          'd14e59575f04e55d21a04907b6fd9f3c')
21 _gitroot="git://anongit.freedesktop.org/git/dbus/dbus"
22 _gitname="dbus"
24 build() {
25   cd "$srcdir"
26   msg "Connecting to GIT server...."
28   if [ -d $_gitname ] ; then
29     cd $_gitname && git pull origin
30     msg "The local files are updated."
31   else
32     git clone $_gitroot $_gitname
33   fi
35   msg "GIT checkout done or server timeout"
36   msg "Starting make..."
38   rm -rf "$srcdir/$_gitname-build"
39   git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
40   cd "$srcdir/$_gitname-build"
42   ./autogen.sh --prefix=/usr --sysconfdir=/etc --localstatedir=/var \
43       --libexecdir=/usr/lib/dbus-1.0 --with-dbus-user=81 \
44       --disable-verbose-mode --disable-static \
45       --enable-inotify --disable-dnotify \
46       --disable-tests --disable-asserts
48   make
51 package() {
52   cd "$srcdir/$_gitname-build"
54   make DESTDIR="$pkgdir" install-man
56   pushd tools
57   install -m755 -d "$pkgdir/etc/X11/xinit/xinitrc.d"
58   install -m755 "$srcdir/30-dbus" "$pkgdir/etc/X11/xinit/xinitrc.d/"
59   install -d -m755 "$pkgdir/usr/share/licenses/dbus"
60   popd
62   make DESTDIR="$pkgdir" install
64   install -Dm644 COPYING "$pkgdir/usr/share/licenses/dbus/COPYING"
66   install -o 81 -g 81 -dm755 "$pkgdir/var/run/dbus"
67   install -Dm755 "$srcdir/dbus.rc" "$pkgdir/etc/rc.d/dbus"
69   #Fix configuration file
70   sed -i -e 's|<user>81</user>|<user>dbus</user>|' "$pkgdir/etc/dbus-1/system.conf"
72   #install .keep files so pacman doesn't delete empty dirs
73   touch "$pkgdir/usr/share/dbus-1/services/.keep"
74   touch "$pkgdir/usr/share/dbus-1/system-services/.keep"
75   touch "$pkgdir/etc/dbus-1/session.d/.keep"
76   touch "$pkgdir/etc/dbus-1/system.d/.keep"
78   install -dm755 "$pkgdir/usr/share/licenses/dbus-core"
79   install -Dm644 COPYING "$pkgdir/usr/share/licenses/dbus-core/COPYING"