# $Id$ PNAME="dbus" PVER="1.4.10" PBUILD="r2" PCATEGORIE="sys-apps" DESCRIPTION="D-BUS is a message bus system, a simple way for applications to talk to one another." HOMEPAGE="http://www.freedesktop.org/Software/dbus" DEPEND=">= x11-libs/libX11-1 >= x11-libs/libXt-1 >= dev-libs/expat-2" SDEPEND=">= dev-util/pkgconfig-0.25" SRCFILE="${PNAME}-${PVER}.tar.gz" SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" sminclude mtools multilib SRC_URI=( http://dbus.freedesktop.org/releases/${PNAME}/${SRCFILE} mirror://${PNAME}/${SRCFILE} mirror://${PNAME}/30-dbus ) # use subdir $uri/dbus UP2SUBDIR="${PNAME}" UP2DATE="updatecmd_freedesktop ${PNAME} gz" src_prepare() { munpack ${SRCFILE} || die # fix missing include all-abis 'sed -i "s/#include /#include \n#include /g" dbus/dbus-sysdeps-util-unix.c' || die } src_compile() { # using /lib/systemd/system as systemd units dir even on multilib systems # to have one common rules/script directory! mconfigure \ --with-system-pid-file=/var/run/dbus.pid \ --with-system-socket=/var/run/dbus/system_bus_socket \ --with-session-socket-dir=/tmp \ --with-test-socket-dir=/tmp \ --libexecdir=/usr/$(mlibdir)/dbus-1.0 \ --localstatedir=/var \ --with-dbus-user=messagebus \ --with-xml=expat \ --disable-verbose-mode \ --disable-checks \ --disable-asserts \ --enable-dnotify \ --with-x \ --disable-doxygen-docs \ --disable-xml-docs \ --with-systemdsystemunitdir=/lib/systemd/system \ || die mmake || die } src_install() { # needed directories minstalldir /etc/X11/xinit/xinitrc.d || die minstalldir /usr/env || die # fix ln issue on multilib: force overwrite of all symlinks mmake install DESTDIR=${BINDIR} LN_S="'ln -sf'" || die # session script minstallexec -s 30-dbus /etc/X11/xinit/xinitrc.d || die # kde needs special treatments minstallexec -s 30-dbus /usr/env/dbus-env.sh || die # mark some dirs undeletable mkeepdir /var/lib/dbus || die mkeepdir /var/run/dbus || die mkeepdir /usr/lib/dbus-1.0/services || die mkeepdir /usr/share/dbus-1/services || die mkeepdir /etc/dbus-1/system.d || die mkeepdir /etc/dbus-1/session.d || die minstalldocs AUTHORS ChangeLog COPYING HACKING NEWS README || die } preinstall() { # adds plugdev group ${MLIBDIR}/mgroupadd -o "-g 302" plugdev # adds messagebus user ${MLIBDIR}/mgroupadd -o "-g 300" messagebus ${MLIBDIR}/museradd -o "-u 300 -g messagebus -d /dev/null -s /bin/false" messagebus } postinstall() { mstartunit dbus.service dbus-daemon } postremove() { mstopunit dbus.service dbus-daemon }