mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
configure.ac: use LIBSYSTEMD
Convert naming SYSTEMD_CFLAGS/LIB -> LIBSYSTEMD_CFLAGS/LIBS to better fit library check for libsystemd. Build lvmlockd with SD_NOTIFY when we have defined LIBSYSTEMD_LIBS.
This commit is contained in:
parent
3ef26494f2
commit
d106ac04ab
@ -1090,7 +1090,7 @@ AS_IF([test "$APP_MACHINEID_SUPPORT" = "yes"],
|
||||
|
||||
dnl -- Look for libsystemd libraries if needed
|
||||
AS_IF([test "$NOTIFYDBUS_SUPPORT" = "yes" || test "$SYSTEMD_JOURNAL_SUPPORT" = "yes" || test "$APP_MACHINEID_SUPPORT" = "yes"], [
|
||||
PKG_CHECK_MODULES(SYSTEMD, [systemd], [SYSTEMD_LIBS="-lsystemd"], $bailout)
|
||||
PKG_CHECK_MODULES(LIBSYSTEMD, [libsystemd], [], $bailout)
|
||||
])
|
||||
|
||||
################################################################################
|
||||
|
@ -15,8 +15,6 @@ srcdir = @srcdir@
|
||||
top_srcdir = @top_srcdir@
|
||||
top_builddir = @top_builddir@
|
||||
|
||||
USE_SD_NOTIFY=yes
|
||||
|
||||
SOURCES = lvmlockd-core.c
|
||||
|
||||
ifeq ("@BUILD_LOCKDSANLOCK@", "yes")
|
||||
@ -51,9 +49,9 @@ INCLUDES += -I$(top_srcdir)/libdaemon/server
|
||||
LDFLAGS += -L$(top_builddir)/libdaemon/server $(EXTRA_EXEC_LDFLAGS) $(ELDFLAGS)
|
||||
LIBS += $(DAEMON_LIBS) $(PTHREAD_LIBS)
|
||||
|
||||
ifeq ($(USE_SD_NOTIFY),yes)
|
||||
CFLAGS += $(SYSTEMD_CFLAGS) -DUSE_SD_NOTIFY
|
||||
LIBS += $(SYSTEMD_LIBS)
|
||||
ifneq (,$(firstword $(LIBSYSTEMD_LIBS)))
|
||||
CFLAGS += $(LIBSYSTEMD_CFLAGS) -DUSE_SD_NOTIFY
|
||||
LIBS += $(LIBSYSTEMD_LIBS)
|
||||
endif
|
||||
|
||||
lvmlockd: $(OBJECTS) $(top_builddir)/libdaemon/server/libdaemonserver.a $(INTERNAL_LIBS)
|
||||
|
@ -75,7 +75,7 @@ UDEV_CFLAGS = @UDEV_CFLAGS@
|
||||
UDEV_LIBS = @UDEV_LIBS@
|
||||
BLKID_CFLAGS = @BLKID_CFLAGS@
|
||||
BLKID_LIBS = @BLKID_LIBS@
|
||||
SYSTEMD_LIBS = @SYSTEMD_LIBS@
|
||||
LIBSYSTEMD_LIBS = @LIBSYSTEMD_LIBS@
|
||||
VALGRIND_CFLAGS = @VALGRIND_CFLAGS@
|
||||
|
||||
# Setup directory variables
|
||||
|
@ -57,7 +57,7 @@ PYTHON3 = @PYTHON3@
|
||||
PYCOMPILE = $(top_srcdir)/autoconf/py-compile
|
||||
|
||||
LIBS += @LIBS@ $(SELINUX_LIBS) $(UDEV_LIBS) $(RT_LIBS) $(M_LIBS)
|
||||
LVMLIBS = $(DMEVENT_LIBS) $(READLINE_LIBS) $(EDITLINE_LIBS) $(SYSTEMD_LIBS) $(BLKID_LIBS) $(AIO_LIBS) $(LIBS)
|
||||
LVMLIBS = $(DMEVENT_LIBS) $(READLINE_LIBS) $(EDITLINE_LIBS) $(LIBSYSTEMD_LIBS) $(BLKID_LIBS) $(AIO_LIBS) $(LIBS)
|
||||
# Extra libraries always linked with static binaries
|
||||
STATIC_LIBS = $(PTHREAD_LIBS)
|
||||
DEFS += @DEFS@
|
||||
@ -82,12 +82,12 @@ CPG_CFLAGS = @CPG_CFLAGS@
|
||||
CPG_LIBS = @CPG_LIBS@
|
||||
EDITLINE_CFLAGS = @EDITLINE_CFLAGS@
|
||||
EDITLINE_LIBS = @EDITLINE_LIBS@
|
||||
LIBSYSTEMD_CFLAGS = @LIBSYSTEMD_CFLAGS@
|
||||
LIBSYSTEMD_LIBS = @LIBSYSTEMD_LIBS@
|
||||
PTHREAD_LIBS = @PTHREAD_LIBS@
|
||||
READLINE_CFLAGS = @READLINE_CFLAGS@
|
||||
READLINE_LIBS = @READLINE_LIBS@
|
||||
SELINUX_LIBS = @SELINUX_LIBS@
|
||||
SYSTEMD_CFLAGS = @SYSTEMD_CFLAGS@
|
||||
SYSTEMD_LIBS = @SYSTEMD_LIBS@
|
||||
UDEV_CFLAGS = @UDEV_CFLAGS@
|
||||
UDEV_LIBS = @UDEV_LIBS@
|
||||
VALGRIND_CFLAGS = @VALGRIND_CFLAGS@
|
||||
|
Loading…
Reference in New Issue
Block a user