summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Sturmlechner <asturm@gentoo.org>2019-03-30 23:32:54 +0100
committerAndreas Sturmlechner <asturm@gentoo.org>2019-03-31 12:39:36 +0200
commit5bd270f4a595255b62e34e17375c50d5ef82f15f (patch)
tree4977ae6b3b37402a0d936432bf295123f73df7c4 /mate-base/mate-session-manager/files/mate-session-manager-1.22.0-elogind.patch
parentmedia-sound/lmms: Drop old (diff)
downloadgentoo-5bd270f4a595255b62e34e17375c50d5ef82f15f.tar.gz
gentoo-5bd270f4a595255b62e34e17375c50d5ef82f15f.tar.bz2
gentoo-5bd270f4a595255b62e34e17375c50d5ef82f15f.zip
mate-base/mate-session-manager: Add USE elogind
Bug: https://bugs.gentoo.org/633336 Package-Manager: Portage-2.3.62, Repoman-2.3.12 Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
Diffstat (limited to 'mate-base/mate-session-manager/files/mate-session-manager-1.22.0-elogind.patch')
-rw-r--r--mate-base/mate-session-manager/files/mate-session-manager-1.22.0-elogind.patch84
1 files changed, 84 insertions, 0 deletions
diff --git a/mate-base/mate-session-manager/files/mate-session-manager-1.22.0-elogind.patch b/mate-base/mate-session-manager/files/mate-session-manager-1.22.0-elogind.patch
new file mode 100644
index 00000000000..ebe68a0b354
--- /dev/null
+++ b/mate-base/mate-session-manager/files/mate-session-manager-1.22.0-elogind.patch
@@ -0,0 +1,84 @@
+From e6f62cd82d2717cb26951629e3f071814694fd07 Mon Sep 17 00:00:00 2001
+From: Victor Kareh <vkareh@redhat.com>
+Date: Fri, 8 Mar 2019 13:37:01 -0500
+Subject: [PATCH] Add ELOGIND support
+
+Reuses HAVE_SYSTEMD #define to reduce #ifdef mess.
+
+ELOGIND is not officially supported, but since it's
+a subset of systemd, it should work out of the box.
+
+Co-authored-by: Joakim Tjernlund <joakim.tjernlund@infinera.com>
+Co-authored-by: Jorge Pizarro Callejas <jpizarrocallejas@gmail.com>
+---
+ configure.ac | 29 +++++++++++++++++++++++++++++
+ mate-session/Makefile.am | 2 ++
+ 2 files changed, 31 insertions(+)
+
+diff --git a/configure.ac b/configure.ac
+index 207ad97..1390ba0 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -109,6 +109,34 @@ fi
+ AM_CONDITIONAL(HAVE_SYSTEMD, test "x$use_systemd" = "xyes")
+ AC_SUBST(HAVE_SYSTEMD)
+
++dnl ====================================================================
++dnl Check for elogind
++dnl
++dnl elogind is not officially supported, but since it's a subset of
++dnl systemd, it should work out of the box
++dnl ====================================================================
++
++AC_ARG_WITH(elogind,
++ AS_HELP_STRING([--with-elogind],
++ [Use libelogind instead of libsystemd-login]),,
++ with_elogind=auto)
++
++use_elogind=no
++if test "x$with_elogind" != "xno"; then
++ PKG_CHECK_MODULES(LIBELOGIND,[libelogind], [use_elogind=yes],
++ [PKG_CHECK_MODULES([LIBELOGIND], [libelogind],
++ [use_elogind=yes], [use_elogind=no])])
++
++ if test "x$use_elogind" = "xyes"; then
++ AC_DEFINE([HAVE_ELOGIND], 1, [elogind support])
++ AC_DEFINE([HAVE_SYSTEMD], 1, [Define to 1 to reduce ifdefs since elogind is a drop-in replacement for systemd])
++ AC_SUBST(LIBELOGIND_CFLAGS)
++ AC_SUBST(LIBELOGIND_LIBS)
++ fi
++fi
++AM_CONDITIONAL(HAVE_ELOGIND, [test "x$use_elogind" = "xyes"])
++AC_SUBST(HAVE_ELOGIND)
++
+ dnl ====================================================================
+ dnl Check for XSync extension
+ dnl ====================================================================
+@@ -333,6 +361,7 @@ echo "
+
+ Default WM: ${with_default_wm}
+ Systemd support: ${use_systemd}
++ Elogind support: ${use_elogind}
+ IPv6 support: ${have_full_ipv6}
+ Backtrace support: ${have_backtrace}
+ XRender support: ${have_xrender}
+diff --git a/mate-session/Makefile.am b/mate-session/Makefile.am
+index 093c908..ea0dc95 100644
+--- a/mate-session/Makefile.am
++++ b/mate-session/Makefile.am
+@@ -7,6 +7,7 @@ noinst_PROGRAMS = \
+ AM_CPPFLAGS = \
+ $(MATE_SESSION_CFLAGS) \
+ $(SYSTEMD_CFLAGS) \
++ $(LIBELOGIND_CFLAGS) \
+ $(DISABLE_DEPRECATED_CFLAGS)
+
+ AM_CFLAGS = $(WARN_CFLAGS)
+@@ -80,6 +81,7 @@ mate_session_LDADD = \
+ $(XEXT_LIBS) \
+ $(MATE_SESSION_LIBS) \
+ $(SYSTEMD_LIBS) \
++ $(LIBELOGIND_LIBS) \
+ $(EXECINFO_LIBS)
+
+ libgsmutil_la_SOURCES = \