summaryrefslogtreecommitdiff
blob: cd03ebe16855131984e5bd8ab02fb4914aaa3394 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
Description: transition to libsystemd from deprecated libsystemd-daemon
 systemd 209 merged the various libsystemd-* libraries into a single
 libsystemd.so, so we check for that instead and rename the configure
 option, define, etc accordingly.
Author: Florian Schlichting <fsfs@debian.org>
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=779762
Forwarded: not-needed (solved in a less invasive and backward-compatible way upstream)

--- a/configure.ac
+++ b/configure.ac
@@ -572,10 +572,10 @@
 MPD_DEPENDS([enable_sqlite], [enable_glib],
 	[Cannot use --enable-sqlite with --disable-glib])
 
-AC_ARG_ENABLE(systemd-daemon,
-	AS_HELP_STRING([--enable-systemd-daemon],
-		[use the systemd daemon library (default=auto)]),,
-	[enable_systemd_daemon=$linux_auto])
+AC_ARG_ENABLE(systemd,
+	AS_HELP_STRING([--enable-systemd],
+		[use the systemd library (default=auto)]),,
+	[enable_systemd=$linux_auto])
 
 AC_ARG_ENABLE(tcp,
 	AS_HELP_STRING([--disable-tcp],
@@ -762,11 +762,11 @@
 	AC_MSG_ERROR([No client interfaces configured!])
 fi
 
-MPD_AUTO_PKG(systemd_daemon, SYSTEMD_DAEMON, libsystemd-daemon,
-	[systemd activation], [libsystemd-daemon not found])
-AM_CONDITIONAL(ENABLE_SYSTEMD_DAEMON, test x$enable_systemd_daemon = xyes)
-if test x$enable_systemd_daemon = xyes; then
-	AC_DEFINE([ENABLE_SYSTEMD_DAEMON], 1, [Define to use the systemd daemon library])
+MPD_AUTO_PKG(systemd, SYSTEMD, libsystemd,
+	[systemd activation], [libsystemd not found])
+AM_CONDITIONAL(ENABLE_SYSTEMD, test x$enable_systemd = xyes)
+if test x$enable_systemd = xyes; then
+	AC_DEFINE([ENABLE_SYSTEMD], 1, [Define to use the systemd library])
 fi
 
 dnl ---------------------------------------------------------------------------
--- a/Makefile.am
+++ b/Makefile.am
@@ -58,7 +58,7 @@
 	$(ICU_LDADD) \
 	libutil.a \
 	$(FS_LIBS) \
-	$(SYSTEMD_DAEMON_LIBS) \
+	$(SYSTEMD_LIBS) \
 	$(GLIB_LIBS)
 
 src_mpd_SOURCES = \
--- a/config.h.in
+++ b/config.h.in
@@ -75,8 +75,8 @@
 /* Define to enable sqlite database support */
 #undef ENABLE_SQLITE
 
-/* Define to use the systemd daemon library */
-#undef ENABLE_SYSTEMD_DAEMON
+/* Define to use the systemd library */
+#undef ENABLE_SYSTEMD
 
 /* Define to enable the TwoLAME encoder plugin */
 #undef ENABLE_TWOLAME_ENCODER
--- a/src/Listen.cxx
+++ b/src/Listen.cxx
@@ -32,7 +32,7 @@
 #include <string.h>
 #include <assert.h>
 
-#ifdef ENABLE_SYSTEMD_DAEMON
+#ifdef ENABLE_SYSTEMD
 #include <systemd/sd-daemon.h>
 #endif
 
@@ -77,7 +77,7 @@
 	}
 }
 
-#ifdef ENABLE_SYSTEMD_DAEMON
+#ifdef ENABLE_SYSTEMD
 
 static bool
 listen_systemd_activation(Error &error_r)
@@ -109,7 +109,7 @@
 
 	listen_socket = new ClientListener(loop, partition);
 
-#ifdef ENABLE_SYSTEMD_DAEMON
+#ifdef ENABLE_SYSTEMD
 	if (listen_systemd_activation(error))
 		return true;
 
--- a/doc/user.xml
+++ b/doc/user.xml
@@ -110,7 +110,7 @@
   libupnp-dev \
   libavahi-client-dev \
   libsqlite3-dev \
-  libsystemd-daemon-dev libwrap0-dev \
+  libsystemd-dev libwrap0-dev \
   libcppunit-dev xmlto \
   libboost-dev \
   libglib2.0-dev libicu-dev