Skip to contentSkip to conversation

dbus: use PACKAGECONFIG for X11 and systemd

PATCH New Ross Burton 1 participant 2 messages Dec 23, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 dbus: use PACKAGECONFIG for X11 and systemd

Instead of several variables and overrides, use PACKAGECONFIG to respect X11 and systemd DISTRO_FEATURES.

---
 meta/recipes-core/dbus/dbus.inc |   25 ++++++++++++-------------
 1 file changed, 12 insertions(+), 13 deletions(-)
meta/recipes-core/dbus/dbus.inc +12 -13
index 343079c..625e975 100644
@@ -5,10 +5,7 @@ SECTION = "base"
 LICENSE = "AFL-2 | GPLv2+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=10dded3b58148f3f1fd804b26354af3e \
                     file://dbus/dbus.h;beginline=6;endline=20;md5=7755c9d7abccd5dbd25a6a974538bb3c"
-X11DEPENDS = "virtual/libx11 libsm"
-DEPENDS = "expat virtual/libintl ${@base_contains('DISTRO_FEATURES', 'x11', '${X11DEPENDS}', '', d)}"
-DEPENDS_class-native = "expat-native virtual/libintl-native"
-DEPENDS_class-nativesdk = "nativesdk-expat virtual/nativesdk-libintl"
+DEPENDS = "expat virtual/libintl"
 RDEPENDS_dbus = "${@base_contains('DISTRO_FEATURES', 'ptest', 'dbus-ptest-ptest', '', d)}"
 RDEPENDS_dbus_class-native = ""
 RDEPENDS_dbus_class-nativesdk = ""
@@ -70,21 +67,23 @@ pkg_postinst_dbus() {
 	fi
 }
 
-EXTRA_OECONF_X = "${@base_contains('DISTRO_FEATURES', 'x11', '--with-x', '--without-x', d)}"
-EXTRA_OECONF_X_class-native = "--without-x --disable-x11-autolaunch"
-# TODO: would like to --enable-systemd but that's a circular build-dependency
-# between systemd<->dbus
-EXTRA_OECONF_SYSTEMD = "${@base_contains('DISTRO_FEATURES', 'systemd', '--with-systemdsystemunitdir=${systemd_unitdir}/system/', '--without-systemdsystemunitdir', d)}"
-
 EXTRA_OECONF = "--disable-tests \
                 --disable-checks \
                 --disable-xml-docs \
                 --disable-doxygen-docs \
                 --disable-libaudit \
                 --with-xml=expat \
-                --disable-systemd \
-                ${EXTRA_OECONF_SYSTEMD} \
-                ${EXTRA_OECONF_X}"
+                --disable-systemd"
+
+PACKAGECONFIG ??= "${@base_contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)} \
+                   ${@base_contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}"
+PACKAGECONFIG_class-native = ""
+PACKAGECONFIG_class-nativesdk = ""
+
+# Would like to --enable-systemd but that's a circular build-dependency between
+# systemd<->dbus
+PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/,--without-systemdsystemunitdir"
+PACKAGECONFIG[x11] = "--with-x --enable-x11-autolaunch,--without-x --disable-x11-autolaunch, virtual/libx11 libsm"
 
 do_install() {
 	autotools_do_install
Signature · 1 line
1.7.10.4
#1 lore raw

PATCH 2/2 dbus: enable API entry point checks

We were disabling API entry point sanity checking which should only be done if the performance gain is prefereable to correctness. Instead don't disable checks explicitly as the default is enabled, allowing distributions to append --disable-checks if required.

---
 meta/recipes-core/dbus/dbus.inc |    1 -
 1 file changed, 1 deletion(-)
meta/recipes-core/dbus/dbus.inc +0 -1
index 625e975..ae80cb0 100644
@@ -68,7 +68,6 @@ pkg_postinst_dbus() {
 }
 
 EXTRA_OECONF = "--disable-tests \
-                --disable-checks \
                 --disable-xml-docs \
                 --disable-doxygen-docs \
                 --disable-libaudit \
Signature · 1 line
1.7.10.4