Patchwork [6/9] weston: consider --disable-compat-libs in systemd

login
register
mail settings
Submitter Valentin Popa
Date July 15, 2014, 8 a.m.
Message ID <1405411250-10594-6-git-send-email-valentin.popa@intel.com>
Download mbox | patch
Permalink /patch/75517/
State New
Headers show

Comments

Valentin Popa - July 15, 2014, 8 a.m.
Since version 209 of systemd, libsystemd-login has been merged
into libsystemd.so.
This patch handles the case when systemd is built
without --enable-compat-libs (e.g. no libsystemd-login).

Signed-off-by: Valentin Popa <valentin.popa@intel.com>
---
 ...c-consider-disable-compat-libs-in-systemd.patch | 47 ++++++++++++++++++++++
 meta/recipes-graphics/wayland/weston_1.5.0.bb      |  3 +-
 2 files changed, 49 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-graphics/wayland/weston/0001-configure.ac-consider-disable-compat-libs-in-systemd.patch

Patch

diff --git a/meta/recipes-graphics/wayland/weston/0001-configure.ac-consider-disable-compat-libs-in-systemd.patch b/meta/recipes-graphics/wayland/weston/0001-configure.ac-consider-disable-compat-libs-in-systemd.patch
new file mode 100644
index 0000000..f195520
--- /dev/null
+++ b/meta/recipes-graphics/wayland/weston/0001-configure.ac-consider-disable-compat-libs-in-systemd.patch
@@ -0,0 +1,47 @@ 
+From 2273fb9cfb978c0e0cbb877475462d72d85138da Mon Sep 17 00:00:00 2001
+From: Valentin Popa <valentin.popa@intel.com>
+Date: Fri, 4 Jul 2014 16:11:19 +0300
+Subject: [PATCH] configure.ac: consider --disable-compat-libs in systemd
+
+Since version 209 of systemd, libsystemd-login has been merged
+into libsystemd.so.
+
+http://lists.freedesktop.org/archives/systemd-devel/2014-February/017146.html
+
+This patch handles the case when systemd is built
+without --enable-compat-libs (e.g. no libsystemd-login).
+
+Upstream-Status: Submitted [wayland-devel]
+
+Signed-off-by: Valentin Popa <valentin.popa@intel.com>
+---
+ configure.ac | 10 ++++++----
+ 1 file changed, 6 insertions(+), 4 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index f55cea8..2638d8a 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -346,13 +346,15 @@ AS_IF([test "x$enable_resize_optimization" = "xyes"],
+       [AC_DEFINE([USE_RESIZE_POOL], [1], [Use resize memory pool as a performance optimization])])
+ 
+ PKG_CHECK_MODULES(SYSTEMD_LOGIN, [libsystemd-login >= 198],
+-                  [have_systemd_login=yes], [have_systemd_login=no])
++                  [have_systemd_login_198=yes have_systemd_login_209=no], [
++  PKG_CHECK_MODULES(SYSTEMD_LOGIN, [libsystemd >= 209],
++                  [have_systemd_login_209=yes have_systemd_login_198=no], [have_systemd_login_209=no have_systemd_login_198=no])
++])
++AS_IF([test "x$have_systemd_login_198" = "xyes" -o "x$have_systemd_login_209" = "xyes"],
++      [have_systemd_login=yes], [have_systemd_login=no])
+ AS_IF([test "x$have_systemd_login" = "xyes"],
+       [AC_DEFINE([HAVE_SYSTEMD_LOGIN], [1], [Have systemd-login])])
+ AM_CONDITIONAL(HAVE_SYSTEMD_LOGIN, test "x$have_systemd_login" = "xyes")
+-
+-PKG_CHECK_MODULES(SYSTEMD_LOGIN_209, [libsystemd-login >= 209],
+-                  [have_systemd_login_209=yes], [have_systemd_login_209=no])
+ AS_IF([test "x$have_systemd_login_209" = "xyes"],
+       [AC_DEFINE([HAVE_SYSTEMD_LOGIN_209], [1], [Have systemd-login >= 209])])
+ 
+-- 
+1.9.1
+
diff --git a/meta/recipes-graphics/wayland/weston_1.5.0.bb b/meta/recipes-graphics/wayland/weston_1.5.0.bb
index 4a8584f..0c7cb0a 100644
--- a/meta/recipes-graphics/wayland/weston_1.5.0.bb
+++ b/meta/recipes-graphics/wayland/weston_1.5.0.bb
@@ -11,7 +11,8 @@  SRC_URI = "http://wayland.freedesktop.org/releases/${BPN}-${PV}.tar.xz \
            file://disable-wayland-scanner-pkg-check.patch \
            file://make-lcms-explicitly-configurable.patch \
            file://make-libwebp-explicitly-configurable.patch \
-"
+           file://0001-configure.ac-consider-disable-compat-libs-in-systemd.patch"
+
 SRC_URI[md5sum] = "8eb40d230efc2411f083c20656534780"
 SRC_URI[sha256sum] = "06388ba04ac79aa72d685cc1a8e646ddb2b8cfe11fcc742294f9addac48b7684"