summaryrefslogtreecommitdiff
path: root/package/dbus
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@uclibc-ng.org>2016-11-20 17:42:34 +0100
committerWaldemar Brodkorb <wbx@openadk.org>2016-11-25 01:49:36 +0100
commitb0f23d1e562e753cb78a473fdade956a25cc337b (patch)
treefe4a5908d1e39e24ec6df66052e866ed72421a79 /package/dbus
parent49a817b44be5695a87f6b4c8eadef3bb0f9419f9 (diff)
finalize systemd as alternative init system
Most important is the fix in patch-src_journal_journald-server_c, which breaks startup of systemd-journald when code is compiled with -DNDEBUG. A lot of base-files reorganizing to only install required files on sysv systems.
Diffstat (limited to 'package/dbus')
-rw-r--r--package/dbus/Makefile45
-rw-r--r--package/dbus/files/dbus.postinst10
-rw-r--r--package/dbus/patches/patch-configure_ac26
3 files changed, 61 insertions, 20 deletions
diff --git a/package/dbus/Makefile b/package/dbus/Makefile
index 7b17fff5a..d0c5a4ee9 100644
--- a/package/dbus/Makefile
+++ b/package/dbus/Makefile
@@ -4,9 +4,9 @@
include ${ADK_TOPDIR}/rules.mk
PKG_NAME:= dbus
-PKG_VERSION:= 1.10.8
+PKG_VERSION:= 1.10.12
PKG_RELEASE:= 1
-PKG_HASH:= baf3d22baa26d3bdd9edc587736cd5562196ce67996d65b82103bedbe1f0c014
+PKG_HASH:= 210a79430b276eafc6406c71705e9140d25b9956d18068df98a70156dc0e475d
PKG_DESCR:= desktop bus daemon
PKG_SECTION:= sys/misc
PKG_DEPENDS:= libdbus libexpat
@@ -24,23 +24,38 @@ PKGSD_LIBDBUS:= DBUS library
PKGSC_LIBDBUS:= libs/misc
PKGSS_LIBDBUS:= libexpat libuuid
+PKG_FLAVOURS_DBUS:= WITH_SYSTEMD
+PKGFD_WITH_SYSTEMD:= enable systemd support
+PKGFB_WITH_SYSTEMD:= systemd
+
include ${ADK_TOPDIR}/mk/package.mk
$(eval $(call PKG_template,DBUS,dbus,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
$(eval $(call PKG_template,LIBDBUS,libdbus,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_LIBDBUS},${PKGSD_LIBDBUS},${PKGSC_LIBDBUS},${PKG_OPTS}))
TARGET_LDFLAGS+= -luuid
+
+AUTOTOOL_STYLE:= autoreconf
+ifeq ($(ADK_PACKAGE_DBUS_WITH_SYSTEMD),y)
+CONFIGURE_ARGS+= --enable-systemd --with-systemdsystemunitdir=/usr/lib/systemd/system
+TARGET_LDFLAGS+= -lsystemd
+else
+CONFIGURE_ARGS+= --disable-systemd
+endif
+
CONFIGURE_ARGS+= --disable-tests \
- --disable-abstract-sockets \
- --enable-checks \
+ --disable-asserts \
+ --enable-abstract-sockets \
+ --with-dbus-user=dbus \
+ --with-system-socket=/run/dbus/system_bus_socket \
+ --with-system-pid-file=/run/dbus/dbus.pid \
--disable-verbose-mode \
- --with-session-socket-dir=/var/tmp \
--disable-kqueue \
- --disable-systemd \
+ --disable-selinux \
+ --disable-libaudit \
+ --disable-doxygen-docs \
--disable-xml-docs \
- --without-x \
- --disable-doxygen-docs
-CONFIGURE_ENV+= ac_cv_have_abstract_sockets=no
+ --without-x
pre-install:
${INSTALL_DIR} $(STAGING_TARGET_DIR)/usr/include/dbus-1.0/dbus
@@ -54,15 +69,17 @@ libdbus-install:
dbus-install:
${INSTALL_DIR} ${IDIR_DBUS}/etc ${IDIR_DBUS}/usr/share \
${IDIR_DBUS}/usr/bin ${IDIR_DBUS}/usr/libexec
+ ${INSTALL_DIR} ${IDIR_DBUS}/var/lib/dbus ${IDIR_DBUS}/run/dbus
+ (cd ${IDIR_DBUS}/var/lib/dbus; ln -sf ../../../etc/machine-id .)
${INSTALL_BIN} ${WRKINST}/usr/libexec/dbus-daemon-launch-helper \
${IDIR_DBUS}/usr/libexec/
${CP} ${WRKINST}/etc/dbus-1 ${IDIR_DBUS}/etc
${CP} ${WRKINST}/usr/share/dbus-1 ${IDIR_DBUS}/usr/share
- ${INSTALL_BIN} ${WRKINST}/usr/bin/dbus-daemon ${IDIR_DBUS}/usr/bin
- ${INSTALL_BIN} ${WRKINST}/usr/bin/dbus-launch ${IDIR_DBUS}/usr/bin
- ${INSTALL_BIN} ${WRKINST}/usr/bin/dbus-uuidgen ${IDIR_DBUS}/usr/bin
- ${INSTALL_BIN} ${WRKINST}/usr/bin/dbus-send ${IDIR_DBUS}/usr/bin
- ${INSTALL_BIN} ${WRKINST}/usr/bin/dbus-monitor ${IDIR_DBUS}/usr/bin
+ ${CP} ${WRKINST}/usr/bin/dbus-* ${IDIR_DBUS}/usr/bin
+ifeq ($(ADK_PACKAGE_DBUS_WITH_SYSTEMD),y)
+ ${INSTALL_DIR} ${IDIR_DBUS}/usr/lib/systemd
+ ${CP} ${WRKINST}/usr/lib/systemd/* ${IDIR_DBUS}/usr/lib/systemd
+endif
# workaround for dev subpackage
${INSTALL_DIR} $(IDIR_DBUS_DEV)/usr/include/dbus-1.0/dbus
$(CP) $(WRKBUILD)/dbus/dbus-arch-deps.h \
diff --git a/package/dbus/files/dbus.postinst b/package/dbus/files/dbus.postinst
index e92450597..0f3f9c6ae 100644
--- a/package/dbus/files/dbus.postinst
+++ b/package/dbus/files/dbus.postinst
@@ -1,12 +1,10 @@
#!/bin/sh
. $IPKG_INSTROOT/etc/functions.sh
gid=$(get_next_gid)
-add_group messagebus $gid
-add_user messagebus $(get_next_uid) $gid /var/run/dbus
+add_group dbus $gid
+add_user dbus $(get_next_uid) $gid /var/run/dbus
add_rcconf dbus NO
-echo Generating UUID
if [ -z $IPKG_INSTROOT ];then
- mkdir /lib/dbus /var/lib
- ln -sf /lib/dbus /var/lib/dbus
- dbus-uuidgen --ensure
+ echo Generating UUID
+ dbus-uuidgen --ensure
fi
diff --git a/package/dbus/patches/patch-configure_ac b/package/dbus/patches/patch-configure_ac
new file mode 100644
index 000000000..cd50a7b14
--- /dev/null
+++ b/package/dbus/patches/patch-configure_ac
@@ -0,0 +1,26 @@
+--- dbus-1.10.8.orig/configure.ac 2016-03-07 17:06:22.000000000 +0100
++++ dbus-1.10.8/configure.ac 2016-11-21 11:25:39.000000000 +0100
+@@ -1186,23 +1186,9 @@ dnl systemd detection
+ if test x$enable_systemd = xno ; then
+ have_systemd=no;
+ else
+- PKG_CHECK_MODULES([SYSTEMD],
+- [libsystemd >= 209],
+- [have_systemd=yes],
+- [PKG_CHECK_MODULES([SYSTEMD],
+- [libsystemd-login >= 32, libsystemd-daemon >= 32, libsystemd-journal >= 32],
+- [have_systemd=yes],
+- [have_systemd=no])])
+-fi
+-
+-if test x$have_systemd = xyes; then
+ AC_DEFINE(HAVE_SYSTEMD,1,[Have systemd])
+ fi
+
+-if test x$enable_systemd = xyes -a x$have_systemd != xyes ; then
+- AC_MSG_ERROR([Explicitly requested systemd support, but systemd not found])
+-fi
+-
+ # If not found in $PATH, we might still have systemd and systemctl at runtime
+ # (perhaps dbus is being compiled in a minimal chroot with no systemd).
+ # Assume the upstream-recommended location. Distributors with split /usr