mirror of
https://github.com/systemd/systemd.git
synced 2024-12-23 21:35:11 +03:00
build-sys: speed up build via convenience library
This commit is contained in:
parent
8745297f98
commit
139be57d94
86
Makefile.am
86
Makefile.am
@ -200,10 +200,15 @@ dist_doc_DATA = \
|
|||||||
src/sd-daemon.h \
|
src/sd-daemon.h \
|
||||||
src/sd-daemon.c
|
src/sd-daemon.c
|
||||||
|
|
||||||
|
noinst_LTLIBRARIES = \
|
||||||
|
libsystemd-basic.la \
|
||||||
|
libsystemd-core.la
|
||||||
|
|
||||||
# This is needed because automake is buggy in how it generates the
|
# This is needed because automake is buggy in how it generates the
|
||||||
# rules for C programs, but not Vala programs. We therefore can't
|
# rules for C programs, but not Vala programs. We therefore can't
|
||||||
# list the .h files as dependencies if we want make dist to work.
|
# list the .h files as dependencies if we want make dist to work.
|
||||||
BASIC_SOURCES = \
|
|
||||||
|
libsystemd_basic_la_SOURCES = \
|
||||||
src/util.c \
|
src/util.c \
|
||||||
src/hashmap.c \
|
src/hashmap.c \
|
||||||
src/set.c \
|
src/set.c \
|
||||||
@ -213,8 +218,7 @@ BASIC_SOURCES = \
|
|||||||
src/log.c \
|
src/log.c \
|
||||||
src/ratelimit.c
|
src/ratelimit.c
|
||||||
|
|
||||||
COMMON_SOURCES = \
|
libsystemd_core_la_SOURCES = \
|
||||||
$(BASIC_SOURCES) \
|
|
||||||
src/unit.c \
|
src/unit.c \
|
||||||
src/job.c \
|
src/job.c \
|
||||||
src/manager.c \
|
src/manager.c \
|
||||||
@ -259,8 +263,23 @@ COMMON_SOURCES = \
|
|||||||
src/namespace.c \
|
src/namespace.c \
|
||||||
src/tcpwrap.c
|
src/tcpwrap.c
|
||||||
|
|
||||||
|
libsystemd_core_la_CFLAGS = \
|
||||||
|
$(AM_CFLAGS) \
|
||||||
|
$(DBUS_CFLAGS) \
|
||||||
|
$(UDEV_CFLAGS) \
|
||||||
|
$(CGROUP_CFLAGS)
|
||||||
|
|
||||||
|
libsystemd_core_la_LIBADD = \
|
||||||
|
libsystemd-basic.la \
|
||||||
|
$(DBUS_LIBS) \
|
||||||
|
$(UDEV_LIBS) \
|
||||||
|
$(CGROUP_LIBS) \
|
||||||
|
$(LIBWRAP_LIBS) \
|
||||||
|
$(PAM_LIBS)
|
||||||
|
|
||||||
EXTRA_DIST += \
|
EXTRA_DIST += \
|
||||||
${COMMON_SOURCES:.c=.h} \
|
${libsystemd_basic_la_SOURCES:.c=.h} \
|
||||||
|
${libsystemd_core_la_SOURCES:.c=.h} \
|
||||||
src/macro.h \
|
src/macro.h \
|
||||||
src/ioprio.h \
|
src/ioprio.h \
|
||||||
src/missing.h \
|
src/missing.h \
|
||||||
@ -292,7 +311,6 @@ EXTRA_DIST += \
|
|||||||
man/systemd.special.html.in
|
man/systemd.special.html.in
|
||||||
|
|
||||||
systemd_SOURCES = \
|
systemd_SOURCES = \
|
||||||
$(COMMON_SOURCES) \
|
|
||||||
src/main.c
|
src/main.c
|
||||||
|
|
||||||
systemd_CFLAGS = \
|
systemd_CFLAGS = \
|
||||||
@ -302,55 +320,50 @@ systemd_CFLAGS = \
|
|||||||
$(CGROUP_CFLAGS)
|
$(CGROUP_CFLAGS)
|
||||||
|
|
||||||
systemd_LDADD = \
|
systemd_LDADD = \
|
||||||
$(DBUS_LIBS) \
|
libsystemd-core.la
|
||||||
$(UDEV_LIBS) \
|
|
||||||
$(CGROUP_LIBS) \
|
|
||||||
$(LIBWRAP_LIBS) \
|
|
||||||
$(PAM_LIBS)
|
|
||||||
|
|
||||||
test_engine_SOURCES = \
|
test_engine_SOURCES = \
|
||||||
$(COMMON_SOURCES) \
|
|
||||||
src/test-engine.c
|
src/test-engine.c
|
||||||
|
|
||||||
test_engine_CFLAGS = $(systemd_CFLAGS)
|
test_engine_CFLAGS = $(systemd_CFLAGS)
|
||||||
test_engine_LDADD = $(systemd_LDADD)
|
test_engine_LDADD = $(systemd_LDADD)
|
||||||
|
|
||||||
test_job_type_SOURCES = \
|
test_job_type_SOURCES = \
|
||||||
$(COMMON_SOURCES) \
|
|
||||||
src/test-job-type.c
|
src/test-job-type.c
|
||||||
|
|
||||||
test_job_type_CFLAGS = $(systemd_CFLAGS)
|
test_job_type_CFLAGS = $(systemd_CFLAGS)
|
||||||
test_job_type_LDADD = $(systemd_LDADD)
|
test_job_type_LDADD = $(systemd_LDADD)
|
||||||
|
|
||||||
test_ns_SOURCES = \
|
test_ns_SOURCES = \
|
||||||
$(BASIC_SOURCES) \
|
src/test-ns.c
|
||||||
src/test-ns.c \
|
|
||||||
src/namespace.c
|
|
||||||
|
|
||||||
test_ns_CFLAGS = $(systemd_CFLAGS)
|
test_ns_CFLAGS = $(systemd_CFLAGS)
|
||||||
test_ns_LDADD = $(systemd_LDADD)
|
test_ns_LDADD = $(systemd_LDADD)
|
||||||
|
|
||||||
test_loopback_SOURCES = \
|
test_loopback_SOURCES = \
|
||||||
$(BASIC_SOURCES) \
|
|
||||||
src/test-loopback.c \
|
src/test-loopback.c \
|
||||||
src/loopback-setup.c
|
src/loopback-setup.c
|
||||||
|
|
||||||
|
test_loopback_LDADD = \
|
||||||
|
libsystemd-basic.la
|
||||||
|
|
||||||
test_daemon_SOURCES = \
|
test_daemon_SOURCES = \
|
||||||
$(BASIC_SOURCES) \
|
|
||||||
src/test-daemon.c \
|
src/test-daemon.c \
|
||||||
src/sd-daemon.c
|
src/sd-daemon.c
|
||||||
|
|
||||||
|
test_daemon_LDADD = \
|
||||||
|
libsystemd-basic.la
|
||||||
|
|
||||||
systemd_logger_SOURCES = \
|
systemd_logger_SOURCES = \
|
||||||
$(BASIC_SOURCES) \
|
|
||||||
src/logger.c \
|
src/logger.c \
|
||||||
src/sd-daemon.c \
|
src/sd-daemon.c \
|
||||||
src/tcpwrap.c
|
src/tcpwrap.c
|
||||||
|
|
||||||
systemd_logger_LDADD = \
|
systemd_logger_LDADD = \
|
||||||
|
libsystemd-basic.la \
|
||||||
$(LIBWRAP_LIBS)
|
$(LIBWRAP_LIBS)
|
||||||
|
|
||||||
systemd_initctl_SOURCES = \
|
systemd_initctl_SOURCES = \
|
||||||
$(BASIC_SOURCES) \
|
|
||||||
src/initctl.c \
|
src/initctl.c \
|
||||||
src/sd-daemon.c
|
src/sd-daemon.c
|
||||||
|
|
||||||
@ -359,10 +372,10 @@ systemd_initctl_CFLAGS = \
|
|||||||
$(DBUS_CFLAGS)
|
$(DBUS_CFLAGS)
|
||||||
|
|
||||||
systemd_initctl_LDADD = \
|
systemd_initctl_LDADD = \
|
||||||
|
libsystemd-basic.la \
|
||||||
$(DBUS_LIBS)
|
$(DBUS_LIBS)
|
||||||
|
|
||||||
systemd_cgroups_agent_SOURCES = \
|
systemd_cgroups_agent_SOURCES = \
|
||||||
$(BASIC_SOURCES) \
|
|
||||||
src/cgroups-agent.c
|
src/cgroups-agent.c
|
||||||
|
|
||||||
systemd_cgroups_agent_CFLAGS = \
|
systemd_cgroups_agent_CFLAGS = \
|
||||||
@ -370,28 +383,39 @@ systemd_cgroups_agent_CFLAGS = \
|
|||||||
$(DBUS_CFLAGS)
|
$(DBUS_CFLAGS)
|
||||||
|
|
||||||
systemd_cgroups_agent_LDADD = \
|
systemd_cgroups_agent_LDADD = \
|
||||||
|
libsystemd-basic.la \
|
||||||
$(DBUS_LIBS)
|
$(DBUS_LIBS)
|
||||||
|
|
||||||
systemctl_SOURCES = \
|
systemctl_SOURCES = \
|
||||||
src/systemctl.c \
|
src/systemctl.c \
|
||||||
src/utmp-wtmp.c \
|
src/utmp-wtmp.c
|
||||||
$(BASIC_SOURCES)
|
|
||||||
|
|
||||||
systemctl_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS)
|
systemctl_CFLAGS = \
|
||||||
systemctl_LDADD = $(DBUS_LIBS)
|
$(AM_CFLAGS) \
|
||||||
|
$(DBUS_CFLAGS)
|
||||||
|
|
||||||
|
systemctl_LDADD = \
|
||||||
|
libsystemd-basic.la \
|
||||||
|
$(DBUS_LIBS)
|
||||||
|
|
||||||
systemd_notify_SOURCES = \
|
systemd_notify_SOURCES = \
|
||||||
src/notify.c \
|
src/notify.c \
|
||||||
src/sd-daemon.c \
|
src/sd-daemon.c
|
||||||
$(BASIC_SOURCES)
|
|
||||||
|
systemd_notify_LDADD = \
|
||||||
|
libsystemd-basic.la
|
||||||
|
|
||||||
systemd_install_SOURCES = \
|
systemd_install_SOURCES = \
|
||||||
src/install.c \
|
src/install.c \
|
||||||
src/path-lookup.c \
|
src/path-lookup.c
|
||||||
$(BASIC_SOURCES)
|
|
||||||
|
systemd_install_LDADD = \
|
||||||
|
libsystemd-basic.la
|
||||||
|
|
||||||
# We don't really link here against D-Bus, however we indirectly include D-Bus header files
|
# We don't really link here against D-Bus, however we indirectly include D-Bus header files
|
||||||
systemd_install_CFLAGS = $(AM_CFLAGS) $(DBUS_CFLAGS)
|
systemd_install_CFLAGS = \
|
||||||
|
$(AM_CFLAGS) \
|
||||||
|
$(DBUS_CFLAGS)
|
||||||
|
|
||||||
systemadm_SOURCES = \
|
systemadm_SOURCES = \
|
||||||
src/systemadm.vala \
|
src/systemadm.vala \
|
||||||
@ -412,7 +436,9 @@ systemadm_VALAFLAGS = \
|
|||||||
--pkg=gtk+-2.0 \
|
--pkg=gtk+-2.0 \
|
||||||
-g
|
-g
|
||||||
|
|
||||||
systemadm_LDADD = $(DBUSGLIB_LIBS) $(GTK_LIBS)
|
systemadm_LDADD = \
|
||||||
|
$(DBUSGLIB_LIBS) \
|
||||||
|
$(GTK_LIBS)
|
||||||
|
|
||||||
SED_PROCESS = \
|
SED_PROCESS = \
|
||||||
$(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
|
$(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
|
||||||
|
@ -59,6 +59,7 @@ else
|
|||||||
rm -rf autom4te.cache
|
rm -rf autom4te.cache
|
||||||
rm -f config.cache
|
rm -f config.cache
|
||||||
|
|
||||||
|
libtoolize -c --force
|
||||||
run_versioned aclocal "$AM_VERSION" -I m4
|
run_versioned aclocal "$AM_VERSION" -I m4
|
||||||
run_versioned autoconf "$AC_VERSION" -Wall
|
run_versioned autoconf "$AC_VERSION" -Wall
|
||||||
run_versioned autoheader "$AC_VERSION"
|
run_versioned autoheader "$AC_VERSION"
|
||||||
|
@ -87,6 +87,9 @@ CC_CHECK_CFLAGS_APPEND([ \
|
|||||||
-fdiagnostics-show-option \
|
-fdiagnostics-show-option \
|
||||||
-fno-strict-aliasing])
|
-fno-strict-aliasing])
|
||||||
|
|
||||||
|
LT_PREREQ(2.2)
|
||||||
|
LT_INIT
|
||||||
|
|
||||||
AC_SEARCH_LIBS([clock_gettime], [rt], [], [AC_MSG_ERROR([*** POSIX RT library not found])])
|
AC_SEARCH_LIBS([clock_gettime], [rt], [], [AC_MSG_ERROR([*** POSIX RT library not found])])
|
||||||
AC_SEARCH_LIBS([cap_init], [cap], [], [AC_MSG_ERROR([*** POSIX caps library not found])])
|
AC_SEARCH_LIBS([cap_init], [cap], [], [AC_MSG_ERROR([*** POSIX caps library not found])])
|
||||||
AC_CHECK_HEADERS([sys/capability.h], [], [AC_MSG_ERROR([*** POSIX caps headers not found])])
|
AC_CHECK_HEADERS([sys/capability.h], [], [AC_MSG_ERROR([*** POSIX caps headers not found])])
|
||||||
|
Loading…
Reference in New Issue
Block a user