]> git.ipfire.org Git - thirdparty/systemd.git/blob - Makefile.am
Merge pull request #5907 from keszybz/mark-python-scripts-+x
[thirdparty/systemd.git] / Makefile.am
1 # -*- Mode: makefile; indent-tabs-mode: t -*-
2 #
3 # This file is part of systemd.
4 #
5 # Copyright 2010-2012 Lennart Poettering
6 # Copyright 2010-2012 Kay Sievers
7 # Copyright 2013 Zbigniew Jędrzejewski-Szmek
8 # Copyright 2013 David Strauss
9 #
10 # systemd is free software; you can redistribute it and/or modify it
11 # under the terms of the GNU Lesser General Public License as published by
12 # the Free Software Foundation; either version 2.1 of the License, or
13 # (at your option) any later version.
14 #
15 # systemd is distributed in the hope that it will be useful, but
16 # WITHOUT ANY WARRANTY; without even the implied warranty of
17 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 # Lesser General Public License for more details.
19 #
20 # You should have received a copy of the GNU Lesser General Public License
21 # along with systemd; If not, see <http://www.gnu.org/licenses/>.
22
23 ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
24 AM_MAKEFLAGS = --no-print-directory
25 AUTOMAKE_OPTIONS = color-tests parallel-tests
26
27 GCC_COLORS ?= 'ooh, shiny!'
28 export GCC_COLORS
29
30 SUBDIRS = . po
31
32 # remove targets if the command fails
33 .DELETE_ON_ERROR:
34
35 # keep intermediate files
36 .SECONDARY:
37
38 # Keep the test-suite.log
39 .PRECIOUS: $(TEST_SUITE_LOG) Makefile
40
41 LIBUDEV_CURRENT=7
42 LIBUDEV_REVISION=6
43 LIBUDEV_AGE=6
44
45 LIBSYSTEMD_CURRENT=18
46 LIBSYSTEMD_REVISION=0
47 LIBSYSTEMD_AGE=18
48
49 # Dirs of external packages
50 dbuspolicydir=@dbuspolicydir@
51 dbussessionservicedir=@dbussessionservicedir@
52 dbussystemservicedir=@dbussystemservicedir@
53 pamlibdir=@pamlibdir@
54 pamconfdir=@pamconfdir@
55 pkgconfigdatadir=$(datadir)/pkgconfig
56 pkgconfiglibdir=$(libdir)/pkgconfig
57 polkitpolicydir=$(datadir)/polkit-1/actions
58 polkitrulesdir=$(datadir)/polkit-1/rules.d
59 polkitpkladir=$(localstatedir)/lib/polkit-1/localauthority/10-vendor.d
60 bashcompletiondir=@bashcompletiondir@
61 zshcompletiondir=@zshcompletiondir@
62 rpmmacrosdir=@rpmmacrosdir@
63 sysvinitdir=$(SYSTEM_SYSVINIT_PATH)
64 sysvrcnddir=$(SYSTEM_SYSVRCND_PATH)
65 varlogdir=$(localstatedir)/log
66 systemdstatedir=$(localstatedir)/lib/systemd
67 catalogstatedir=$(systemdstatedir)/catalog
68 xinitrcdir=$(sysconfdir)/X11/xinit/xinitrc.d
69
70 # Our own, non-special dirs
71 environmentdir=$(prefix)/lib/environment.d
72 pkgsysconfdir=$(sysconfdir)/systemd
73 userunitdir=$(prefix)/lib/systemd/user
74 userpresetdir=$(prefix)/lib/systemd/user-preset
75 tmpfilesdir=$(prefix)/lib/tmpfiles.d
76 sysusersdir=$(prefix)/lib/sysusers.d
77 sysctldir=$(prefix)/lib/sysctl.d
78 binfmtdir=$(prefix)/lib/binfmt.d
79 modulesloaddir=$(prefix)/lib/modules-load.d
80 networkdir=$(rootprefix)/lib/systemd/network
81 pkgincludedir=$(includedir)/systemd
82 systemgeneratordir=$(rootlibexecdir)/system-generators
83 usergeneratordir=$(prefix)/lib/systemd/user-generators
84 systemenvgeneratordir=$(prefix)/lib/systemd/system-environment-generators
85 userenvgeneratordir=$(prefix)/lib/systemd/user-environment-generators
86 systemshutdowndir=$(rootlibexecdir)/system-shutdown
87 systemsleepdir=$(rootlibexecdir)/system-sleep
88 systemunitdir=$(rootprefix)/lib/systemd/system
89 systempresetdir=$(rootprefix)/lib/systemd/system-preset
90 udevlibexecdir=$(rootprefix)/lib/udev
91 udevhomedir=$(udevlibexecdir)
92 udevrulesdir=$(udevlibexecdir)/rules.d
93 udevhwdbdir=$(udevlibexecdir)/hwdb.d
94 catalogdir=$(prefix)/lib/systemd/catalog
95 kernelinstalldir = $(prefix)/lib/kernel/install.d
96 factory_etcdir = $(datadir)/factory/etc
97 factory_pamdir = $(datadir)/factory/etc/pam.d
98 bootlibdir = $(prefix)/lib/systemd/boot/efi
99 testsdir = $(prefix)/lib/systemd/tests
100
101 # And these are the special ones for /
102 rootprefix=@rootprefix@
103 rootbindir=$(rootprefix)/bin
104 rootlibexecdir=$(rootprefix)/lib/systemd
105
106 EXTRA_DIST =
107 BUILT_SOURCES =
108 INSTALL_EXEC_HOOKS =
109 UNINSTALL_EXEC_HOOKS =
110 INSTALL_DATA_HOOKS =
111 UNINSTALL_DATA_HOOKS =
112 DISTCLEAN_LOCAL_HOOKS =
113 CLEAN_LOCAL_HOOKS =
114 pkginclude_HEADERS =
115 noinst_LTLIBRARIES =
116 lib_LTLIBRARIES =
117 rootlibexec_LTLIBRARIES =
118 include_HEADERS =
119 noinst_DATA =
120 pkgconfigdata_DATA =
121 pkgconfiglib_DATA =
122 polkitpolicy_in_in_files =
123 polkitpolicy_in_files =
124 polkitpolicy_files =
125 polkitrules_files =
126 polkitpkla_files =
127 dist_udevrules_DATA =
128 nodist_udevrules_DATA =
129 dist_pkgsysconf_DATA =
130 nodist_pkgsysconf_DATA =
131 dist_dbuspolicy_DATA =
132 dist_dbussystemservice_DATA =
133 dist_systemunit_DATA_busnames =
134 dist_sysusers_DATA =
135 check_PROGRAMS =
136 check_DATA =
137 dist_rootlibexec_DATA =
138 tests=
139 manual_tests =
140 TEST_DATA_FILES =
141 TEST_EXTENSIONS = .py
142 PY_LOG_COMPILER = $(PYTHON)
143 DISABLE_HARD_ERRORS = yes
144 if ENABLE_TESTS
145 noinst_PROGRAMS = $(manual_tests) $(tests) $(unsafe_tests)
146 TESTS = $(tests)
147 if ENABLE_UNSAFE_TESTS
148 TESTS += \
149 $(unsafe_tests)
150 endif
151 else
152 noinst_PROGRAMS =
153 TESTS =
154 endif
155 AM_TESTS_ENVIRONMENT = \
156 export SYSTEMD_KBD_MODEL_MAP=$(abs_top_srcdir)/src/locale/kbd-model-map; \
157 export SYSTEMD_LANGUAGE_FALLBACK_MAP=$(abs_top_srcdir)/src/locale/language-fallback-map; \
158 export PATH=$(abs_top_builddir):$$PATH;
159
160 if ENABLE_BASH_COMPLETION
161 dist_bashcompletion_DATA = $(dist_bashcompletion_data)
162 nodist_bashcompletion_DATA = $(nodist_bashcompletion_data)
163 endif
164 if ENABLE_ZSH_COMPLETION
165 dist_zshcompletion_DATA = $(dist_zshcompletion_data)
166 nodist_zshcompletion_DATA = $(nodist_zshcompletion_data)
167 endif
168 udevlibexec_PROGRAMS =
169 gperf_gperf_sources =
170 rootlib_LTLIBRARIES =
171
172 in_files = $(filter %.in,$(EXTRA_DIST))
173 in_in_files = $(filter %.in.in, $(in_files))
174 m4_files = $(filter %.m4,$(EXTRA_DIST) $(in_files:.m4.in=.m4))
175
176 CLEANFILES = $(BUILT_SOURCES) \
177 $(pkgconfigdata_DATA) \
178 $(pkgconfiglib_DATA) \
179 $(nodist_bashcompletion_data) \
180 $(nodist_zshcompletion_data) \
181 $(nodist_rpmmacros_DATA) \
182 $(in_files:.in=) $(in_in_files:.in.in=) \
183 $(m4_files:.m4=)
184
185 .PHONY: $(INSTALL_EXEC_HOOKS) $(UNINSTALL_EXEC_HOOKS) \
186 $(INSTALL_DATA_HOOKS) $(UNINSTALL_DATA_HOOKS) \
187 $(DISTCLEAN_LOCAL_HOOKS) $(CLEAN_LOCAL_HOOKS)
188
189 AM_CPPFLAGS = \
190 -include $(top_builddir)/config.h \
191 -DPKGSYSCONFDIR=\"$(pkgsysconfdir)\" \
192 -DSYSTEM_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/system\" \
193 -DSYSTEM_DATA_UNIT_PATH=\"$(systemunitdir)\" \
194 -DSYSTEM_SYSVINIT_PATH=\"$(SYSTEM_SYSVINIT_PATH)\" \
195 -DSYSTEM_SYSVRCND_PATH=\"$(SYSTEM_SYSVRCND_PATH)\" \
196 -DUSER_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/user\" \
197 -DUSER_DATA_UNIT_PATH=\"$(userunitdir)\" \
198 -DCERTIFICATE_ROOT=\"$(CERTIFICATEROOT)\" \
199 -DCATALOG_DATABASE=\"$(catalogstatedir)/database\" \
200 -DSYSTEMD_CGROUP_AGENT_PATH=\"$(rootlibexecdir)/systemd-cgroups-agent\" \
201 -DSYSTEMD_BINARY_PATH=\"$(rootlibexecdir)/systemd\" \
202 -DSYSTEMD_FSCK_PATH=\"$(rootlibexecdir)/systemd-fsck\" \
203 -DSYSTEMD_SHUTDOWN_BINARY_PATH=\"$(rootlibexecdir)/systemd-shutdown\" \
204 -DSYSTEMD_SLEEP_BINARY_PATH=\"$(rootlibexecdir)/systemd-sleep\" \
205 -DSYSTEMCTL_BINARY_PATH=\"$(rootbindir)/systemctl\" \
206 -DSYSTEMD_TTY_ASK_PASSWORD_AGENT_BINARY_PATH=\"$(rootbindir)/systemd-tty-ask-password-agent\" \
207 -DSYSTEMD_STDIO_BRIDGE_BINARY_PATH=\"$(bindir)/systemd-stdio-bridge\" \
208 -DROOTPREFIX=\"$(rootprefix)\" \
209 -DRANDOM_SEED_DIR=\"$(localstatedir)/lib/systemd/\" \
210 -DRANDOM_SEED=\"$(localstatedir)/lib/systemd/random-seed\" \
211 -DSYSTEMD_CRYPTSETUP_PATH=\"$(rootlibexecdir)/systemd-cryptsetup\" \
212 -DSYSTEM_GENERATOR_PATH=\"$(systemgeneratordir)\" \
213 -DUSER_GENERATOR_PATH=\"$(usergeneratordir)\" \
214 -DSYSTEM_ENV_GENERATOR_PATH=\"$(systemenvgeneratordir)\" \
215 -DUSER_ENV_GENERATOR_PATH=\"$(userenvgeneratordir)\" \
216 -DSYSTEM_SHUTDOWN_PATH=\"$(systemshutdowndir)\" \
217 -DSYSTEM_SLEEP_PATH=\"$(systemsleepdir)\" \
218 -DSYSTEMD_KBD_MODEL_MAP=\"$(pkgdatadir)/kbd-model-map\" \
219 -DSYSTEMD_LANGUAGE_FALLBACK_MAP=\"$(pkgdatadir)/language-fallback-map\" \
220 -DUDEVLIBEXECDIR=\"$(udevlibexecdir)\" \
221 -DPOLKIT_AGENT_BINARY_PATH=\"$(bindir)/pkttyagent\" \
222 -DQUOTACHECK=\"$(QUOTACHECK)\" \
223 -DKEXEC=\"$(KEXEC)\" \
224 -DMOUNT_PATH=\"$(MOUNT_PATH)\" \
225 -DUMOUNT_PATH=\"$(UMOUNT_PATH)\" \
226 -DLIBDIR=\"$(libdir)\" \
227 -DROOTLIBDIR=\"$(rootlibdir)\" \
228 -DROOTLIBEXECDIR=\"$(rootlibexecdir)\" \
229 -I $(top_srcdir)/src \
230 -I $(top_builddir)/src/basic \
231 -I $(top_srcdir)/src/basic \
232 -I $(top_srcdir)/src/shared \
233 -I $(top_builddir)/src/shared \
234 -I $(top_srcdir)/src/network \
235 -I $(top_srcdir)/src/locale \
236 -I $(top_srcdir)/src/login \
237 -I $(top_srcdir)/src/journal \
238 -I $(top_builddir)/src/journal \
239 -I $(top_srcdir)/src/timedate \
240 -I $(top_srcdir)/src/timesync \
241 -I $(top_srcdir)/src/nspawn \
242 -I $(top_srcdir)/src/resolve \
243 -I $(top_builddir)/src/resolve \
244 -I $(top_srcdir)/src/systemd \
245 -I $(top_builddir)/src/core \
246 -I $(top_srcdir)/src/core \
247 -I $(top_srcdir)/src/libudev \
248 -I $(top_srcdir)/src/udev \
249 -I $(top_srcdir)/src/udev/net \
250 -I $(top_builddir)/src/udev \
251 -I $(top_srcdir)/src/libsystemd/sd-bus \
252 -I $(top_srcdir)/src/libsystemd/sd-event \
253 -I $(top_srcdir)/src/libsystemd/sd-login \
254 -I $(top_srcdir)/src/libsystemd/sd-netlink \
255 -I $(top_srcdir)/src/libsystemd/sd-network \
256 -I $(top_srcdir)/src/libsystemd/sd-hwdb \
257 -I $(top_srcdir)/src/libsystemd/sd-device \
258 -I $(top_srcdir)/src/libsystemd/sd-id128 \
259 -I $(top_srcdir)/src/libsystemd-network \
260 -DABS_SRC_DIR=\"$(abs_top_srcdir)\" \
261 -DABS_BUILD_DIR=\"$(abs_top_builddir)\" \
262 $(OUR_CPPFLAGS)
263
264 AM_CFLAGS = $(OUR_CFLAGS)
265 AM_LDFLAGS = $(OUR_LDFLAGS)
266
267 # ------------------------------------------------------------------------------
268 INSTALL_DIRS =
269
270 SHUTDOWN_TARGET_WANTS =
271 LOCAL_FS_TARGET_WANTS =
272 MULTI_USER_TARGET_WANTS =
273 GRAPHICAL_TARGET_WANTS =
274 RESCUE_TARGET_WANTS =
275 SYSINIT_TARGET_WANTS =
276 SOCKETS_TARGET_WANTS =
277 BUSNAMES_TARGET_WANTS =
278 TIMERS_TARGET_WANTS =
279 USER_SOCKETS_TARGET_WANTS =
280 USER_DEFAULT_TARGET_WANTS =
281 USER_BUSNAMES_TARGET_WANTS =
282
283 SYSTEM_UNIT_ALIASES =
284 USER_UNIT_ALIASES =
285 GENERAL_ALIASES =
286
287 install-target-wants-hook:
288 what="$(SHUTDOWN_TARGET_WANTS)" && wants=shutdown.target && dir=$(systemunitdir) && $(add-wants)
289 what="$(LOCAL_FS_TARGET_WANTS)" && wants=local-fs.target && dir=$(systemunitdir) && $(add-wants)
290 what="$(MULTI_USER_TARGET_WANTS)" && wants=multi-user.target && dir=$(systemunitdir) && $(add-wants)
291 what="$(GRAPHICAL_TARGET_WANTS)" && wants=graphical.target && dir=$(systemunitdir) && $(add-wants)
292 what="$(RESCUE_TARGET_WANTS)" && wants=rescue.target && dir=$(systemunitdir) && $(add-wants)
293 what="$(SYSINIT_TARGET_WANTS)" && wants=sysinit.target && dir=$(systemunitdir) && $(add-wants)
294 what="$(SOCKETS_TARGET_WANTS)" && wants=sockets.target && dir=$(systemunitdir) && $(add-wants)
295 what="$(TIMERS_TARGET_WANTS)" && wants=timers.target && dir=$(systemunitdir) && $(add-wants)
296 what="$(SLICES_TARGET_WANTS)" && wants=slices.target && dir=$(systemunitdir) && $(add-wants)
297 what="$(USER_SOCKETS_TARGET_WANTS)" && wants=sockets.target && dir=$(userunitdir) && $(add-wants)
298 what="$(USER_DEFAULT_TARGET_WANTS)" && wants=default.target && dir=$(userunitdir) && $(add-wants)
299
300 install-busnames-target-wants-hook:
301 what="$(BUSNAMES_TARGET_WANTS)" && wants=busnames.target && dir=$(systemunitdir) && $(add-wants)
302 what="$(USER_BUSNAMES_TARGET_WANTS)" && wants=busnames.target && dir=$(userunitdir) && $(add-wants)
303
304 define add-wants
305 [ -z "$$what" ] || ( \
306 dir=$(DESTDIR)$$dir/$$wants.wants && \
307 $(MKDIR_P) -m 0755 $$dir && \
308 cd $$dir && \
309 rm -f $$what && \
310 for i in $$what; do $(LN_S) ../$$i . || exit $$? ; done )
311 endef
312
313 install-directories-hook:
314 $(MKDIR_P) $(addprefix $(DESTDIR),$(INSTALL_DIRS))
315
316 install-environment-conf-hook: install-directories-hook
317 $(AM_V_LN)$(LN_S) --relative -f $(DESTDIR)$(sysconfdir)/environment \
318 $(DESTDIR)$(environmentdir)/99-environment.conf
319
320 install-aliases-hook:
321 set -- $(SYSTEM_UNIT_ALIASES) && \
322 dir=$(systemunitdir) && $(install-aliases)
323 set -- $(USER_UNIT_ALIASES) && \
324 dir=$(userunitdir) && $(install-relative-aliases)
325 set -- $(GENERAL_ALIASES) && \
326 dir= && $(install-relative-aliases)
327
328 define install-aliases
329 while [ -n "$$1" ]; do \
330 $(MKDIR_P) `dirname $(DESTDIR)$$dir/$$2` && \
331 rm -f $(DESTDIR)$$dir/$$2 && \
332 $(LN_S) $$1 $(DESTDIR)$$dir/$$2 && \
333 shift 2 || exit $$?; \
334 done
335 endef
336
337 define install-relative-aliases
338 while [ -n "$$1" ]; do \
339 $(MKDIR_P) `dirname $(DESTDIR)$$dir/$$2` && \
340 rm -f $(DESTDIR)$$dir/$$2 && \
341 $(LN_S) --relative $(DESTDIR)$$1 $(DESTDIR)$$dir/$$2 && \
342 shift 2 || exit $$?; \
343 done
344 endef
345
346 install-touch-usr-hook:
347 touch -c $(DESTDIR)/$(prefix)
348
349 INSTALL_EXEC_HOOKS += \
350 install-target-wants-hook \
351 install-directories-hook \
352 install-aliases-hook \
353 install-touch-usr-hook \
354 install-busnames-target-wants-hook
355
356 if ENABLE_ENVIRONMENT_D
357 INSTALL_EXEC_HOOKS += \
358 install-environment-conf-hook
359 endif
360
361 # ------------------------------------------------------------------------------
362 AM_V_M4 = $(AM_V_M4_$(V))
363 AM_V_M4_ = $(AM_V_M4_$(AM_DEFAULT_VERBOSITY))
364 AM_V_M4_0 = @echo " M4 " $@;
365
366 AM_V_XSLT = $(AM_V_XSLT_$(V))
367 AM_V_XSLT_ = $(AM_V_XSLT_$(AM_DEFAULT_VERBOSITY))
368 AM_V_XSLT_0 = @echo " XSLT " $@;
369
370 AM_V_GPERF = $(AM_V_GPERF_$(V))
371 AM_V_GPERF_ = $(AM_V_GPERF_$(AM_DEFAULT_VERBOSITY))
372 AM_V_GPERF_0 = @echo " GPERF " $@;
373
374 AM_V_LN = $(AM_V_LN_$(V))
375 AM_V_LN_ = $(AM_V_LN_$(AM_DEFAULT_VERBOSITY))
376 AM_V_LN_0 = @echo " LN " $@;
377
378 AM_V_RM = $(AM_V_RM_$(V))
379 AM_V_RM_ = $(AM_V_RM_$(AM_DEFAULT_VERBOSITY))
380 AM_V_RM_0 = @echo " RM " $@;
381
382 # ------------------------------------------------------------------------------
383 rootbin_PROGRAMS = \
384 systemctl \
385 systemd-notify \
386 systemd-ask-password \
387 systemd-tty-ask-password-agent \
388 systemd-machine-id-setup \
389 systemd-escape
390
391 bin_PROGRAMS = \
392 systemd-cgls \
393 systemd-cgtop \
394 systemd-nspawn \
395 systemd-detect-virt \
396 systemd-delta \
397 systemd-analyze \
398 systemd-run \
399 systemd-mount \
400 systemd-stdio-bridge \
401 systemd-path
402
403 dist_bin_SCRIPTS = \
404 src/kernel-install/kernel-install
405
406 dist_kernelinstall_SCRIPTS = \
407 src/kernel-install/50-depmod.install \
408 src/kernel-install/90-loaderentry.install
409
410 rootlibexec_PROGRAMS = \
411 systemd \
412 systemd-cgroups-agent \
413 systemd-initctl \
414 systemd-shutdown \
415 systemd-remount-fs \
416 systemd-volatile-root \
417 systemd-reply-password \
418 systemd-fsck \
419 systemd-ac-power \
420 systemd-sysctl \
421 systemd-sleep \
422 systemd-socket-proxyd \
423 systemd-update-done
424
425 if HAVE_BLKID
426 rootlibexec_PROGRAMS += \
427 systemd-dissect
428 endif
429
430 if HAVE_UTMP
431 rootlibexec_PROGRAMS += \
432 systemd-update-utmp
433 endif
434
435 systemgenerator_PROGRAMS = \
436 systemd-getty-generator \
437 systemd-fstab-generator \
438 systemd-system-update-generator \
439 systemd-debug-generator
440
441 if ENABLE_ENVIRONMENT_D
442 userenvgenerator_PROGRAMS = \
443 30-systemd-environment-d-generator
444 endif
445
446 rootlibexec_SCRIPTS = \
447 src/sulogin-shell/systemd-sulogin-shell
448
449 EXTRA_DIST += \
450 src/sulogin-shell/systemd-sulogin-shell.in
451
452 dist_bashcompletion_data = \
453 shell-completion/bash/busctl \
454 shell-completion/bash/journalctl \
455 shell-completion/bash/systemd-analyze \
456 shell-completion/bash/systemd-cat \
457 shell-completion/bash/systemd-cgls \
458 shell-completion/bash/systemd-cgtop \
459 shell-completion/bash/systemd-delta \
460 shell-completion/bash/systemd-detect-virt \
461 shell-completion/bash/systemd-nspawn \
462 shell-completion/bash/systemd-path \
463 shell-completion/bash/systemd-run \
464 shell-completion/bash/udevadm \
465 shell-completion/bash/kernel-install
466
467 nodist_bashcompletion_data = \
468 shell-completion/bash/systemctl
469
470 dist_zshcompletion_data = \
471 shell-completion/zsh/_busctl \
472 shell-completion/zsh/_journalctl \
473 shell-completion/zsh/_udevadm \
474 shell-completion/zsh/_kernel-install \
475 shell-completion/zsh/_systemd-nspawn \
476 shell-completion/zsh/_systemd-analyze \
477 shell-completion/zsh/_systemd-run \
478 shell-completion/zsh/_sd_hosts_or_user_at_host \
479 shell-completion/zsh/_sd_outputmodes \
480 shell-completion/zsh/_sd_unit_files \
481 shell-completion/zsh/_systemd-delta \
482 shell-completion/zsh/_systemd
483
484 nodist_zshcompletion_data = \
485 shell-completion/zsh/_systemctl
486
487 EXTRA_DIST += \
488 shell-completion/bash/systemctl.in \
489 shell-completion/zsh/_systemctl.in
490
491 dist_sysctl_DATA = \
492 sysctl.d/50-default.conf
493
494 dist_systemunit_DATA = \
495 units/graphical.target \
496 units/multi-user.target \
497 units/emergency.target \
498 units/sysinit.target \
499 units/basic.target \
500 units/getty.target \
501 units/halt.target \
502 units/kexec.target \
503 units/exit.target \
504 units/local-fs.target \
505 units/local-fs-pre.target \
506 units/initrd.target \
507 units/initrd-fs.target \
508 units/initrd-root-device.target \
509 units/initrd-root-fs.target \
510 units/remote-fs.target \
511 units/remote-fs-pre.target \
512 units/network.target \
513 units/network-pre.target \
514 units/network-online.target \
515 units/nss-lookup.target \
516 units/nss-user-lookup.target \
517 units/poweroff.target \
518 units/reboot.target \
519 units/rescue.target \
520 units/rpcbind.target \
521 units/time-sync.target \
522 units/shutdown.target \
523 units/final.target \
524 units/umount.target \
525 units/sigpwr.target \
526 units/sleep.target \
527 units/sockets.target \
528 units/timers.target \
529 units/paths.target \
530 units/suspend.target \
531 units/swap.target \
532 units/slices.target \
533 units/system.slice \
534 units/systemd-initctl.socket \
535 units/syslog.socket \
536 units/dev-hugepages.mount \
537 units/dev-mqueue.mount \
538 units/sys-kernel-config.mount \
539 units/sys-kernel-debug.mount \
540 units/sys-fs-fuse-connections.mount \
541 units/tmp.mount \
542 units/var-lib-machines.mount \
543 units/printer.target \
544 units/sound.target \
545 units/bluetooth.target \
546 units/smartcard.target \
547 units/systemd-ask-password-wall.path \
548 units/systemd-ask-password-console.path \
549 units/systemd-udevd-control.socket \
550 units/systemd-udevd-kernel.socket \
551 units/system-update.target \
552 units/initrd-switch-root.target \
553 units/machines.target
554
555 dist_systemunit_DATA += \
556 $(dist_systemunit_DATA_busnames)
557
558 dist_systemunit_DATA_busnames += \
559 units/busnames.target
560
561 nodist_systemunit_DATA = \
562 units/getty@.service \
563 units/serial-getty@.service \
564 units/console-getty.service \
565 units/container-getty@.service \
566 units/system-update-cleanup.service \
567 units/systemd-initctl.service \
568 units/systemd-remount-fs.service \
569 units/systemd-volatile-root.service \
570 units/systemd-ask-password-wall.service \
571 units/systemd-ask-password-console.service \
572 units/systemd-sysctl.service \
573 units/emergency.service \
574 units/rescue.service \
575 units/user@.service \
576 units/systemd-suspend.service \
577 units/systemd-halt.service \
578 units/systemd-poweroff.service \
579 units/systemd-reboot.service \
580 units/systemd-kexec.service \
581 units/systemd-exit.service \
582 units/systemd-fsck@.service \
583 units/systemd-fsck-root.service \
584 units/systemd-machine-id-commit.service \
585 units/systemd-udevd.service \
586 units/systemd-udev-trigger.service \
587 units/systemd-udev-settle.service \
588 units/systemd-hwdb-update.service \
589 units/debug-shell.service \
590 units/initrd-parse-etc.service \
591 units/initrd-cleanup.service \
592 units/initrd-udevadm-cleanup-db.service \
593 units/initrd-switch-root.service \
594 units/systemd-nspawn@.service \
595 units/systemd-update-done.service
596
597 if HAVE_UTMP
598 nodist_systemunit_DATA += \
599 units/systemd-update-utmp.service \
600 units/systemd-update-utmp-runlevel.service
601 endif
602
603 dist_userunit_DATA = \
604 units/user/basic.target \
605 units/user/default.target \
606 units/user/exit.target \
607 units/user/graphical-session.target \
608 units/user/graphical-session-pre.target \
609 units/user/bluetooth.target \
610 units/user/busnames.target \
611 units/user/paths.target \
612 units/user/printer.target \
613 units/user/shutdown.target \
614 units/user/smartcard.target \
615 units/user/sockets.target \
616 units/user/sound.target \
617 units/user/timers.target
618
619 nodist_userunit_DATA = \
620 units/user/systemd-exit.service
621
622 dist_systempreset_DATA = \
623 system-preset/90-systemd.preset
624
625 EXTRA_DIST += \
626 units/getty@.service.m4 \
627 units/serial-getty@.service.m4 \
628 units/console-getty.service.m4.in \
629 units/container-getty@.service.m4.in \
630 units/rescue.service.in \
631 units/system-update-cleanup.service.in \
632 units/systemd-initctl.service.in \
633 units/systemd-remount-fs.service.in \
634 units/systemd-volatile-root.service.in \
635 units/systemd-update-utmp.service.in \
636 units/systemd-update-utmp-runlevel.service.in \
637 units/systemd-ask-password-wall.service.in \
638 units/systemd-ask-password-console.service.in \
639 units/systemd-sysctl.service.in \
640 units/emergency.service.in \
641 units/systemd-halt.service.in \
642 units/systemd-poweroff.service.in \
643 units/systemd-reboot.service.in \
644 units/systemd-kexec.service.in \
645 units/systemd-exit.service.in \
646 units/user/systemd-exit.service.in \
647 units/systemd-fsck@.service.in \
648 units/systemd-fsck-root.service.in \
649 units/systemd-machine-id-commit.service.in \
650 units/user@.service.m4.in \
651 units/debug-shell.service.in \
652 units/systemd-suspend.service.in \
653 units/quotaon.service.in \
654 units/initrd-parse-etc.service.in \
655 units/initrd-cleanup.service.in \
656 units/initrd-udevadm-cleanup-db.service.in \
657 units/initrd-switch-root.service.in \
658 units/systemd-nspawn@.service.in \
659 units/systemd-update-done.service.in \
660 units/tmp.mount.m4
661
662 if HAVE_SYSV_COMPAT
663 nodist_systemunit_DATA += \
664 units/rc-local.service \
665 units/halt-local.service
666
667 systemgenerator_PROGRAMS += \
668 systemd-sysv-generator \
669 systemd-rc-local-generator
670 endif
671
672 EXTRA_DIST += \
673 src/systemctl/systemd-sysv-install.SKELETON \
674 units/rc-local.service.in \
675 units/halt-local.service.in
676
677 GENERAL_ALIASES += \
678 $(systemunitdir)/machines.target $(pkgsysconfdir)/system/multi-user.target.wants/machines.target
679
680 dist_doc_DATA = \
681 README \
682 NEWS \
683 CODING_STYLE \
684 LICENSE.LGPL2.1 \
685 LICENSE.GPL2 \
686 DISTRO_PORTING \
687 src/libsystemd/sd-bus/GVARIANT-SERIALIZATION
688
689 EXTRA_DIST += \
690 README.md \
691 autogen.sh \
692 .dir-locals.el \
693 .editorconfig \
694 .vimrc \
695 .ycm_extra_conf.py \
696 .travis.yml \
697 .mailmap
698
699 @INTLTOOL_POLICY_RULE@
700
701 systemd-mount-install-hook:
702 -$(LN_S) systemd-mount $(DESTDIR)$(bindir)/systemd-umount
703
704 systemd-mount-uninstall-hook:
705 -rm $(DESTDIR)$(bindir)/systemd-umount
706
707 INSTALL_EXEC_HOOKS += systemd-mount-install-hook
708 UNINSTALL_EXEC_HOOKS += systemd-mount-uninstall-hook
709
710 # ------------------------------------------------------------------------------
711
712 MANPAGES =
713 MANPAGES_ALIAS =
714
715 include Makefile-man.am
716
717 .PHONY: man update-man-list
718 man: $(MANPAGES) $(MANPAGES_ALIAS) $(HTML_FILES) $(HTML_ALIAS)
719
720 XML_FILES = \
721 ${patsubst %.1,%.xml,${patsubst %.3,%.xml,${patsubst %.5,%.xml,${patsubst %.7,%.xml,${patsubst %.8,%.xml,$(MANPAGES)}}}}}
722 HTML_FILES = \
723 ${XML_FILES:.xml=.html}
724 HTML_ALIAS = \
725 ${patsubst %.1,%.html,${patsubst %.3,%.html,${patsubst %.5,%.html,${patsubst %.7,%.html,${patsubst %.8,%.html,$(MANPAGES_ALIAS)}}}}}
726
727 if ENABLE_MANPAGES
728 man_MANS = \
729 $(MANPAGES) \
730 $(MANPAGES_ALIAS)
731
732 noinst_DATA += \
733 $(HTML_FILES) \
734 $(HTML_ALIAS) \
735 docs/html/man
736 endif
737
738 CLEANFILES += \
739 $(man_MANS) \
740 $(HTML_FILES) \
741 $(HTML_ALIAS) \
742 docs/html/man
743
744 docs/html/man:
745 $(AM_V_at)$(MKDIR_P) $(dir $@)
746 $(AM_V_LN)$(LN_S) -f ../../man $@
747
748 man/index.html: man/systemd.index.html
749 $(AM_V_LN)$(LN_S) -f systemd.index.html $@
750
751 if HAVE_PYTHON
752 if ENABLE_MANPAGES
753 noinst_DATA += \
754 man/index.html
755 endif
756 endif
757
758 CLEANFILES += \
759 man/index.html
760
761 XML_GLOB = $(wildcard $(top_srcdir)/man/*.xml)
762 NON_INDEX_XML_FILES = $(filter-out man/systemd.index.xml,$(XML_FILES))
763 SOURCE_XML_FILES = ${patsubst %,$(top_srcdir)/%,$(filter-out man/systemd.directives.xml,$(NON_INDEX_XML_FILES))}
764
765 # This target should only be run manually. It recreates Makefile-man.am
766 # file in the source directory based on all man/*.xml files. Run it after
767 # adding, removing, or changing the conditional in a man page.
768 update-man-list: $(top_srcdir)/tools/make-man-rules.py $(XML_GLOB) man/custom-entities.ent
769 $(AM_V_GEN)$(PYTHON) $< $(XML_GLOB) > $(top_srcdir)/Makefile-man.tmp
770 $(AM_V_at)mv $(top_srcdir)/Makefile-man.tmp $(top_srcdir)/Makefile-man.am
771 @echo "Makefile-man.am has been regenerated"
772
773 man/systemd.index.xml: $(top_srcdir)/tools/make-man-index.py $(NON_INDEX_XML_FILES)
774 $(AM_V_at)$(MKDIR_P) $(dir $@)
775 $(AM_V_GEN)$(PYTHON) $< $@ $(filter-out $<,$^)
776
777 man/systemd.directives.xml: $(top_srcdir)/tools/make-directive-index.py man/custom-entities.ent $(SOURCE_XML_FILES)
778 $(AM_V_at)$(MKDIR_P) $(dir $@)
779 $(AM_V_GEN)$(PYTHON) $< $@ $(SOURCE_XML_FILES)
780
781 CLEANFILES += \
782 man/systemd.index.xml \
783 man/systemd.directives.xml
784
785 EXTRA_DIST += \
786 $(filter-out man/systemd.directives.xml man/systemd.index.xml,$(XML_FILES)) \
787 tools/make-man-index.py \
788 tools/make-man-rules.py \
789 tools/make-directive-index.py \
790 tools/xml_helper.py \
791 man/glib-event-glue.c \
792 man/50-xdg-data-dirs.sh \
793 man/90-rearrange-path.py
794
795 # ------------------------------------------------------------------------------
796 noinst_LTLIBRARIES += \
797 libbasic.la
798
799 libbasic_la_SOURCES = \
800 src/basic/missing.h \
801 src/basic/missing_syscall.h \
802 src/basic/raw-clone.h \
803 src/basic/capability-util.c \
804 src/basic/capability-util.h \
805 src/basic/conf-files.c \
806 src/basic/conf-files.h \
807 src/basic/stdio-util.h \
808 src/basic/hostname-util.h \
809 src/basic/hostname-util.c \
810 src/basic/unit-name.c \
811 src/basic/unit-name.h \
812 src/basic/ioprio.h \
813 src/basic/securebits.h \
814 src/basic/special.h \
815 src/basic/list.h \
816 src/basic/unaligned.h \
817 src/basic/macro.h \
818 src/basic/def.h \
819 src/basic/sparse-endian.h \
820 src/basic/refcnt.h \
821 src/basic/util.c \
822 src/basic/util.h \
823 src/basic/io-util.c \
824 src/basic/io-util.h \
825 src/basic/string-util.c \
826 src/basic/string-util.h \
827 src/basic/fd-util.c \
828 src/basic/fd-util.h \
829 src/basic/parse-util.c \
830 src/basic/parse-util.h \
831 src/basic/user-util.c \
832 src/basic/user-util.h \
833 src/basic/rlimit-util.c \
834 src/basic/rlimit-util.h \
835 src/basic/dirent-util.c \
836 src/basic/dirent-util.h \
837 src/basic/xattr-util.c \
838 src/basic/xattr-util.h \
839 src/basic/chattr-util.c \
840 src/basic/chattr-util.h \
841 src/basic/proc-cmdline.c \
842 src/basic/proc-cmdline.h \
843 src/basic/fs-util.c \
844 src/basic/fs-util.h \
845 src/basic/syslog-util.c \
846 src/basic/syslog-util.h \
847 src/basic/stat-util.c \
848 src/basic/stat-util.h \
849 src/basic/mount-util.c \
850 src/basic/mount-util.h \
851 src/basic/hexdecoct.c \
852 src/basic/hexdecoct.h \
853 src/basic/glob-util.h \
854 src/basic/glob-util.c \
855 src/basic/extract-word.c \
856 src/basic/extract-word.h \
857 src/basic/escape.c \
858 src/basic/escape.h \
859 src/basic/cpu-set-util.c \
860 src/basic/cpu-set-util.h \
861 src/basic/lockfile-util.c \
862 src/basic/lockfile-util.h \
863 src/basic/path-util.c \
864 src/basic/path-util.h \
865 src/basic/time-util.c \
866 src/basic/time-util.h \
867 src/basic/locale-util.c \
868 src/basic/locale-util.h \
869 src/basic/umask-util.h \
870 src/basic/signal-util.c \
871 src/basic/signal-util.h \
872 src/basic/string-table.c \
873 src/basic/string-table.h \
874 src/basic/mempool.c \
875 src/basic/mempool.h \
876 src/basic/hashmap.c \
877 src/basic/hashmap.h \
878 src/basic/hash-funcs.c \
879 src/basic/hash-funcs.h \
880 src/basic/siphash24.c \
881 src/basic/siphash24.h \
882 src/basic/set.h \
883 src/basic/ordered-set.h \
884 src/basic/ordered-set.c \
885 src/basic/bitmap.c \
886 src/basic/bitmap.h \
887 src/basic/prioq.c \
888 src/basic/prioq.h \
889 src/basic/web-util.c \
890 src/basic/web-util.h \
891 src/basic/strv.c \
892 src/basic/strv.h \
893 src/basic/env-util.c \
894 src/basic/env-util.h \
895 src/basic/strbuf.c \
896 src/basic/strbuf.h \
897 src/basic/strxcpyx.c \
898 src/basic/strxcpyx.h \
899 src/basic/log.c \
900 src/basic/log.h \
901 src/basic/bus-label.c \
902 src/basic/bus-label.h \
903 src/basic/ratelimit.h \
904 src/basic/ratelimit.c \
905 src/basic/exec-util.c \
906 src/basic/exec-util.h \
907 src/basic/exit-status.c \
908 src/basic/exit-status.h \
909 src/basic/virt.c \
910 src/basic/virt.h \
911 src/basic/architecture.c \
912 src/basic/architecture.h \
913 src/basic/smack-util.c \
914 src/basic/smack-util.h \
915 src/basic/device-nodes.c \
916 src/basic/device-nodes.h \
917 src/basic/utf8.c \
918 src/basic/utf8.h \
919 src/basic/gunicode.c \
920 src/basic/gunicode.h \
921 src/basic/socket-util.c \
922 src/basic/socket-util.h \
923 src/basic/in-addr-util.c \
924 src/basic/in-addr-util.h \
925 src/basic/ether-addr-util.h \
926 src/basic/ether-addr-util.c \
927 src/basic/replace-var.c \
928 src/basic/replace-var.h \
929 src/basic/clock-util.c \
930 src/basic/clock-util.h \
931 src/basic/calendarspec.c \
932 src/basic/calendarspec.h \
933 src/basic/fileio.c \
934 src/basic/fileio.h \
935 src/basic/MurmurHash2.c \
936 src/basic/MurmurHash2.h \
937 src/basic/mkdir.c \
938 src/basic/mkdir.h \
939 src/basic/cgroup-util.c \
940 src/basic/cgroup-util.h \
941 src/basic/errno-list.c \
942 src/basic/errno-list.h \
943 src/basic/af-list.c \
944 src/basic/af-list.h \
945 src/basic/arphrd-list.c \
946 src/basic/arphrd-list.h \
947 src/basic/terminal-util.c \
948 src/basic/terminal-util.h \
949 src/basic/login-util.h \
950 src/basic/login-util.c \
951 src/basic/cap-list.c \
952 src/basic/cap-list.h \
953 src/basic/audit-util.c \
954 src/basic/audit-util.h \
955 src/basic/xml.c \
956 src/basic/xml.h \
957 src/basic/barrier.c \
958 src/basic/barrier.h \
959 src/basic/async.c \
960 src/basic/async.h \
961 src/basic/memfd-util.c \
962 src/basic/memfd-util.h \
963 src/basic/process-util.c \
964 src/basic/process-util.h \
965 src/basic/random-util.c \
966 src/basic/random-util.h \
967 src/basic/verbs.c \
968 src/basic/verbs.h \
969 src/basic/sigbus.c \
970 src/basic/sigbus.h \
971 src/basic/build.h \
972 src/basic/socket-label.c \
973 src/basic/label.c \
974 src/basic/label.h \
975 src/basic/btrfs-util.c \
976 src/basic/btrfs-util.h \
977 src/basic/btrfs-ctree.h \
978 src/basic/selinux-util.c \
979 src/basic/selinux-util.h \
980 src/basic/mkdir-label.c \
981 src/basic/fileio-label.c \
982 src/basic/fileio-label.h \
983 src/basic/rm-rf.c \
984 src/basic/rm-rf.h \
985 src/basic/copy.c \
986 src/basic/copy.h \
987 src/basic/alloc-util.h \
988 src/basic/alloc-util.c \
989 src/basic/format-util.h \
990 src/basic/nss-util.h \
991 src/basic/khash.h \
992 src/basic/khash.c \
993 src/basic/journal-importer.h \
994 src/basic/journal-importer.c
995
996 nodist_libbasic_la_SOURCES = \
997 src/basic/errno-from-name.h \
998 src/basic/errno-to-name.h \
999 src/basic/af-from-name.h \
1000 src/basic/af-to-name.h \
1001 src/basic/arphrd-from-name.h \
1002 src/basic/arphrd-to-name.h \
1003 src/basic/cap-from-name.h \
1004 src/basic/cap-to-name.h
1005
1006 libbasic_la_CFLAGS = \
1007 $(AM_CFLAGS) \
1008 $(SELINUX_CFLAGS) \
1009 $(CAP_CFLAGS) \
1010 -pthread
1011
1012 libbasic_la_LIBADD = \
1013 $(SELINUX_LIBS) \
1014 $(CAP_LIBS) \
1015 -lrt
1016
1017 # -----------------------------------------------------------------------------
1018 noinst_LTLIBRARIES += \
1019 libshared.la
1020
1021 libshared_la_SOURCES = \
1022 src/shared/output-mode.h \
1023 src/shared/output-mode.c \
1024 src/shared/gpt.h \
1025 src/shared/udev-util.h \
1026 src/shared/linux/auto_dev-ioctl.h \
1027 src/shared/linux-3.13/dm-ioctl.h \
1028 src/shared/initreq.h \
1029 src/shared/dns-domain.c \
1030 src/shared/dns-domain.h \
1031 src/shared/efivars.c \
1032 src/shared/efivars.h \
1033 src/shared/fstab-util.c \
1034 src/shared/fstab-util.h \
1035 src/shared/sleep-config.c \
1036 src/shared/sleep-config.h \
1037 src/shared/conf-parser.c \
1038 src/shared/conf-parser.h \
1039 src/shared/pager.c \
1040 src/shared/pager.h \
1041 src/shared/spawn-polkit-agent.c \
1042 src/shared/spawn-polkit-agent.h \
1043 src/shared/apparmor-util.c \
1044 src/shared/apparmor-util.h \
1045 src/shared/ima-util.c \
1046 src/shared/ima-util.h \
1047 src/shared/journal-util.c \
1048 src/shared/journal-util.h \
1049 src/shared/ptyfwd.c \
1050 src/shared/ptyfwd.h \
1051 src/shared/base-filesystem.c \
1052 src/shared/base-filesystem.h \
1053 src/shared/uid-range.c \
1054 src/shared/uid-range.h \
1055 src/shared/install.c \
1056 src/shared/install.h \
1057 src/shared/install-printf.c \
1058 src/shared/install-printf.h \
1059 src/shared/path-lookup.c \
1060 src/shared/path-lookup.h \
1061 src/shared/specifier.c \
1062 src/shared/specifier.h \
1063 src/shared/dev-setup.c \
1064 src/shared/dev-setup.h \
1065 src/shared/dropin.c \
1066 src/shared/dropin.h \
1067 src/shared/condition.c \
1068 src/shared/condition.h \
1069 src/shared/clean-ipc.c \
1070 src/shared/clean-ipc.h \
1071 src/shared/generator.h \
1072 src/shared/generator.c \
1073 src/shared/acpi-fpdt.h \
1074 src/shared/acpi-fpdt.c \
1075 src/shared/boot-timestamps.h \
1076 src/shared/boot-timestamps.c \
1077 src/shared/cgroup-show.c \
1078 src/shared/cgroup-show.h \
1079 src/shared/utmp-wtmp.h \
1080 src/shared/watchdog.c \
1081 src/shared/watchdog.h \
1082 src/shared/spawn-ask-password-agent.c \
1083 src/shared/spawn-ask-password-agent.h \
1084 src/shared/ask-password-api.c \
1085 src/shared/ask-password-api.h \
1086 src/shared/switch-root.h \
1087 src/shared/switch-root.c \
1088 src/shared/import-util.c \
1089 src/shared/import-util.h \
1090 src/shared/sysctl-util.c \
1091 src/shared/sysctl-util.h \
1092 src/shared/bus-util.c \
1093 src/shared/bus-util.h \
1094 src/shared/logs-show.c \
1095 src/shared/logs-show.h \
1096 src/shared/machine-image.c \
1097 src/shared/machine-image.h \
1098 src/shared/machine-pool.c \
1099 src/shared/machine-pool.h \
1100 src/shared/loop-util.c \
1101 src/shared/loop-util.h \
1102 src/shared/resolve-util.c \
1103 src/shared/resolve-util.h \
1104 src/shared/bus-unit-util.c \
1105 src/shared/bus-unit-util.h \
1106 src/shared/vlan-util.h \
1107 src/shared/vlan-util.c \
1108 src/shared/tests.h \
1109 src/shared/tests.c \
1110 src/shared/fdset.c \
1111 src/shared/fdset.h \
1112 src/shared/nsflags.h \
1113 src/shared/nsflags.c \
1114 src/shared/dissect-image.c \
1115 src/shared/dissect-image.h \
1116 src/shared/volatile-util.c \
1117 src/shared/volatile-util.h
1118
1119 if HAVE_UTMP
1120 libshared_la_SOURCES += \
1121 src/shared/utmp-wtmp.c
1122 endif
1123
1124 if HAVE_SECCOMP
1125 libshared_la_SOURCES += \
1126 src/shared/seccomp-util.h \
1127 src/shared/seccomp-util.c
1128 endif
1129
1130 if HAVE_ACL
1131 libshared_la_SOURCES += \
1132 src/shared/acl-util.c \
1133 src/shared/acl-util.h
1134 endif
1135
1136 libshared_la_CFLAGS = \
1137 $(AM_CFLAGS) \
1138 $(ACL_CFLAGS) \
1139 $(LIBIDN_CFLAGS) \
1140 $(SECCOMP_CFLAGS) \
1141 $(BLKID_CFLAGS) \
1142 $(LIBCRYPTSETUP_CFLAGS)
1143
1144 libshared_la_LIBADD = \
1145 libsystemd-internal.la \
1146 libbasic.la \
1147 libsystemd-journal-internal.la \
1148 libudev-internal.la \
1149 $(ACL_LIBS) \
1150 $(LIBIDN_LIBS) \
1151 $(SECCOMP_LIBS) \
1152 $(BLKID_LIBS) \
1153 $(LIBCRYPTSETUP_LIBS)
1154
1155 rootlibexec_LTLIBRARIES += \
1156 libsystemd-shared.la
1157
1158 libsystemd_shared_la_SOURCES = \
1159 $(libbasic_la_SOURCES) \
1160 $(libshared_la_SOURCES) \
1161 $(libsystemd_internal_la_SOURCES) \
1162 $(libsystemd_journal_internal_la_SOURCES) \
1163 $(libudev_internal_la_SOURCES)
1164
1165 libsystemd_shared_la_CFLAGS = \
1166 $(AM_CFLAGS) \
1167 $(libbasic_la_CFLAGS) \
1168 $(libshared_la_CFLAGS) \
1169 $(libsystemd_internal_la_CFLAGS) \
1170 $(libsystemd_journal_internal_la_CFLAGS) \
1171 $(libudev_internal_la_CFLAGS) \
1172 $(ACL_CFLAGS) \
1173 $(LIBIDN_CFLAGS) \
1174 $(SECCOMP_CFLAGS) \
1175 $(BLKID_CFLAGS) \
1176 $(LIBCRYPTSETUP_CFLAGS) \
1177 -fvisibility=default
1178
1179 # We can't use libshared_la_LIBADD here because it would
1180 # pull in libsystemd*-internal.la
1181 libsystemd_shared_la_LIBADD = \
1182 $(libbasic_la_LIBADD) \
1183 $(libsystemd_internal_la_LIBADD) \
1184 $(libsystemd_journal_internal_la_LIBADD) \
1185 $(libudev_internal_la_LIBADD) \
1186 $(ACL_LIBS) \
1187 $(LIBIDN_LIBS) \
1188 $(SECCOMP_LIBS) \
1189 $(BLKID_LIBS) \
1190 $(LIBCRYPTSETUP_LIBS)
1191
1192 libsystemd_shared_la_LDFLAGS = \
1193 $(AM_LDFLAGS) \
1194 -release $(PACKAGE_VERSION)
1195
1196
1197 # -----------------------------------------------------------------------------
1198 if HAVE_LIBIPTC
1199 noinst_LTLIBRARIES += \
1200 libfirewall.la
1201
1202 libfirewall_la_SOURCES = \
1203 src/shared/firewall-util.h \
1204 src/shared/firewall-util.c
1205
1206 libfirewall_la_CFLAGS = \
1207 $(AM_CFLAGS) \
1208 $(LIBIPTC_CFLAGS)
1209
1210 libfirewall_la_LIBADD = \
1211 $(LIBIPTC_LIBS)
1212 endif
1213
1214 # -----------------------------------------------------------------------------
1215 if ENABLE_LDCONFIG
1216 dist_systemunit_DATA += \
1217 units/ldconfig.service
1218
1219 SYSINIT_TARGET_WANTS += \
1220 ldconfig.service
1221 endif
1222
1223 # ------------------------------------------------------------------------------
1224 noinst_LTLIBRARIES += \
1225 libcore.la
1226
1227 libcore_la_SOURCES = \
1228 src/core/unit.c \
1229 src/core/unit.h \
1230 src/core/unit-printf.c \
1231 src/core/unit-printf.h \
1232 src/core/job.c \
1233 src/core/job.h \
1234 src/core/manager.c \
1235 src/core/manager.h \
1236 src/core/transaction.c \
1237 src/core/transaction.h \
1238 src/core/load-fragment.c \
1239 src/core/load-fragment.h \
1240 src/core/service.c \
1241 src/core/service.h \
1242 src/core/socket.c \
1243 src/core/socket.h \
1244 src/core/busname.c \
1245 src/core/busname.h \
1246 src/core/bus-policy.c \
1247 src/core/bus-policy.h \
1248 src/core/target.c \
1249 src/core/target.h \
1250 src/core/device.c \
1251 src/core/device.h \
1252 src/core/mount.c \
1253 src/core/mount.h \
1254 src/core/automount.c \
1255 src/core/automount.h \
1256 src/core/swap.c \
1257 src/core/swap.h \
1258 src/core/timer.c \
1259 src/core/timer.h \
1260 src/core/path.c \
1261 src/core/path.h \
1262 src/core/slice.c \
1263 src/core/slice.h \
1264 src/core/scope.c \
1265 src/core/scope.h \
1266 src/core/load-dropin.c \
1267 src/core/load-dropin.h \
1268 src/core/execute.c \
1269 src/core/execute.h \
1270 src/core/dynamic-user.c \
1271 src/core/dynamic-user.h \
1272 src/core/kill.c \
1273 src/core/kill.h \
1274 src/core/dbus.c \
1275 src/core/dbus.h \
1276 src/core/dbus-manager.c \
1277 src/core/dbus-manager.h \
1278 src/core/dbus-unit.c \
1279 src/core/dbus-unit.h \
1280 src/core/dbus-job.c \
1281 src/core/dbus-job.h \
1282 src/core/dbus-service.c \
1283 src/core/dbus-service.h \
1284 src/core/dbus-socket.c \
1285 src/core/dbus-socket.h \
1286 src/core/dbus-busname.c \
1287 src/core/dbus-busname.h \
1288 src/core/dbus-target.c \
1289 src/core/dbus-target.h \
1290 src/core/dbus-device.c \
1291 src/core/dbus-device.h \
1292 src/core/dbus-mount.c \
1293 src/core/dbus-mount.h \
1294 src/core/dbus-automount.c \
1295 src/core/dbus-automount.h \
1296 src/core/dbus-swap.c \
1297 src/core/dbus-swap.h \
1298 src/core/dbus-timer.c \
1299 src/core/dbus-timer.h \
1300 src/core/dbus-path.c \
1301 src/core/dbus-path.h \
1302 src/core/dbus-slice.c \
1303 src/core/dbus-slice.h \
1304 src/core/dbus-scope.c \
1305 src/core/dbus-scope.h \
1306 src/core/dbus-execute.c \
1307 src/core/dbus-execute.h \
1308 src/core/dbus-kill.c \
1309 src/core/dbus-kill.h \
1310 src/core/dbus-cgroup.c \
1311 src/core/dbus-cgroup.h \
1312 src/core/cgroup.c \
1313 src/core/cgroup.h \
1314 src/core/selinux-access.c \
1315 src/core/selinux-access.h \
1316 src/core/selinux-setup.c \
1317 src/core/selinux-setup.h \
1318 src/core/smack-setup.c \
1319 src/core/smack-setup.h \
1320 src/core/ima-setup.c \
1321 src/core/ima-setup.h \
1322 src/core/locale-setup.h \
1323 src/core/locale-setup.c \
1324 src/core/hostname-setup.c \
1325 src/core/hostname-setup.h \
1326 src/core/machine-id-setup.c \
1327 src/core/machine-id-setup.h \
1328 src/core/mount-setup.c \
1329 src/core/mount-setup.h \
1330 src/core/kmod-setup.c \
1331 src/core/kmod-setup.h \
1332 src/core/loopback-setup.h \
1333 src/core/loopback-setup.c \
1334 src/core/namespace.c \
1335 src/core/namespace.h \
1336 src/core/killall.h \
1337 src/core/killall.c \
1338 src/core/audit-fd.c \
1339 src/core/audit-fd.h \
1340 src/core/show-status.c \
1341 src/core/show-status.h \
1342 src/core/emergency-action.c \
1343 src/core/emergency-action.h
1344
1345 nodist_libcore_la_SOURCES = \
1346 src/core/load-fragment-gperf.c \
1347 src/core/load-fragment-gperf-nulstr.c
1348
1349 libcore_la_CFLAGS = \
1350 $(AM_CFLAGS) \
1351 $(PAM_CFLAGS) \
1352 $(AUDIT_CFLAGS) \
1353 $(KMOD_CFLAGS) \
1354 $(APPARMOR_CFLAGS) \
1355 $(MOUNT_CFLAGS) \
1356 $(SECCOMP_CFLAGS)
1357
1358 libcore_la_LIBADD = \
1359 libsystemd-shared.la \
1360 $(PAM_LIBS) \
1361 $(AUDIT_LIBS) \
1362 $(KMOD_LIBS) \
1363 $(APPARMOR_LIBS) \
1364 $(MOUNT_LIBS)
1365
1366 src/core/load-fragment-gperf-nulstr.c: src/core/load-fragment-gperf.gperf
1367 $(AM_V_at)$(MKDIR_P) $(dir $@)
1368 $(AM_V_GEN)$(AWK) 'BEGIN{ keywords=0 ; FS="," ; print "extern const char load_fragment_gperf_nulstr[];" ; print "const char load_fragment_gperf_nulstr[] ="} ; keyword==1 { print "\"" $$1 "\\0\"" } ; /%%/ { keyword=1} ; END { print ";" }' < $< > $@
1369
1370 gperf_gperf_m4_sources = \
1371 src/core/load-fragment-gperf.gperf.m4
1372
1373 gperf_txt_sources = \
1374 src/basic/errno-list.txt \
1375 src/basic/af-list.txt \
1376 src/basic/arphrd-list.txt \
1377 src/basic/cap-list.txt
1378
1379 BUILT_SOURCES += \
1380 $(gperf_gperf_m4_sources:-gperf.gperf.m4=-gperf.c) \
1381 $(gperf_gperf_m4_sources:-gperf.gperf.m4=-gperf-nulstr.c) \
1382 $(gperf_gperf_sources:-gperf.gperf=-gperf.c) \
1383 $(gperf_txt_sources:-list.txt=-from-name.h) \
1384 $(filter-out %keyboard-keys-to-name.h,$(gperf_txt_sources:-list.txt=-to-name.h))
1385
1386 CLEANFILES += \
1387 $(gperf_txt_sources:-list.txt=-from-name.gperf)
1388 DISTCLEANFILES = \
1389 $(gperf_txt_sources)
1390
1391 EXTRA_DIST += \
1392 $(gperf_gperf_m4_sources) \
1393 $(gperf_gperf_sources)
1394
1395 CLEANFILES += \
1396 $(gperf_txt_sources)
1397
1398 %-from-name.gperf: %-list.txt
1399 $(AM_V_at)$(MKDIR_P) $(dir $@)
1400 $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct $(notdir $*)_name { const char* name; int id; };"; print "%null-strings"; print "%%";} { printf "%s, %s\n", $$1, $$1 }' <$< >$@
1401
1402 %-from-name.h: %-from-name.gperf
1403 $(AM_V_at)$(MKDIR_P) $(dir $@)
1404 $(AM_V_GPERF)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_$(notdir $*) -H hash_$(notdir $*)_name -p -C <$< >$@
1405
1406
1407 src/basic/errno-list.txt:
1408 $(AM_V_at)$(MKDIR_P) $(dir $@)
1409 $(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM -include errno.h - </dev/null | $(AWK) '/^#define[ \t]+E[^ _]+[ \t]+/ { print $$2; }' >$@
1410
1411 src/basic/errno-to-name.h: src/basic/errno-list.txt
1412 $(AM_V_at)$(MKDIR_P) $(dir $@)
1413 $(AM_V_GEN)$(AWK) 'BEGIN{ print "static const char* const errno_names[] = { "} !/EDEADLOCK/ && !/EWOULDBLOCK/ && !/ENOTSUP/ { printf "[%s] = \"%s\",\n", $$1, $$1 } END{print "};"}' <$< >$@
1414
1415
1416 src/basic/af-list.txt:
1417 $(AM_V_at)$(MKDIR_P) $(dir $@)
1418 $(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM -include sys/socket.h - </dev/null | grep -v AF_UNSPEC | grep -v AF_MAX | $(AWK) '/^#define[ \t]+AF_[^ \t]+[ \t]+PF_[^ \t]/ { print $$2; }' >$@
1419
1420 src/basic/af-to-name.h: src/basic/af-list.txt
1421 $(AM_V_at)$(MKDIR_P) $(dir $@)
1422 $(AM_V_GEN)$(AWK) 'BEGIN{ print "static const char* const af_names[] = { "} !/AF_FILE/ && !/AF_ROUTE/ && !/AF_LOCAL/ { printf "[%s] = \"%s\",\n", $$1, $$1 } END{print "};"}' <$< >$@
1423
1424
1425 src/basic/arphrd-list.txt:
1426 $(AM_V_at)$(MKDIR_P) $(dir $@)
1427 $(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM -include net/if_arp.h - </dev/null | $(AWK) '/^#define[ \t]+ARPHRD_[^ \t]+[ \t]+[^ \t]/ { print $$2; }' | sed -e 's/ARPHRD_//' >$@
1428
1429 src/basic/arphrd-to-name.h: src/basic/arphrd-list.txt
1430 $(AM_V_at)$(MKDIR_P) $(dir $@)
1431 $(AM_V_GEN)$(AWK) 'BEGIN{ print "static const char* const arphrd_names[] = { "} !/CISCO/ { printf "[ARPHRD_%s] = \"%s\",\n", $$1, $$1 } END{print "};"}' <$< >$@
1432
1433 src/basic/arphrd-from-name.gperf: src/basic/arphrd-list.txt
1434 $(AM_V_at)$(MKDIR_P) $(dir $@)
1435 $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct arphrd_name { const char* name; int id; };"; print "%null-strings"; print "%%";} { printf "%s, ARPHRD_%s\n", $$1, $$1 }' <$< >$@
1436
1437
1438 src/basic/cap-list.txt:
1439 $(AM_V_at)$(MKDIR_P) $(dir $@)
1440 $(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM -include linux/capability.h -include missing.h - </dev/null | $(AWK) '/^#define[ \t]+CAP_[A-Z_]+[ \t]+/ { print $$2; }' | grep -v CAP_LAST_CAP >$@
1441
1442 src/basic/cap-to-name.h: src/basic/cap-list.txt
1443 $(AM_V_at)$(MKDIR_P) $(dir $@)
1444 $(AM_V_GEN)$(AWK) 'BEGIN{ print "static const char* const capability_names[] = { "} { printf "[%s] = \"%s\",\n", $$1, tolower($$1) } END{print "};"}' <$< >$@
1445
1446 src/basic/cap-from-name.gperf: src/basic/cap-list.txt
1447 $(AM_V_at)$(MKDIR_P) $(dir $@)
1448 $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct capability_name { const char* name; int id; };"; print "%null-strings"; print "%%";} { printf "%s, %s\n", $$1, $$1 }' <$< >$@
1449
1450 src/basic/cap-from-name.h: src/basic/cap-from-name.gperf
1451 $(AM_V_at)$(MKDIR_P) $(dir $@)
1452 $(AM_V_GPERF)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_capability -H hash_capability_name -p -C <$< >$@
1453
1454 audit_list_includes = -include linux/audit.h -include missing.h
1455 if HAVE_AUDIT
1456 audit_list_includes += -include libaudit.h
1457 endif
1458
1459 src/journal/audit_type-list.txt:
1460 $(AM_V_at)$(MKDIR_P) $(dir $@)
1461 $(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM $(audit_list_includes) - </dev/null | grep -vE 'AUDIT_.*(FIRST|LAST)_' | $(SED) -r -n 's/^#define\s+AUDIT_(\w+)\s+([0-9]{4})\s*$$/\1\t\2/p' | sort -k2 >$@
1462
1463 src/journal/audit_type-to-name.h: src/journal/audit_type-list.txt
1464 $(AM_V_at)$(MKDIR_P) $(dir $@)
1465 $(AM_V_GEN)$(AWK) 'BEGIN{ print "const char *audit_type_to_string(int type) {\n\tswitch(type) {" } {printf " case AUDIT_%s: return \"%s\";\n", $$1, $$1 } END{ print " default: return NULL;\n\t}\n}\n" }' <$< >$@
1466
1467
1468 src/resolve/dns_type-list.txt: src/resolve/dns-type.h
1469 $(AM_V_at)$(MKDIR_P) $(dir $@)
1470 $(AM_V_GEN)$(SED) -n -r 's/.* DNS_TYPE_(\w+).*/\1/p' <$< >$@
1471
1472 src/resolve/dns_type-to-name.h: src/resolve/dns_type-list.txt
1473 $(AM_V_at)$(MKDIR_P) $(dir $@)
1474 $(AM_V_GEN)$(AWK) 'BEGIN{ print "const char *dns_type_to_string(int type) {\n\tswitch(type) {" } {printf " case DNS_TYPE_%s: return ", $$1; sub(/_/, "-"); printf "\"%s\";\n", $$1 } END{ print " default: return NULL;\n\t}\n}\n" }' <$< >$@
1475
1476 src/resolve/dns_type-from-name.gperf: src/resolve/dns_type-list.txt
1477 $(AM_V_at)$(MKDIR_P) $(dir $@)
1478 $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct dns_type_name { const char* name; int id; };"; print "%null-strings"; print "%%";} { s=$$1; sub(/_/, "-", s); printf "%s, ", $$s; printf "DNS_TYPE_%s\n", $$1 }' <$< >$@
1479
1480 # ------------------------------------------------------------------------------
1481 systemd_SOURCES = \
1482 src/core/main.c
1483
1484 systemd_CFLAGS = \
1485 $(AM_CFLAGS) \
1486 $(SECCOMP_CFLAGS) \
1487 $(MOUNT_CFLAGS)
1488
1489 systemd_LDADD = \
1490 libcore.la
1491
1492 dist_pkgsysconf_DATA += \
1493 src/core/system.conf \
1494 src/core/user.conf
1495
1496 dist_dbuspolicy_DATA += \
1497 src/core/org.freedesktop.systemd1.conf
1498
1499 dist_dbussystemservice_DATA += \
1500 src/core/org.freedesktop.systemd1.service
1501
1502 polkitpolicy_in_in_files += \
1503 src/core/org.freedesktop.systemd1.policy.in.in
1504
1505 pkgconfigdata_DATA += \
1506 src/core/systemd.pc
1507
1508 if ENABLE_RPM_MACROS
1509 nodist_rpmmacros_DATA = \
1510 src/core/macros.systemd
1511 endif
1512
1513 BUILT_SOURCES += \
1514 src/core/triggers.systemd
1515
1516 EXTRA_DIST += \
1517 src/core/systemd.pc.in \
1518 src/core/macros.systemd.in \
1519 src/core/triggers.systemd.in
1520
1521 # ------------------------------------------------------------------------------
1522
1523 manual_tests += \
1524 test-ns \
1525 test-cgroup \
1526 test-install \
1527 test-btrfs \
1528 test-acd \
1529 test-ipv4ll-manual \
1530 test-ask-password-api \
1531 test-dissect-image
1532
1533 unsafe_tests = \
1534 test-hostname \
1535 test-ipcrm
1536
1537 if HAVE_LIBIPTC
1538 manual_tests += \
1539 test-firewall-util
1540 endif
1541
1542 if HAVE_KMOD
1543 manual_tests += \
1544 test-netlink-manual
1545 endif
1546
1547 tests += \
1548 test-daemon \
1549 test-log \
1550 test-loopback \
1551 test-engine \
1552 test-watchdog \
1553 test-cgroup-mask \
1554 test-job-type \
1555 test-env-util \
1556 test-strbuf \
1557 test-strv \
1558 test-path \
1559 test-path-util \
1560 test-strxcpyx \
1561 test-siphash24 \
1562 test-unit-name \
1563 test-unit-file \
1564 test-utf8 \
1565 test-ellipsize \
1566 test-util \
1567 test-mount-util \
1568 test-exec-util \
1569 test-cpu-set-util \
1570 test-hexdecoct \
1571 test-escape \
1572 test-alloc-util \
1573 test-proc-cmdline \
1574 test-io-util \
1575 test-glob-util \
1576 test-xattr-util \
1577 test-fs-util \
1578 test-web-util \
1579 test-stat-util \
1580 test-fd-util \
1581 test-string-util \
1582 test-extract-word \
1583 test-parse-util \
1584 test-user-util \
1585 test-hostname-util \
1586 test-process-util \
1587 test-terminal-util \
1588 test-path-lookup \
1589 test-barrier \
1590 test-tmpfiles \
1591 test-namespace \
1592 test-date \
1593 test-sleep \
1594 test-replace-var \
1595 test-sched-prio \
1596 test-calendarspec \
1597 test-strip-tab-ansi \
1598 test-cgroup-util \
1599 test-fstab-util \
1600 test-prioq \
1601 test-fileio \
1602 test-time \
1603 test-clock \
1604 test-hashmap \
1605 test-set \
1606 test-bitmap \
1607 test-list \
1608 test-unaligned \
1609 test-tables \
1610 test-device-nodes \
1611 test-xml \
1612 test-architecture \
1613 test-socket-util \
1614 test-fdset \
1615 test-conf-files \
1616 test-conf-parser \
1617 test-capability \
1618 test-async \
1619 test-ratelimit \
1620 test-condition \
1621 test-uid-range \
1622 test-locale-util \
1623 test-execute \
1624 test-copy \
1625 test-cap-list \
1626 test-sigbus \
1627 test-verbs \
1628 test-af-list \
1629 test-arphrd-list \
1630 test-dns-domain \
1631 test-install-root \
1632 test-rlimit-util \
1633 test-signal-util \
1634 test-selinux \
1635 test-sizeof \
1636 test-journal-importer
1637
1638 if HAVE_ACL
1639 tests += \
1640 test-acl-util
1641 endif
1642
1643 if HAVE_SECCOMP
1644 tests += \
1645 test-seccomp
1646 endif
1647
1648 TEST_DATA_FILES += \
1649 test/a.service \
1650 test/basic.target \
1651 test/b.service \
1652 test/c.service \
1653 test/daughter.service \
1654 test/d.service \
1655 test/end.service \
1656 test/e.service \
1657 test/f.service \
1658 test/grandchild.service \
1659 test/g.service \
1660 test/hello-after-sleep.target \
1661 test/hello.service \
1662 test/h.service \
1663 test/parent-deep.slice \
1664 test/parent.slice \
1665 test/sched_idle_bad.service \
1666 test/sched_idle_ok.service \
1667 test/sched_rr_bad.service \
1668 test/sched_rr_change.service \
1669 test/sched_rr_ok.service \
1670 test/shutdown.target \
1671 test/sleep.service \
1672 test/sockets.target \
1673 test/son.service \
1674 test/sysinit.target \
1675 test/testsuite.target \
1676 test/timers.target \
1677 test/unstoppable.service \
1678 test/test-path/paths.target \
1679 test/test-path/basic.target \
1680 test/test-path/sysinit.target \
1681 test/test-path/path-changed.service \
1682 test/test-path/path-directorynotempty.service \
1683 test/test-path/path-existsglob.service \
1684 test/test-path/path-exists.service \
1685 test/test-path/path-makedirectory.service \
1686 test/test-path/path-modified.service \
1687 test/test-path/path-mycustomunit.service \
1688 test/test-path/path-service.service \
1689 test/test-path/path-changed.path \
1690 test/test-path/path-directorynotempty.path \
1691 test/test-path/path-existsglob.path \
1692 test/test-path/path-exists.path \
1693 test/test-path/path-makedirectory.path \
1694 test/test-path/path-modified.path \
1695 test/test-path/path-unit.path \
1696 test/test-execute/exec-environment-empty.service \
1697 test/test-execute/exec-environment-multiple.service \
1698 test/test-execute/exec-environment.service \
1699 test/test-execute/exec-passenvironment-absent.service \
1700 test/test-execute/exec-passenvironment-empty.service \
1701 test/test-execute/exec-passenvironment-repeated.service \
1702 test/test-execute/exec-passenvironment.service \
1703 test/test-execute/exec-group.service \
1704 test/test-execute/exec-group-nfsnobody.service \
1705 test/test-execute/exec-supplementarygroups.service \
1706 test/test-execute/exec-supplementarygroups-single-group.service \
1707 test/test-execute/exec-supplementarygroups-single-group-user.service \
1708 test/test-execute/exec-supplementarygroups-multiple-groups-default-group-user.service \
1709 test/test-execute/exec-supplementarygroups-multiple-groups-withgid.service \
1710 test/test-execute/exec-supplementarygroups-multiple-groups-withuid.service \
1711 test/test-execute/exec-dynamicuser-fixeduser.service \
1712 test/test-execute/exec-dynamicuser-fixeduser-one-supplementarygroup.service \
1713 test/test-execute/exec-dynamicuser-supplementarygroups.service \
1714 test/test-execute/exec-ignoresigpipe-no.service \
1715 test/test-execute/exec-ignoresigpipe-yes.service \
1716 test/test-execute/exec-personality-x86-64.service \
1717 test/test-execute/exec-personality-x86.service \
1718 test/test-execute/exec-personality-s390.service \
1719 test/test-execute/exec-personality-ppc64.service \
1720 test/test-execute/exec-personality-ppc64le.service \
1721 test/test-execute/exec-personality-aarch64.service \
1722 test/test-execute/exec-privatedevices-no.service \
1723 test/test-execute/exec-privatedevices-yes.service \
1724 test/test-execute/exec-privatedevices-no-capability-mknod.service \
1725 test/test-execute/exec-privatedevices-yes-capability-mknod.service \
1726 test/test-execute/exec-protectkernelmodules-no-capabilities.service \
1727 test/test-execute/exec-protectkernelmodules-yes-capabilities.service \
1728 test/test-execute/exec-protectkernelmodules-yes-mount-propagation.service \
1729 test/test-execute/exec-privatetmp-no.service \
1730 test/test-execute/exec-privatetmp-yes.service \
1731 test/test-execute/exec-readonlypaths.service \
1732 test/test-execute/exec-readonlypaths-mount-propagation.service \
1733 test/test-execute/exec-readwritepaths-mount-propagation.service \
1734 test/test-execute/exec-inaccessiblepaths-mount-propagation.service \
1735 test/test-execute/exec-spec-interpolation.service \
1736 test/test-execute/exec-systemcallerrornumber.service \
1737 test/test-execute/exec-systemcallfilter-failing2.service \
1738 test/test-execute/exec-systemcallfilter-failing.service \
1739 test/test-execute/exec-systemcallfilter-not-failing2.service \
1740 test/test-execute/exec-systemcallfilter-not-failing.service \
1741 test/test-execute/exec-systemcallfilter-system-user.service \
1742 test/test-execute/exec-systemcallfilter-system-user-nfsnobody.service \
1743 test/test-execute/exec-user.service \
1744 test/test-execute/exec-user-nfsnobody.service \
1745 test/test-execute/exec-workingdirectory.service \
1746 test/test-execute/exec-umask-0177.service \
1747 test/test-execute/exec-umask-default.service \
1748 test/test-execute/exec-privatenetwork-yes.service \
1749 test/test-execute/exec-environmentfile.service \
1750 test/test-execute/exec-oomscoreadjust-positive.service \
1751 test/test-execute/exec-oomscoreadjust-negative.service \
1752 test/test-execute/exec-ioschedulingclass-best-effort.service \
1753 test/test-execute/exec-ioschedulingclass-idle.service \
1754 test/test-execute/exec-ioschedulingclass-none.service \
1755 test/test-execute/exec-ioschedulingclass-realtime.service \
1756 test/test-execute/exec-capabilityboundingset-invert.service \
1757 test/test-execute/exec-capabilityboundingset-merge.service \
1758 test/test-execute/exec-capabilityboundingset-reset.service \
1759 test/test-execute/exec-capabilityboundingset-simple.service \
1760 test/test-execute/exec-capabilityambientset.service \
1761 test/test-execute/exec-capabilityambientset-nfsnobody.service \
1762 test/test-execute/exec-capabilityambientset-merge.service \
1763 test/test-execute/exec-capabilityambientset-merge-nfsnobody.service \
1764 test/test-execute/exec-runtimedirectory.service \
1765 test/test-execute/exec-runtimedirectory-mode.service \
1766 test/test-execute/exec-runtimedirectory-owner.service \
1767 test/test-execute/exec-runtimedirectory-owner-nfsnobody.service \
1768 test/test-execute/exec-restrict-namespaces-no.service \
1769 test/test-execute/exec-restrict-namespaces-yes.service \
1770 test/test-execute/exec-restrict-namespaces-mnt.service \
1771 test/test-execute/exec-restrict-namespaces-mnt-blacklist.service \
1772 test/test-execute/exec-read-only-path-succeed.service \
1773 test/test-execute/exec-privatedevices-yes-capability-sys-rawio.service \
1774 test/test-execute/exec-privatedevices-no-capability-sys-rawio.service \
1775 test/bus-policy/hello.conf \
1776 test/bus-policy/methods.conf \
1777 test/bus-policy/ownerships.conf \
1778 test/bus-policy/signals.conf \
1779 test/bus-policy/check-own-rules.conf \
1780 test/bus-policy/many-rules.conf \
1781 test/bus-policy/test.conf \
1782 test/hwdb/10-bad.hwdb
1783
1784
1785 EXTRA_DIST += \
1786 src/test/test-helper.h
1787
1788 test_device_nodes_SOURCES = \
1789 src/test/test-device-nodes.c
1790
1791 test_device_nodes_LDADD = \
1792 libsystemd-shared.la
1793
1794 test_engine_SOURCES = \
1795 src/test/test-engine.c
1796
1797 test_engine_CFLAGS = \
1798 $(AM_CFLAGS) \
1799 $(SECCOMP_CFLAGS) \
1800 $(MOUNT_CFLAGS)
1801
1802 test_engine_LDADD = \
1803 libcore.la
1804
1805 test_job_type_SOURCES = \
1806 src/test/test-job-type.c
1807
1808 test_job_type_CFLAGS = \
1809 $(AM_CFLAGS) \
1810 $(SECCOMP_CFLAGS) \
1811 $(MOUNT_CFLAGS)
1812
1813 test_job_type_LDADD = \
1814 libcore.la
1815
1816 test_ns_SOURCES = \
1817 src/test/test-ns.c
1818
1819 test_ns_CFLAGS = \
1820 $(AM_CFLAGS) \
1821 $(SECCOMP_CFLAGS)
1822
1823 test_ns_LDADD = \
1824 libcore.la
1825
1826 test_loopback_SOURCES = \
1827 src/test/test-loopback.c
1828
1829 test_loopback_LDADD = \
1830 libcore.la
1831
1832 test_hostname_SOURCES = \
1833 src/test/test-hostname.c
1834
1835 test_hostname_LDADD = \
1836 libcore.la
1837
1838 test_dns_domain_SOURCES = \
1839 src/test/test-dns-domain.c
1840
1841 test_dns_domain_LDADD = \
1842 libsystemd-network.la \
1843 libsystemd-shared.la
1844
1845
1846 if ENABLE_EFI
1847 tests += \
1848 test-boot-timestamps
1849
1850 test_boot_timestamps_SOURCES = \
1851 src/test/test-boot-timestamps.c
1852
1853 test_boot_timestamps_LDADD = \
1854 libsystemd-shared.la
1855 endif
1856
1857 test_unit_name_SOURCES = \
1858 src/test/test-unit-name.c
1859
1860 test_unit_name_CFLAGS = \
1861 $(AM_CFLAGS) \
1862 $(SECCOMP_CFLAGS) \
1863 $(MOUNT_CFLAGS)
1864
1865 test_unit_name_LDADD = \
1866 libcore.la
1867
1868 test_unit_file_SOURCES = \
1869 src/test/test-unit-file.c
1870
1871 test_unit_file_CFLAGS = \
1872 $(AM_CFLAGS) \
1873 $(SECCOMP_CFLAGS) \
1874 $(MOUNT_CFLAGS)
1875
1876 test_unit_file_LDADD = \
1877 libcore.la
1878
1879 test_utf8_SOURCES = \
1880 src/test/test-utf8.c
1881
1882 test_utf8_LDADD = \
1883 libsystemd-shared.la
1884
1885 test_capability_SOURCES = \
1886 src/test/test-capability.c
1887
1888 test_capability_CFLAGS = \
1889 $(AM_CFLAGS) \
1890 $(CAP_CFLAGS)
1891
1892 test_capability_LDADD = \
1893 libsystemd-shared.la \
1894 $(CAP_LIBS)
1895
1896 test_async_SOURCES = \
1897 src/test/test-async.c
1898
1899 test_async_LDADD = \
1900 libsystemd-shared.la
1901
1902 test_locale_util_SOURCES = \
1903 src/test/test-locale-util.c
1904
1905 test_locale_util_LDADD = \
1906 libsystemd-shared.la
1907
1908 test_copy_SOURCES = \
1909 src/test/test-copy.c
1910
1911 # Link statically to ensure file is large
1912 test_copy_LDADD = \
1913 libshared.la
1914
1915 test_sigbus_SOURCES = \
1916 src/test/test-sigbus.c
1917
1918 test_sigbus_LDADD = \
1919 libsystemd-shared.la
1920
1921 test_condition_SOURCES = \
1922 src/test/test-condition.c
1923
1924 test_condition_LDADD = \
1925 libsystemd-shared.la
1926
1927 test_fdset_SOURCES = \
1928 src/test/test-fdset.c
1929
1930 test_fdset_LDADD = \
1931 libsystemd-shared.la
1932
1933 test_fstab_util_SOURCES = \
1934 src/test/test-fstab-util.c
1935
1936 test_fstab_util_LDADD = \
1937 libsystemd-shared.la
1938
1939 test_ratelimit_SOURCES = \
1940 src/test/test-ratelimit.c
1941
1942 test_ratelimit_LDADD = \
1943 libsystemd-shared.la
1944
1945 test_util_SOURCES = \
1946 src/test/test-util.c
1947
1948 test_util_LDADD = \
1949 libsystemd-shared.la
1950
1951 test_mount_util_SOURCES = \
1952 src/test/test-mount-util.c
1953
1954 test_mount_util_LDADD = \
1955 libsystemd-shared.la
1956
1957 test_exec_util_SOURCES = \
1958 src/test/test-exec-util.c
1959
1960 test_exec_util_LDADD = \
1961 libsystemd-shared.la
1962
1963 test_hexdecoct_SOURCES = \
1964 src/test/test-hexdecoct.c
1965
1966 test_hexdecoct_LDADD = \
1967 libsystemd-shared.la
1968
1969 test_alloc_util_SOURCES = \
1970 src/test/test-alloc-util.c
1971
1972 test_alloc_util_LDADD = \
1973 libsystemd-shared.la
1974
1975 test_xattr_util_SOURCES = \
1976 src/test/test-xattr-util.c
1977
1978 test_xattr_util_LDADD = \
1979 libsystemd-shared.la
1980
1981 test_io_util_SOURCES = \
1982 src/test/test-io-util.c
1983
1984 test_io_util_LDADD = \
1985 libsystemd-shared.la
1986
1987 test_glob_util_SOURCES = \
1988 src/test/test-glob-util.c
1989
1990 test_glob_util_LDADD = \
1991 libsystemd-shared.la
1992
1993 test_fs_util_SOURCES = \
1994 src/test/test-fs-util.c
1995
1996 test_fs_util_LDADD = \
1997 libsystemd-shared.la
1998
1999 test_proc_cmdline_SOURCES = \
2000 src/test/test-proc-cmdline.c
2001
2002 test_proc_cmdline_LDADD = \
2003 libsystemd-shared.la
2004
2005 test_fd_util_SOURCES = \
2006 src/test/test-fd-util.c
2007
2008 test_fd_util_LDADD = \
2009 libsystemd-shared.la
2010
2011 test_web_util_SOURCES = \
2012 src/test/test-web-util.c
2013
2014 test_web_util_LDADD = \
2015 libsystemd-shared.la
2016
2017 test_cpu_set_util_SOURCES = \
2018 src/test/test-cpu-set-util.c
2019
2020 test_cpu_set_util_LDADD = \
2021 libsystemd-shared.la
2022
2023 test_stat_util_SOURCES = \
2024 src/test/test-stat-util.c
2025
2026 test_stat_util_LDADD = \
2027 libsystemd-shared.la
2028
2029 test_escape_SOURCES = \
2030 src/test/test-escape.c
2031
2032 test_escape_LDADD = \
2033 libsystemd-shared.la
2034
2035 test_string_util_SOURCES = \
2036 src/test/test-string-util.c
2037
2038 test_string_util_LDADD = \
2039 libsystemd-shared.la
2040
2041 test_extract_word_SOURCES = \
2042 src/test/test-extract-word.c
2043
2044 test_extract_word_LDADD = \
2045 libsystemd-shared.la
2046
2047 test_parse_util_SOURCES = \
2048 src/test/test-parse-util.c
2049
2050 test_parse_util_LDADD = \
2051 libsystemd-shared.la
2052
2053 test_user_util_SOURCES = \
2054 src/test/test-user-util.c
2055
2056 test_user_util_LDADD = \
2057 libsystemd-shared.la
2058
2059 test_hostname_util_SOURCES = \
2060 src/test/test-hostname-util.c
2061
2062 test_hostname_util_LDADD = \
2063 libsystemd-shared.la
2064
2065 test_process_util_SOURCES = \
2066 src/test/test-process-util.c
2067
2068 test_process_util_LDADD = \
2069 libsystemd-shared.la
2070
2071 test_terminal_util_SOURCES = \
2072 src/test/test-terminal-util.c
2073
2074 test_terminal_util_LDADD = \
2075 libsystemd-shared.la
2076
2077 test_path_lookup_SOURCES = \
2078 src/test/test-path-lookup.c
2079
2080 test_path_lookup_LDADD = \
2081 libsystemd-shared.la
2082
2083 test_uid_range_SOURCES = \
2084 src/test/test-uid-range.c
2085
2086 test_uid_range_LDADD = \
2087 libsystemd-shared.la
2088
2089 test_cap_list_SOURCES = \
2090 src/test/test-cap-list.c
2091
2092 test_cap_list_CFLAGS = \
2093 $(AM_CFLAGS) \
2094 $(CAP_CFLAGS)
2095
2096 test_cap_list_LDADD = \
2097 libsystemd-shared.la \
2098 $(CAP_LIBS)
2099
2100 test_socket_util_SOURCES = \
2101 src/test/test-socket-util.c
2102
2103 test_socket_util_LDADD = \
2104 libsystemd-shared.la
2105
2106 test_barrier_SOURCES = \
2107 src/test/test-barrier.c
2108
2109 test_barrier_LDADD = \
2110 libsystemd-shared.la
2111
2112 test_tmpfiles_SOURCES = \
2113 src/test/test-tmpfiles.c
2114
2115 test_tmpfiles_LDADD = \
2116 libsystemd-shared.la
2117
2118 test_namespace_SOURCES = \
2119 src/test/test-namespace.c
2120
2121 test_verbs_SOURCES = \
2122 src/test/test-verbs.c
2123
2124 test_verbs_LDADD = \
2125 libsystemd-shared.la
2126
2127 test_install_root_SOURCES = \
2128 src/test/test-install-root.c
2129
2130 test_install_root_LDADD = \
2131 libsystemd-shared.la
2132
2133 test_acl_util_SOURCES = \
2134 src/test/test-acl-util.c
2135
2136 test_acl_util_LDADD = \
2137 libsystemd-shared.la
2138
2139 test_seccomp_SOURCES = \
2140 src/test/test-seccomp.c
2141
2142 test_seccomp_LDADD = \
2143 libsystemd-shared.la \
2144 $(SECCOMP_LIBS)
2145
2146 test_namespace_LDADD = \
2147 libcore.la
2148
2149 test_rlimit_util_SOURCES = \
2150 src/test/test-rlimit-util.c
2151
2152 test_rlimit_util_LDADD = \
2153 libsystemd-shared.la
2154
2155 test_ask_password_api_SOURCES = \
2156 src/test/test-ask-password-api.c
2157
2158 test_ask_password_api_LDADD = \
2159 libsystemd-shared.la
2160
2161 test_dissect_image_SOURCES = \
2162 src/test/test-dissect-image.c
2163
2164 test_dissect_image_CFLAGS = \
2165 $(AM_CFLAGS) \
2166 $(BLKID_CFLAGS)
2167
2168 test_dissect_image_LDADD = \
2169 libsystemd-shared.la \
2170 $(BLKID_LIBS)
2171
2172 test_signal_util_SOURCES = \
2173 src/test/test-signal-util.c
2174
2175 test_signal_util_LDADD = \
2176 libsystemd-shared.la
2177
2178 test_selinux_SOURCES = \
2179 src/test/test-selinux.c
2180
2181 test_selinux_LDADD = \
2182 libsystemd-shared.la
2183
2184 test_sizeof_SOURCES = \
2185 src/test/test-sizeof.c
2186
2187 BUILT_SOURCES += \
2188 src/test/test-hashmap-ordered.c
2189
2190 src/test/test-hashmap-ordered.c: src/test/test-hashmap-plain.c
2191 $(AM_V_at)$(MKDIR_P) $(dir $@)
2192 $(AM_V_GEN)$(AWK) 'BEGIN { print "/* GENERATED FILE */\n#define ORDERED" } \
2193 { if (!match($$0, "^#include")) \
2194 gsub(/hashmap/, "ordered_hashmap"); \
2195 gsub(/HASHMAP/, "ORDERED_HASHMAP"); \
2196 gsub(/Hashmap/, "OrderedHashmap"); \
2197 print }' <$< >$@
2198
2199 nodist_test_hashmap_SOURCES = \
2200 src/test/test-hashmap-ordered.c
2201
2202 test_hashmap_SOURCES = \
2203 src/test/test-hashmap.c \
2204 src/test/test-hashmap-plain.c
2205
2206 test_hashmap_LDADD = \
2207 libsystemd-shared.la
2208
2209 test_set_SOURCES = \
2210 src/test/test-set.c
2211
2212 test_set_LDADD = \
2213 libsystemd-shared.la
2214
2215 test_bitmap_SOURCES = \
2216 src/test/test-bitmap.c
2217
2218 test_bitmap_LDADD = \
2219 libsystemd-shared.la
2220
2221 test_xml_SOURCES = \
2222 src/test/test-xml.c
2223
2224 test_xml_LDADD = \
2225 libsystemd-shared.la
2226
2227 test_list_SOURCES = \
2228 src/test/test-list.c
2229
2230 test_list_LDADD = \
2231 libsystemd-shared.la
2232
2233 test_unaligned_LDADD = \
2234 libsystemd-shared.la
2235
2236 test_unaligned_SOURCES = \
2237 src/test/test-unaligned.c
2238
2239 test_tables_SOURCES = \
2240 src/test/test-tables.c \
2241 src/shared/test-tables.h \
2242 src/journal/journald-server.c \
2243 src/journal/journald-server.h
2244
2245 test_tables_CPPFLAGS = \
2246 $(AM_CPPFLAGS)
2247
2248 test_tables_CFLAGS = \
2249 $(AM_CFLAGS) \
2250 $(SECCOMP_CFLAGS) \
2251 $(MOUNT_CFLAGS)
2252
2253 test_tables_LDADD = \
2254 libjournal-core.la \
2255 libcore.la \
2256 libudev-core.la
2257
2258 test_prioq_SOURCES = \
2259 src/test/test-prioq.c
2260
2261 test_prioq_LDADD = \
2262 libsystemd-shared.la
2263
2264 test_fileio_SOURCES = \
2265 src/test/test-fileio.c
2266
2267 test_fileio_LDADD = \
2268 libsystemd-shared.la
2269
2270 test_time_SOURCES = \
2271 src/test/test-time.c
2272
2273 test_time_LDADD = \
2274 libsystemd-shared.la
2275
2276 test_clock_SOURCES = \
2277 src/test/test-clock.c
2278
2279 test_clock_LDADD = \
2280 libsystemd-shared.la
2281
2282 test_architecture_SOURCES = \
2283 src/test/test-architecture.c
2284
2285 test_architecture_LDADD = \
2286 libsystemd-shared.la
2287
2288 test_log_SOURCES = \
2289 src/test/test-log.c
2290
2291 test_log_LDADD = \
2292 libsystemd-shared.la
2293
2294 test_ipcrm_SOURCES = \
2295 src/test/test-ipcrm.c
2296
2297 test_ipcrm_LDADD = \
2298 libsystemd-shared.la
2299
2300 test_btrfs_SOURCES = \
2301 src/test/test-btrfs.c
2302
2303 test_btrfs_LDADD = \
2304 libsystemd-shared.la
2305
2306 if HAVE_LIBIPTC
2307 test_firewall_util_SOURCES = \
2308 src/test/test-firewall-util.c
2309
2310 test_firewall_util_CFLAGS = \
2311 $(AM_CFLAGS) \
2312 $(LIBIPTC_CFLAGS)
2313
2314 test_firewall_util_LDADD = \
2315 libfirewall.la \
2316 libsystemd-shared.la \
2317 $(LIBIPTC_LIBS)
2318 endif
2319
2320 test_netlink_manual_SOURCES = \
2321 src/test/test-netlink-manual.c
2322
2323 test_netlink_manual_CFLAGS = \
2324 $(AM_CFLAGS) \
2325 $(KMOD_CFLAGS)
2326
2327 test_netlink_manual_LDADD = \
2328 libsystemd-shared.la \
2329 $(KMOD_LIBS)
2330
2331 test_ellipsize_SOURCES = \
2332 src/test/test-ellipsize.c
2333
2334 test_ellipsize_LDADD = \
2335 libsystemd-shared.la
2336
2337 test_date_SOURCES = \
2338 src/test/test-date.c
2339
2340 test_date_LDADD = \
2341 libsystemd-shared.la
2342
2343 test_sleep_SOURCES = \
2344 src/test/test-sleep.c
2345
2346 test_sleep_LDADD = \
2347 libcore.la
2348
2349 test_replace_var_SOURCES = \
2350 src/test/test-replace-var.c
2351
2352 test_replace_var_LDADD = \
2353 libsystemd-shared.la
2354
2355 test_calendarspec_SOURCES = \
2356 src/test/test-calendarspec.c
2357
2358 test_calendarspec_LDADD = \
2359 libsystemd-shared.la
2360
2361 test_strip_tab_ansi_SOURCES = \
2362 src/test/test-strip-tab-ansi.c
2363
2364 test_strip_tab_ansi_LDADD = \
2365 libsystemd-shared.la
2366
2367 test_daemon_SOURCES = \
2368 src/test/test-daemon.c
2369
2370 test_daemon_LDADD = \
2371 libsystemd-shared.la
2372
2373 test_cgroup_SOURCES = \
2374 src/test/test-cgroup.c
2375
2376 test_cgroup_LDADD = \
2377 libsystemd-shared.la
2378
2379 test_cgroup_mask_SOURCES = \
2380 src/test/test-cgroup-mask.c
2381
2382 test_cgroup_mask_CPPFLAGS = \
2383 $(AM_CPPFLAGS) \
2384 $(MOUNT_CFLAGS)
2385
2386 test_cgroup_mask_CFLAGS = \
2387 $(AM_CFLAGS) \
2388 $(SECCOMP_CFLAGS)
2389
2390 test_cgroup_mask_LDADD = \
2391 libcore.la
2392
2393 test_cgroup_util_SOURCES = \
2394 src/test/test-cgroup-util.c
2395
2396 test_cgroup_util_LDADD = \
2397 libsystemd-shared.la
2398
2399 test_env_util_SOURCES = \
2400 src/test/test-env-util.c
2401
2402 test_env_util_LDADD = \
2403 libsystemd-shared.la
2404
2405 test_strbuf_SOURCES = \
2406 src/test/test-strbuf.c
2407
2408 test_strbuf_LDADD = \
2409 libsystemd-shared.la
2410
2411 test_strv_SOURCES = \
2412 src/test/test-strv.c
2413
2414 test_strv_LDADD = \
2415 libsystemd-shared.la
2416
2417 test_path_util_SOURCES = \
2418 src/test/test-path-util.c
2419
2420 test_path_util_LDADD = \
2421 libsystemd-shared.la
2422
2423 test_path_SOURCES = \
2424 src/test/test-path.c
2425
2426 test_path_CFLAGS = \
2427 $(AM_CFLAGS) \
2428 $(MOUNT_CFLAGS)
2429
2430 test_path_LDADD = \
2431 libcore.la
2432
2433 test_execute_SOURCES = \
2434 src/test/test-execute.c
2435
2436 test_execute_CFLAGS = \
2437 $(AM_CFLAGS) \
2438 $(MOUNT_CFLAGS)
2439
2440 test_execute_LDADD = \
2441 libcore.la
2442
2443 test_siphash24_SOURCES = \
2444 src/test/test-siphash24.c
2445
2446 test_siphash24_LDADD = \
2447 libsystemd-shared.la
2448
2449 test_strxcpyx_SOURCES = \
2450 src/test/test-strxcpyx.c
2451
2452 test_strxcpyx_LDADD = \
2453 libsystemd-shared.la
2454
2455 test_install_SOURCES = \
2456 src/test/test-install.c
2457
2458 test_install_LDADD = \
2459 libsystemd-shared.la
2460
2461 test_watchdog_SOURCES = \
2462 src/test/test-watchdog.c
2463
2464 test_watchdog_LDADD = \
2465 libsystemd-shared.la
2466
2467 test_sched_prio_SOURCES = \
2468 src/test/test-sched-prio.c
2469
2470 test_sched_prio_CPPFLAGS = \
2471 $(AM_CPPFLAGS) \
2472 $(MOUNT_CFLAGS)
2473
2474 test_sched_prio_CFLAGS = \
2475 $(AM_CFLAGS) \
2476 $(SECCOMP_CFLAGS)
2477
2478 test_sched_prio_LDADD = \
2479 libcore.la
2480
2481 test_conf_files_SOURCES = \
2482 src/test/test-conf-files.c
2483
2484 test_conf_files_LDADD = \
2485 libsystemd-shared.la
2486
2487 test_conf_parser_SOURCES = \
2488 src/test/test-conf-parser.c
2489
2490 test_conf_parser_LDADD = \
2491 libsystemd-shared.la
2492
2493 test_af_list_SOURCES = \
2494 src/test/test-af-list.c
2495
2496 test_af_list_LDADD = \
2497 libsystemd-shared.la
2498
2499 test_arphrd_list_SOURCES = \
2500 src/test/test-arphrd-list.c
2501
2502 test_arphrd_list_LDADD = \
2503 libsystemd-shared.la
2504
2505 test_journal_importer_SOURCES = \
2506 src/test/test-journal-importer.c
2507
2508 test_journal_importer_LDADD = \
2509 libsystemd-shared.la
2510
2511 TEST_DATA_FILES += \
2512 test/journal-data/journal-1.txt \
2513 test/journal-data/journal-2.txt
2514
2515 # ------------------------------------------------------------------------------
2516 ## .PHONY so it always rebuilds it
2517 .PHONY: coverage lcov-run lcov-report coverage-sync
2518
2519 # run lcov from scratch, always
2520 coverage: all
2521 $(MAKE) lcov-run
2522 $(MAKE) lcov-report
2523
2524 coverage_dir = coverage
2525 coverage_opts = --base-directory $(srcdir) --directory $(builddir) --rc 'geninfo_adjust_src_path=$(abspath $(srcdir))=>$(abspath $(builddir))'
2526
2527 if ENABLE_COVERAGE
2528 # reset run coverage tests
2529 lcov-run:
2530 @rm -rf $(coverage_dir)
2531 lcov $(coverage_opts) --zerocounters
2532 -$(MAKE) check
2533
2534 # generate report based on current coverage data
2535 lcov-report:
2536 $(MKDIR_P) $(coverage_dir)
2537 lcov $(coverage_opts) --compat-libtool --capture --no-external \
2538 | sed 's|$(abspath $(builddir))|$(abspath $(srcdir))|' > $(coverage_dir)/.lcov.info
2539 lcov --remove $(coverage_dir)/.lcov.info --output-file $(coverage_dir)/.lcov-clean.info 'test-*'
2540 genhtml -t "systemd test coverage" -o $(coverage_dir) $(coverage_dir)/.lcov-clean.info
2541 @echo "Coverage report generated in $(abs_builddir)/$(coverage_dir)/index.html"
2542
2543 # lcov doesn't work properly with vpath builds, make sure that bad
2544 # output is not uploaded by mistake.
2545 coverage-sync: coverage
2546 test "$(builddir)" = "$(srcdir)"
2547 rsync -rlv --delete --omit-dir-times coverage/ $(www_target)/coverage
2548
2549 else
2550 lcov-run lcov-report:
2551 echo "Need to reconfigure with --enable-coverage"
2552 endif
2553
2554 # ------------------------------------------------------------------------------
2555 systemd_analyze_SOURCES = \
2556 src/analyze/analyze.c \
2557 src/analyze/analyze-verify.c \
2558 src/analyze/analyze-verify.h
2559
2560 systemd_analyze_CFLAGS = \
2561 $(AM_CFLAGS) \
2562 $(SECCOMP_CFLAGS) \
2563 $(MOUNT_CFLAGS)
2564
2565 systemd_analyze_LDADD = \
2566 libcore.la
2567
2568 # ------------------------------------------------------------------------------
2569 systemd_initctl_SOURCES = \
2570 src/initctl/initctl.c
2571
2572 systemd_initctl_LDADD = \
2573 libsystemd-shared.la
2574
2575 # ------------------------------------------------------------------------------
2576 systemd_update_utmp_SOURCES = \
2577 src/update-utmp/update-utmp.c
2578
2579 systemd_update_utmp_CFLAGS = \
2580 $(AM_CFLAGS) \
2581 $(AUDIT_CFLAGS)
2582
2583 systemd_update_utmp_LDADD = \
2584 libsystemd-shared.la \
2585 $(AUDIT_LIBS)
2586
2587 # ------------------------------------------------------------------------------
2588 systemd_update_done_SOURCES = \
2589 src/update-done/update-done.c
2590
2591 systemd_update_done_LDADD = \
2592 libsystemd-shared.la
2593
2594 # ------------------------------------------------------------------------------
2595 systemd_shutdown_SOURCES = \
2596 src/core/umount.c \
2597 src/core/umount.h \
2598 src/core/shutdown.c \
2599 src/core/mount-setup.c \
2600 src/core/mount-setup.h \
2601 src/core/killall.h \
2602 src/core/killall.c
2603
2604 systemd_shutdown_LDADD = \
2605 libsystemd-shared.la
2606
2607 # ------------------------------------------------------------------------------
2608 if HAVE_KMOD
2609 systemd_modules_load_SOURCES = \
2610 src/modules-load/modules-load.c
2611
2612 systemd_modules_load_CFLAGS = \
2613 $(AM_CFLAGS) \
2614 $(KMOD_CFLAGS)
2615
2616 systemd_modules_load_LDADD = \
2617 libsystemd-shared.la \
2618 $(KMOD_LIBS)
2619
2620 rootlibexec_PROGRAMS += \
2621 systemd-modules-load
2622
2623 nodist_systemunit_DATA += \
2624 units/systemd-modules-load.service
2625
2626 SYSINIT_TARGET_WANTS += \
2627 systemd-modules-load.service
2628
2629 if ENABLE_TMPFILES
2630 nodist_systemunit_DATA += \
2631 units/kmod-static-nodes.service
2632
2633 SYSINIT_TARGET_WANTS += \
2634 kmod-static-nodes.service
2635 endif
2636 endif
2637
2638 EXTRA_DIST += \
2639 units/systemd-modules-load.service.in \
2640 units/kmod-static-nodes.service.in
2641
2642 # ------------------------------------------------------------------------------
2643 if ENABLE_TMPFILES
2644 systemd_tmpfiles_SOURCES = \
2645 src/tmpfiles/tmpfiles.c
2646
2647 systemd_tmpfiles_CFLAGS = \
2648 $(AM_CFLAGS) \
2649 $(ACL_CFLAGS)
2650
2651 systemd_tmpfiles_LDADD = \
2652 libsystemd-shared.la \
2653 $(ACL_LIBS)
2654
2655 rootbin_PROGRAMS += \
2656 systemd-tmpfiles
2657
2658 dist_systemunit_DATA += \
2659 units/systemd-tmpfiles-clean.timer
2660
2661 nodist_systemunit_DATA += \
2662 units/systemd-tmpfiles-setup-dev.service \
2663 units/systemd-tmpfiles-setup.service \
2664 units/systemd-tmpfiles-clean.service
2665
2666 nodist_tmpfiles_DATA = \
2667 tmpfiles.d/systemd.conf \
2668 tmpfiles.d/etc.conf
2669
2670 dist_tmpfiles_DATA = \
2671 tmpfiles.d/systemd-nologin.conf \
2672 tmpfiles.d/tmp.conf \
2673 tmpfiles.d/x11.conf \
2674 tmpfiles.d/var.conf \
2675 tmpfiles.d/home.conf \
2676 tmpfiles.d/systemd-nspawn.conf \
2677 tmpfiles.d/journal-nocow.conf
2678
2679 if HAVE_SYSV_COMPAT
2680 dist_tmpfiles_DATA += \
2681 tmpfiles.d/legacy.conf
2682 endif
2683
2684 SYSINIT_TARGET_WANTS += \
2685 systemd-tmpfiles-setup-dev.service \
2686 systemd-tmpfiles-setup.service
2687
2688 dist_zshcompletion_data += \
2689 shell-completion/zsh/_systemd-tmpfiles
2690
2691 TIMERS_TARGET_WANTS += \
2692 systemd-tmpfiles-clean.timer
2693
2694 INSTALL_DIRS += \
2695 $(tmpfilesdir) \
2696 $(sysconfdir)/tmpfiles.d
2697 endif
2698
2699 EXTRA_DIST += \
2700 tmpfiles.d/systemd.conf.m4 \
2701 tmpfiles.d/etc.conf.m4 \
2702 units/systemd-tmpfiles-setup-dev.service.in \
2703 units/systemd-tmpfiles-setup.service.in \
2704 units/systemd-tmpfiles-clean.service.in
2705
2706 # ------------------------------------------------------------------------------
2707 if ENABLE_SYSUSERS
2708 systemd_sysusers_SOURCES = \
2709 src/sysusers/sysusers.c
2710
2711 systemd_sysusers_LDADD = \
2712 libsystemd-shared.la
2713
2714 rootbin_PROGRAMS += \
2715 systemd-sysusers
2716
2717 nodist_systemunit_DATA += \
2718 units/systemd-sysusers.service
2719
2720 SYSINIT_TARGET_WANTS += \
2721 systemd-sysusers.service
2722
2723 nodist_sysusers_DATA = \
2724 sysusers.d/systemd.conf \
2725 sysusers.d/basic.conf
2726
2727 if HAVE_REMOTE
2728 nodist_sysusers_DATA += \
2729 sysusers.d/systemd-remote.conf
2730 endif
2731
2732 INSTALL_DIRS += \
2733 $(sysusersdir)
2734 endif
2735
2736 EXTRA_DIST += \
2737 units/systemd-sysusers.service.in \
2738 sysusers.d/systemd.conf.m4 \
2739 sysusers.d/systemd-remote.conf.m4 \
2740 sysusers.d/basic.conf.in
2741
2742 # ------------------------------------------------------------------------------
2743 dist_factory_etc_DATA = \
2744 factory/etc/nsswitch.conf
2745
2746 if HAVE_PAM
2747 dist_factory_pam_DATA = \
2748 factory/etc/pam.d/system-auth \
2749 factory/etc/pam.d/other
2750 endif
2751
2752 # ------------------------------------------------------------------------------
2753 if ENABLE_FIRSTBOOT
2754 systemd_firstboot_SOURCES = \
2755 src/firstboot/firstboot.c
2756
2757 systemd_firstboot_LDADD = \
2758 libsystemd-shared.la \
2759 -lcrypt
2760
2761 rootbin_PROGRAMS += \
2762 systemd-firstboot
2763
2764 nodist_systemunit_DATA += \
2765 units/systemd-firstboot.service
2766
2767 SYSINIT_TARGET_WANTS += \
2768 systemd-firstboot.service
2769 endif
2770
2771 EXTRA_DIST += \
2772 units/systemd-firstboot.service.in
2773
2774 # ------------------------------------------------------------------------------
2775 systemd_machine_id_setup_SOURCES = \
2776 src/machine-id-setup/machine-id-setup-main.c \
2777 src/core/machine-id-setup.c \
2778 src/core/machine-id-setup.h
2779
2780 systemd_machine_id_setup_LDADD = \
2781 libsystemd-shared.la
2782
2783 SYSINIT_TARGET_WANTS += \
2784 systemd-machine-id-commit.service
2785
2786 # ------------------------------------------------------------------------------
2787 systemd_sysctl_SOURCES = \
2788 src/sysctl/sysctl.c
2789
2790 systemd_sysctl_LDADD = \
2791 libsystemd-shared.la
2792
2793 # ------------------------------------------------------------------------------
2794 systemd_sleep_SOURCES = \
2795 src/sleep/sleep.c
2796
2797 systemd_sleep_LDADD = \
2798 libsystemd-shared.la
2799
2800 # ------------------------------------------------------------------------------
2801 systemd_fsck_SOURCES = \
2802 src/fsck/fsck.c
2803
2804 systemd_fsck_LDADD = \
2805 libsystemd-shared.la
2806
2807 # ------------------------------------------------------------------------------
2808 systemd_ac_power_SOURCES = \
2809 src/ac-power/ac-power.c
2810
2811 systemd_ac_power_LDADD = \
2812 libsystemd-shared.la
2813
2814 # ------------------------------------------------------------------------------
2815 systemd_detect_virt_SOURCES = \
2816 src/detect-virt/detect-virt.c
2817
2818 systemd_detect_virt_LDADD = \
2819 libsystemd-shared.la
2820
2821 # ------------------------------------------------------------------------------
2822 systemd_delta_SOURCES = \
2823 src/delta/delta.c
2824
2825 systemd_delta_LDADD = \
2826 libsystemd-shared.la
2827
2828 # ------------------------------------------------------------------------------
2829 systemd_getty_generator_SOURCES = \
2830 src/getty-generator/getty-generator.c
2831
2832 systemd_getty_generator_LDADD = \
2833 libsystemd-shared.la
2834
2835 # ------------------------------------------------------------------------------
2836 systemd_debug_generator_SOURCES = \
2837 src/debug-generator/debug-generator.c
2838
2839 systemd_debug_generator_LDADD = \
2840 libsystemd-shared.la
2841
2842 # ------------------------------------------------------------------------------
2843 systemd_fstab_generator_SOURCES = \
2844 src/fstab-generator/fstab-generator.c \
2845 src/core/mount-setup.c
2846
2847 systemd_fstab_generator_LDADD = \
2848 libsystemd-shared.la
2849
2850 # ------------------------------------------------------------------------------
2851 systemd_system_update_generator_SOURCES = \
2852 src/system-update-generator/system-update-generator.c
2853
2854 systemd_system_update_generator_LDADD = \
2855 libsystemd-shared.la
2856
2857 # ------------------------------------------------------------------------------
2858 30_systemd_environment_d_generator_SOURCES = \
2859 src/environment-d-generator/environment-d-generator.c
2860
2861 30_systemd_environment_d_generator_LDADD = \
2862 libsystemd-shared.la
2863
2864 # ------------------------------------------------------------------------------
2865 if ENABLE_HIBERNATE
2866 systemgenerator_PROGRAMS += \
2867 systemd-hibernate-resume-generator
2868
2869 rootlibexec_PROGRAMS += \
2870 systemd-hibernate-resume
2871
2872 systemd_hibernate_resume_SOURCES = \
2873 src/hibernate-resume/hibernate-resume.c
2874
2875 systemd_hibernate_resume_LDADD = \
2876 libsystemd-shared.la
2877
2878 systemd_hibernate_resume_generator_SOURCES = \
2879 src/hibernate-resume/hibernate-resume-generator.c
2880
2881 systemd_hibernate_resume_generator_LDADD = \
2882 libsystemd-shared.la
2883
2884 dist_systemunit_DATA += \
2885 units/hibernate.target \
2886 units/hybrid-sleep.target
2887
2888 nodist_systemunit_DATA += \
2889 units/systemd-hibernate.service \
2890 units/systemd-hibernate-resume@.service \
2891 units/systemd-hybrid-sleep.service
2892 endif
2893
2894 EXTRA_DIST += \
2895 units/systemd-hibernate.service.in \
2896 units/systemd-hibernate-resume@.service.in \
2897 units/systemd-hybrid-sleep.service.in
2898
2899 # ------------------------------------------------------------------------------
2900 if ENABLE_EFI
2901 if HAVE_BLKID
2902 bootctl_SOURCES = \
2903 src/boot/bootctl.c
2904
2905 bootctl_CPPFLAGS = \
2906 $(AM_CPPFLAGS) \
2907 -DEFI_MACHINE_TYPE_NAME=\"$(EFI_MACHINE_TYPE_NAME)\" \
2908 -DBOOTLIBDIR=\"$(bootlibdir)\"
2909
2910 bootctl_CFLAGS = \
2911 $(AM_CFLAGS) \
2912 $(BLKID_CFLAGS)
2913
2914 bootctl_LDADD = \
2915 libsystemd-shared.la \
2916 $(BLKID_LIBS)
2917
2918 bin_PROGRAMS += \
2919 bootctl
2920
2921 dist_bashcompletion_data += \
2922 shell-completion/bash/bootctl
2923
2924 dist_zshcompletion_data += \
2925 shell-completion/zsh/_bootctl
2926 endif
2927
2928 # ------------------------------------------------------------------------------
2929 if HAVE_GNUEFI
2930 efi_cppflags = \
2931 $(EFI_CPPFLAGS) \
2932 -I$(top_builddir) -include config.h \
2933 -I$(EFI_INC_DIR)/efi \
2934 -I$(EFI_INC_DIR)/efi/$(EFI_ARCH) \
2935 -DEFI_MACHINE_TYPE_NAME=\"$(EFI_MACHINE_TYPE_NAME)\"
2936
2937 efi_cflags = \
2938 $(EFI_CFLAGS) \
2939 -Wall \
2940 -Wextra \
2941 -std=gnu90 \
2942 -nostdinc \
2943 -ggdb -O0 \
2944 -fpic \
2945 -fshort-wchar \
2946 -nostdinc \
2947 -ffreestanding \
2948 -fno-strict-aliasing \
2949 -fno-stack-protector \
2950 -Wsign-compare \
2951 -Wno-missing-field-initializers
2952
2953 if ARCH_X86_64
2954 efi_cflags += \
2955 -mno-red-zone \
2956 -mno-sse \
2957 -mno-mmx \
2958 -DEFI_FUNCTION_WRAPPER \
2959 -DGNU_EFI_USE_MS_ABI
2960 endif
2961
2962 if ARCH_IA32
2963 efi_cflags += \
2964 -mno-sse \
2965 -mno-mmx
2966 endif
2967
2968 efi_ldflags = \
2969 $(EFI_LDFLAGS) \
2970 -T $(EFI_LDS_DIR)/elf_$(EFI_ARCH)_efi.lds \
2971 -shared \
2972 -Bsymbolic \
2973 -nostdlib \
2974 -znocombreloc \
2975 -L $(EFI_LIB_DIR) \
2976 $(EFI_LDS_DIR)/crt0-efi-$(EFI_ARCH).o
2977
2978 # Aarch64 and ARM32 don't have an EFI capable objcopy. Use 'binary' instead,
2979 # and add required symbols manually.
2980 if ARCH_AARCH64
2981 efi_ldflags += --defsym=EFI_SUBSYSTEM=0xa
2982 EFI_FORMAT = -O binary
2983 else
2984 if ARCH_ARM
2985 efi_ldflags += --defsym=EFI_SUBSYSTEM=0xa
2986 EFI_FORMAT = -O binary
2987 else
2988 EFI_FORMAT = --target=efi-app-$(EFI_ARCH)
2989 endif
2990 endif
2991 endif
2992 endif
2993
2994 # ------------------------------------------------------------------------------
2995 efi_headers = \
2996 src/boot/efi/console.h \
2997 src/boot/efi/disk.h \
2998 src/boot/efi/graphics.h \
2999 src/boot/efi/linux.h \
3000 src/boot/efi/measure.h \
3001 src/boot/efi/pefile.h \
3002 src/boot/efi/splash.h \
3003 src/boot/efi/util.h
3004
3005 systemd_boot_sources = \
3006 src/boot/efi/boot.c \
3007 src/boot/efi/console.c \
3008 src/boot/efi/disk.c \
3009 src/boot/efi/graphics.c \
3010 src/boot/efi/measure.c \
3011 src/boot/efi/pefile.c \
3012 src/boot/efi/util.c
3013
3014 EXTRA_DIST += $(systemd_boot_sources) $(systemd_boot_headers)
3015
3016 systemd_boot_objects = $(addprefix $(top_builddir)/,$(systemd_boot_sources:.c=.o))
3017 systemd_boot_solib = $(top_builddir)/src/boot/efi/systemd_boot.so
3018 systemd_boot = systemd-boot$(EFI_MACHINE_TYPE_NAME).efi
3019
3020 if ENABLE_EFI
3021 if HAVE_GNUEFI
3022 bootlib_DATA = $(systemd_boot)
3023
3024 $(top_builddir)/src/boot/efi/%.o: $(top_srcdir)/src/boot/efi/%.c $(addprefix $(top_srcdir)/,$(efi_headers))
3025 @$(MKDIR_P) $(top_builddir)/src/boot/efi/
3026 $(AM_V_CC)$(EFI_CC) $(efi_cppflags) $(efi_cflags) -c $< -o $@
3027
3028 $(systemd_boot_solib): $(systemd_boot_objects)
3029 $(AM_V_CCLD)$(LD) $(efi_ldflags) $(systemd_boot_objects) \
3030 -o $@ -lefi -lgnuefi $(shell $(CC) -print-libgcc-file-name); \
3031 nm -D -u $@ | grep ' U ' && exit 1 || :
3032
3033 $(systemd_boot): $(systemd_boot_solib)
3034 $(AM_V_GEN)$(OBJCOPY) -j .text -j .sdata -j .data -j .dynamic \
3035 -j .dynsym -j .rel -j .rela -j .reloc $(EFI_FORMAT) $< $@
3036 endif
3037 endif
3038
3039 CLEANFILES += $(systemd_boot_objects) $(systemd_boot_solib) $(systemd_boot)
3040
3041 # ------------------------------------------------------------------------------
3042 stub_sources = \
3043 src/boot/efi/disk.c \
3044 src/boot/efi/graphics.c \
3045 src/boot/efi/linux.c \
3046 src/boot/efi/measure.c \
3047 src/boot/efi/pefile.c \
3048 src/boot/efi/splash.c \
3049 src/boot/efi/stub.c \
3050 src/boot/efi/util.c
3051
3052 EXTRA_DIST += \
3053 $(stub_sources) \
3054 $(stub_headers) \
3055 test/splash.bmp
3056
3057 stub_objects = $(addprefix $(top_builddir)/,$(stub_sources:.c=.o))
3058 stub_solib = $(top_builddir)/src/boot/efi/stub.so
3059 stub = linux$(EFI_MACHINE_TYPE_NAME).efi.stub
3060
3061 if ENABLE_EFI
3062 if HAVE_GNUEFI
3063 bootlib_DATA += $(stub)
3064
3065 $(stub_solib): $(stub_objects)
3066 $(AM_V_CCLD)$(LD) $(efi_ldflags) $(stub_objects) \
3067 -o $@ -lefi -lgnuefi $(shell $(CC) -print-libgcc-file-name); \
3068 nm -D -u $@ | grep ' U ' && exit 1 || :
3069
3070 $(stub): $(stub_solib)
3071 $(AM_V_GEN)$(OBJCOPY) -j .text -j .sdata -j .data -j .dynamic \
3072 -j .dynsym -j .rel -j .rela -j .reloc $(EFI_FORMAT) $< $@
3073 endif
3074 endif
3075
3076 CLEANFILES += $(stub_objects) $(stub_solib) $(stub)
3077
3078
3079 # ------------------------------------------------------------------------------
3080 CLEANFILES += test-efi-disk.img
3081
3082 test-efi-disk.img: $(systemd_boot) $(stub) test/splash.bmp test/test-efi-create-disk.sh
3083 $(AM_V_GEN)test/test-efi-create-disk.sh $@ $(systemd_boot) $(stub) test/splash.bmp
3084
3085 test-efi: test-efi-disk.img
3086 $(QEMU) -machine accel=kvm -m 1024 -bios $(QEMU_BIOS) -snapshot test-efi-disk.img
3087
3088 EXTRA_DIST += test/test-efi-create-disk.sh
3089
3090 # ------------------------------------------------------------------------------
3091 if HAVE_BLKID
3092 systemgenerator_PROGRAMS += \
3093 systemd-gpt-auto-generator
3094
3095 systemd_gpt_auto_generator_SOURCES = \
3096 src/gpt-auto-generator/gpt-auto-generator.c \
3097 src/basic/blkid-util.h
3098
3099 systemd_gpt_auto_generator_LDADD = \
3100 libsystemd-shared.la \
3101 $(BLKID_LIBS)
3102
3103 systemd_gpt_auto_generator_CFLAGS = \
3104 $(AM_CFLAGS) \
3105 $(BLKID_CFLAGS)
3106 endif
3107
3108 # ------------------------------------------------------------------------------
3109 dist_xinitrc_SCRIPTS = \
3110 xorg/50-systemd-user.sh
3111
3112 # ------------------------------------------------------------------------------
3113 systemd_sysv_generator_SOURCES = \
3114 src/sysv-generator/sysv-generator.c
3115
3116 systemd_sysv_generator_LDADD = \
3117 libcore.la
3118
3119 # ------------------------------------------------------------------------------
3120 systemd_rc_local_generator_SOURCES = \
3121 src/rc-local-generator/rc-local-generator.c
3122
3123 systemd_rc_local_generator_LDADD = \
3124 libsystemd-shared.la
3125
3126 # ------------------------------------------------------------------------------
3127 systemd_remount_fs_SOURCES = \
3128 src/remount-fs/remount-fs.c \
3129 src/core/mount-setup.c \
3130 src/core/mount-setup.h
3131
3132 systemd_remount_fs_LDADD = \
3133 libsystemd-shared.la
3134
3135 # ------------------------------------------------------------------------------
3136 systemd_volatile_root_SOURCES = \
3137 src/volatile-root/volatile-root.c
3138
3139 systemd_volatile_root_LDADD = \
3140 libsystemd-shared.la
3141
3142 # ------------------------------------------------------------------------------
3143 systemd_cgroups_agent_SOURCES = \
3144 src/cgroups-agent/cgroups-agent.c
3145
3146 systemd_cgroups_agent_LDADD = \
3147 libsystemd-shared.la
3148
3149 # ------------------------------------------------------------------------------
3150 systemd_escape_SOURCES = \
3151 src/escape/escape.c
3152
3153 systemd_escape_LDADD = \
3154 libsystemd-shared.la
3155
3156 # -----------------------------------------------------------------------------
3157 systemctl_SOURCES = \
3158 src/systemctl/systemctl.c
3159
3160 systemctl_LDADD = \
3161 libsystemd-shared.la
3162
3163 # ------------------------------------------------------------------------------
3164 systemd_notify_SOURCES = \
3165 src/notify/notify.c
3166
3167 systemd_notify_LDADD = \
3168 libsystemd-shared.la
3169
3170 # ------------------------------------------------------------------------------
3171 systemd_dissect_SOURCES = \
3172 src/dissect/dissect.c
3173
3174 systemd_dissect_LDADD = \
3175 libsystemd-shared.la
3176
3177 # ------------------------------------------------------------------------------
3178 systemd_path_SOURCES = \
3179 src/path/path.c
3180
3181 systemd_path_LDADD = \
3182 libsystemd-shared.la
3183
3184 # ------------------------------------------------------------------------------
3185 systemd_ask_password_SOURCES = \
3186 src/ask-password/ask-password.c
3187
3188 systemd_ask_password_LDADD = \
3189 libsystemd-shared.la
3190
3191 # ------------------------------------------------------------------------------
3192 systemd_reply_password_SOURCES = \
3193 src/reply-password/reply-password.c
3194
3195 systemd_reply_password_LDADD = \
3196 libsystemd-shared.la
3197
3198 # ------------------------------------------------------------------------------
3199 systemd_cgls_SOURCES = \
3200 src/cgls/cgls.c
3201
3202 systemd_cgls_LDADD = \
3203 libsystemd-shared.la
3204
3205 # ------------------------------------------------------------------------------
3206 systemd_cgtop_SOURCES = \
3207 src/cgtop/cgtop.c
3208
3209 systemd_cgtop_LDADD = \
3210 libsystemd-shared.la
3211
3212 # ------------------------------------------------------------------------------
3213 systemd_nspawn_SOURCES = \
3214 src/nspawn/nspawn.c \
3215 src/nspawn/nspawn-settings.c \
3216 src/nspawn/nspawn-settings.h \
3217 src/nspawn/nspawn-mount.c \
3218 src/nspawn/nspawn-mount.h \
3219 src/nspawn/nspawn-network.c \
3220 src/nspawn/nspawn-network.h \
3221 src/nspawn/nspawn-expose-ports.c \
3222 src/nspawn/nspawn-expose-ports.h \
3223 src/nspawn/nspawn-cgroup.c \
3224 src/nspawn/nspawn-cgroup.h \
3225 src/nspawn/nspawn-seccomp.c \
3226 src/nspawn/nspawn-seccomp.h \
3227 src/nspawn/nspawn-register.c \
3228 src/nspawn/nspawn-register.h \
3229 src/nspawn/nspawn-setuid.c \
3230 src/nspawn/nspawn-setuid.h \
3231 src/nspawn/nspawn-stub-pid1.c \
3232 src/nspawn/nspawn-stub-pid1.h \
3233 src/nspawn/nspawn-patch-uid.c \
3234 src/nspawn/nspawn-patch-uid.h \
3235 src/core/mount-setup.c \
3236 src/core/mount-setup.h \
3237 src/core/loopback-setup.c \
3238 src/core/loopback-setup.h
3239
3240 nodist_systemd_nspawn_SOURCES = \
3241 src/nspawn/nspawn-gperf.c
3242
3243 gperf_gperf_sources += \
3244 src/nspawn/nspawn-gperf.gperf
3245
3246 systemd_nspawn_CFLAGS = \
3247 $(AM_CFLAGS) \
3248 $(ACL_CFLAGS) \
3249 $(BLKID_CFLAGS) \
3250 $(SECCOMP_CFLAGS) \
3251 $(SELINUX_CFLAGS)
3252
3253 systemd_nspawn_LDADD = \
3254 libsystemd-shared.la \
3255 $(ACL_LIBS) \
3256 $(BLKID_LIBS) \
3257 $(SECCOMP_LIBS) \
3258 $(SELINUX_LIBS)
3259
3260 if HAVE_LIBIPTC
3261 systemd_nspawn_LDADD += \
3262 libfirewall.la
3263 endif
3264
3265 test_patch_uid_SOURCES = \
3266 src/nspawn/nspawn-patch-uid.c \
3267 src/nspawn/nspawn-patch-uid.h \
3268 src/nspawn/test-patch-uid.c
3269
3270 test_patch_uid_CFLAGS = \
3271 $(AM_CFLAGS) \
3272 $(ACL_CFLAGS)
3273
3274 test_patch_uid_LDADD = \
3275 libsystemd-shared.la \
3276 $(ACL_LIBS)
3277
3278 manual_tests += \
3279 test-patch-uid
3280
3281 # ------------------------------------------------------------------------------
3282 systemd_run_SOURCES = \
3283 src/run/run.c
3284
3285 systemd_run_LDADD = \
3286 libsystemd-shared.la
3287
3288 # ------------------------------------------------------------------------------
3289 systemd_mount_SOURCES = \
3290 src/mount/mount-tool.c
3291
3292 systemd_mount_LDADD = \
3293 libsystemd-shared.la
3294
3295 # ------------------------------------------------------------------------------
3296 systemd_stdio_bridge_SOURCES = \
3297 src/stdio-bridge/stdio-bridge.c
3298
3299 systemd_stdio_bridge_LDADD = \
3300 libsystemd-shared.la
3301
3302 # ------------------------------------------------------------------------------
3303 systemd_tty_ask_password_agent_SOURCES = \
3304 src/tty-ask-password-agent/tty-ask-password-agent.c
3305
3306 systemd_tty_ask_password_agent_LDADD = \
3307 libsystemd-shared.la
3308
3309 # ------------------------------------------------------------------------------
3310 libsystemd_internal_la_SOURCES = \
3311 src/systemd/sd-bus.h \
3312 src/systemd/sd-bus-protocol.h \
3313 src/systemd/sd-bus-vtable.h \
3314 src/systemd/sd-utf8.h \
3315 src/systemd/sd-event.h \
3316 src/systemd/sd-netlink.h \
3317 src/systemd/sd-resolve.h \
3318 src/systemd/sd-login.h \
3319 src/systemd/sd-id128.h \
3320 src/systemd/sd-daemon.h \
3321 src/systemd/sd-path.h \
3322 src/systemd/sd-network.h \
3323 src/systemd/sd-hwdb.h \
3324 src/systemd/sd-device.h \
3325 src/libsystemd/libsystemd.sym \
3326 src/libsystemd/sd-bus/sd-bus.c \
3327 src/libsystemd/sd-bus/bus-control.c \
3328 src/libsystemd/sd-bus/bus-control.h \
3329 src/libsystemd/sd-bus/bus-error.c \
3330 src/libsystemd/sd-bus/bus-error.h \
3331 src/libsystemd/sd-bus/bus-common-errors.h \
3332 src/libsystemd/sd-bus/bus-common-errors.c \
3333 src/libsystemd/sd-bus/bus-internal.c \
3334 src/libsystemd/sd-bus/bus-internal.h \
3335 src/libsystemd/sd-bus/bus-socket.c \
3336 src/libsystemd/sd-bus/bus-socket.h \
3337 src/libsystemd/sd-bus/bus-kernel.c \
3338 src/libsystemd/sd-bus/bus-kernel.h \
3339 src/libsystemd/sd-bus/bus-container.c \
3340 src/libsystemd/sd-bus/bus-container.h \
3341 src/libsystemd/sd-bus/bus-message.c \
3342 src/libsystemd/sd-bus/bus-message.h \
3343 src/libsystemd/sd-bus/bus-creds.c \
3344 src/libsystemd/sd-bus/bus-creds.h \
3345 src/libsystemd/sd-bus/bus-signature.c \
3346 src/libsystemd/sd-bus/bus-signature.h \
3347 src/libsystemd/sd-bus/bus-type.c \
3348 src/libsystemd/sd-bus/bus-type.h \
3349 src/libsystemd/sd-bus/bus-match.c \
3350 src/libsystemd/sd-bus/bus-match.h \
3351 src/libsystemd/sd-bus/bus-bloom.c \
3352 src/libsystemd/sd-bus/bus-bloom.h \
3353 src/libsystemd/sd-bus/bus-introspect.c \
3354 src/libsystemd/sd-bus/bus-introspect.h \
3355 src/libsystemd/sd-bus/bus-objects.c \
3356 src/libsystemd/sd-bus/bus-objects.h \
3357 src/libsystemd/sd-bus/bus-gvariant.c \
3358 src/libsystemd/sd-bus/bus-gvariant.h \
3359 src/libsystemd/sd-bus/bus-convenience.c \
3360 src/libsystemd/sd-bus/bus-track.c \
3361 src/libsystemd/sd-bus/bus-track.h \
3362 src/libsystemd/sd-bus/bus-slot.c \
3363 src/libsystemd/sd-bus/bus-slot.h \
3364 src/libsystemd/sd-bus/bus-protocol.h \
3365 src/libsystemd/sd-bus/kdbus.h \
3366 src/libsystemd/sd-bus/bus-dump.c \
3367 src/libsystemd/sd-bus/bus-dump.h \
3368 src/libsystemd/sd-utf8/sd-utf8.c \
3369 src/libsystemd/sd-event/sd-event.c \
3370 src/libsystemd/sd-netlink/sd-netlink.c \
3371 src/libsystemd/sd-netlink/netlink-internal.h \
3372 src/libsystemd/sd-netlink/netlink-message.c \
3373 src/libsystemd/sd-netlink/netlink-socket.c \
3374 src/libsystemd/sd-netlink/rtnl-message.c \
3375 src/libsystemd/sd-netlink/netlink-types.h \
3376 src/libsystemd/sd-netlink/netlink-types.c \
3377 src/libsystemd/sd-netlink/netlink-util.h \
3378 src/libsystemd/sd-netlink/netlink-util.c \
3379 src/libsystemd/sd-netlink/local-addresses.h \
3380 src/libsystemd/sd-netlink/local-addresses.c \
3381 src/libsystemd/sd-id128/sd-id128.c \
3382 src/libsystemd/sd-id128/id128-util.h \
3383 src/libsystemd/sd-id128/id128-util.c \
3384 src/libsystemd/sd-daemon/sd-daemon.c \
3385 src/libsystemd/sd-login/sd-login.c \
3386 src/libsystemd/sd-path/sd-path.c \
3387 src/libsystemd/sd-network/sd-network.c \
3388 src/libsystemd/sd-network/network-util.h \
3389 src/libsystemd/sd-network/network-util.c \
3390 src/libsystemd/sd-hwdb/sd-hwdb.c \
3391 src/libsystemd/sd-hwdb/hwdb-util.h \
3392 src/libsystemd/sd-hwdb/hwdb-internal.h \
3393 src/libsystemd/sd-device/device-internal.h \
3394 src/libsystemd/sd-device/device-util.h \
3395 src/libsystemd/sd-device/device-enumerator.c \
3396 src/libsystemd/sd-device/device-enumerator-private.h \
3397 src/libsystemd/sd-device/sd-device.c \
3398 src/libsystemd/sd-device/device-private.c \
3399 src/libsystemd/sd-device/device-private.h \
3400 src/libsystemd/sd-resolve/sd-resolve.c
3401
3402 libsystemd_internal_la_LIBADD = \
3403 -lresolv
3404
3405 noinst_LTLIBRARIES += \
3406 libsystemd-internal.la
3407
3408 EXTRA_DIST += \
3409 src/libsystemd/libsystemd.pc.in \
3410 src/libsystemd/sd-bus/GVARIANT-SERIALIZATION
3411
3412 libsystemd_la_SOURCES =
3413
3414 libsystemd_la_LDFLAGS = \
3415 $(AM_LDFLAGS) \
3416 -version-info $(LIBSYSTEMD_CURRENT):$(LIBSYSTEMD_REVISION):$(LIBSYSTEMD_AGE) \
3417 -Wl,--version-script=$(top_srcdir)/src/libsystemd/libsystemd.sym
3418
3419 libsystemd_la_LIBADD = \
3420 libsystemd-internal.la \
3421 libbasic.la \
3422 libsystemd-journal-internal.la
3423
3424 pkgconfiglib_DATA += \
3425 src/libsystemd/libsystemd.pc
3426
3427 pkginclude_HEADERS += \
3428 src/systemd/sd-bus.h \
3429 src/systemd/sd-bus-protocol.h \
3430 src/systemd/sd-bus-vtable.h \
3431 src/systemd/sd-event.h \
3432 src/systemd/sd-login.h \
3433 src/systemd/sd-id128.h \
3434 src/systemd/sd-daemon.h
3435
3436 rootlib_LTLIBRARIES += \
3437 libsystemd.la
3438
3439 tests += \
3440 test-bus-marshal \
3441 test-bus-signature \
3442 test-bus-benchmark \
3443 test-bus-chat \
3444 test-bus-cleanup \
3445 test-bus-server \
3446 test-bus-match \
3447 test-bus-kernel \
3448 test-bus-kernel-bloom \
3449 test-bus-zero-copy \
3450 test-bus-introspect \
3451 test-bus-objects \
3452 test-bus-error \
3453 test-bus-creds \
3454 test-bus-gvariant \
3455 test-bus-track \
3456 test-event \
3457 test-netlink \
3458 test-local-addresses \
3459 test-resolve
3460
3461 bin_PROGRAMS += \
3462 busctl
3463
3464 test_bus_marshal_SOURCES = \
3465 src/libsystemd/sd-bus/test-bus-marshal.c
3466
3467 test_bus_marshal_LDADD = \
3468 libsystemd-shared.la \
3469 $(GLIB_LIBS) \
3470 $(DBUS_LIBS)
3471
3472 test_bus_marshal_CFLAGS = \
3473 $(AM_CFLAGS) \
3474 $(GLIB_CFLAGS) \
3475 $(DBUS_CFLAGS)
3476
3477 test_bus_signature_SOURCES = \
3478 src/libsystemd/sd-bus/test-bus-signature.c
3479
3480 test_bus_signature_LDADD = \
3481 libsystemd-shared.la
3482
3483 test_bus_chat_SOURCES = \
3484 src/libsystemd/sd-bus/test-bus-chat.c
3485
3486 test_bus_chat_LDADD = \
3487 libsystemd-shared.la
3488
3489 test_bus_cleanup_SOURCES = \
3490 src/libsystemd/sd-bus/test-bus-cleanup.c
3491
3492 test_bus_cleanup_CFLAGS = \
3493 $(AM_CFLAGS) \
3494 $(SECCOMP_CFLAGS)
3495
3496 test_bus_cleanup_LDADD = \
3497 libsystemd-shared.la
3498
3499 test_bus_track_SOURCES = \
3500 src/libsystemd/sd-bus/test-bus-track.c
3501
3502 test_bus_track_CFLAGS = \
3503 $(AM_CFLAGS) \
3504 $(SECCOMP_CFLAGS)
3505
3506 test_bus_track_LDADD = \
3507 libsystemd-shared.la
3508
3509 test_bus_server_SOURCES = \
3510 src/libsystemd/sd-bus/test-bus-server.c
3511
3512 test_bus_server_LDADD = \
3513 libsystemd-shared.la
3514
3515 test_bus_objects_SOURCES = \
3516 src/libsystemd/sd-bus/test-bus-objects.c
3517
3518 test_bus_objects_LDADD = \
3519 libsystemd-shared.la
3520
3521 test_bus_error_SOURCES = \
3522 src/libsystemd/sd-bus/test-bus-error.c
3523
3524 # Link statically because this test uses BUS_ERROR_MAP_ELF_REGISTER
3525 test_bus_error_LDADD = \
3526 libshared.la
3527
3528 test_bus_gvariant_SOURCES = \
3529 src/libsystemd/sd-bus/test-bus-gvariant.c
3530
3531 test_bus_gvariant_LDADD = \
3532 libsystemd-shared.la \
3533 $(GLIB_LIBS)
3534
3535 test_bus_gvariant_CFLAGS = \
3536 $(AM_CFLAGS) \
3537 $(GLIB_CFLAGS)
3538
3539 test_bus_creds_SOURCES = \
3540 src/libsystemd/sd-bus/test-bus-creds.c
3541
3542 test_bus_creds_LDADD = \
3543 libsystemd-shared.la
3544
3545 test_bus_match_SOURCES = \
3546 src/libsystemd/sd-bus/test-bus-match.c
3547
3548 test_bus_match_LDADD = \
3549 libsystemd-shared.la
3550
3551 test_bus_kernel_SOURCES = \
3552 src/libsystemd/sd-bus/test-bus-kernel.c
3553
3554 test_bus_kernel_LDADD = \
3555 libsystemd-shared.la
3556
3557 test_bus_kernel_bloom_SOURCES = \
3558 src/libsystemd/sd-bus/test-bus-kernel-bloom.c
3559
3560 test_bus_kernel_bloom_LDADD = \
3561 libsystemd-shared.la
3562
3563 test_bus_benchmark_SOURCES = \
3564 src/libsystemd/sd-bus/test-bus-benchmark.c
3565
3566 test_bus_benchmark_LDADD = \
3567 libsystemd-shared.la
3568
3569 test_bus_zero_copy_SOURCES = \
3570 src/libsystemd/sd-bus/test-bus-zero-copy.c
3571
3572 test_bus_zero_copy_LDADD = \
3573 libsystemd-shared.la
3574
3575 test_bus_introspect_SOURCES = \
3576 src/libsystemd/sd-bus/test-bus-introspect.c
3577
3578 test_bus_introspect_LDADD = \
3579 libsystemd-shared.la
3580
3581 test_event_SOURCES = \
3582 src/libsystemd/sd-event/test-event.c
3583
3584 test_event_LDADD = \
3585 libsystemd-shared.la
3586
3587 test_netlink_SOURCES = \
3588 src/libsystemd/sd-netlink/test-netlink.c
3589
3590 test_netlink_LDADD = \
3591 libsystemd-shared.la
3592
3593 test_local_addresses_SOURCES = \
3594 src/libsystemd/sd-netlink/test-local-addresses.c
3595
3596 test_local_addresses_LDADD = \
3597 libsystemd-shared.la
3598
3599 test_resolve_SOURCES = \
3600 src/libsystemd/sd-resolve/test-resolve.c
3601
3602 test_resolve_LDADD = \
3603 libsystemd-shared.la
3604
3605 busctl_SOURCES = \
3606 src/busctl/busctl.c \
3607 src/busctl/busctl-introspect.c \
3608 src/busctl/busctl-introspect.h
3609
3610 busctl_LDADD = \
3611 libsystemd-shared.la
3612
3613 # ------------------------------------------------------------------------------
3614 noinst_LTLIBRARIES += \
3615 libsystemd-network.la
3616
3617 libsystemd_network_la_CFLAGS = \
3618 $(AM_CFLAGS) \
3619 $(KMOD_CFLAGS)
3620
3621 libsystemd_network_la_SOURCES = \
3622 src/systemd/sd-dhcp-client.h \
3623 src/systemd/sd-dhcp-server.h \
3624 src/systemd/sd-dhcp-lease.h \
3625 src/systemd/sd-ipv4ll.h \
3626 src/systemd/sd-ipv4acd.h \
3627 src/systemd/sd-ndisc.h \
3628 src/systemd/sd-dhcp6-client.h \
3629 src/systemd/sd-dhcp6-lease.h \
3630 src/systemd/sd-lldp.h \
3631 src/libsystemd-network/sd-dhcp-client.c \
3632 src/libsystemd-network/sd-dhcp-server.c \
3633 src/libsystemd-network/dhcp-network.c \
3634 src/libsystemd-network/dhcp-option.c \
3635 src/libsystemd-network/dhcp-packet.c \
3636 src/libsystemd-network/dhcp-internal.h \
3637 src/libsystemd-network/dhcp-server-internal.h \
3638 src/libsystemd-network/dhcp-protocol.h \
3639 src/libsystemd-network/dhcp-lease-internal.h \
3640 src/libsystemd-network/sd-dhcp-lease.c \
3641 src/libsystemd-network/sd-ipv4ll.c \
3642 src/libsystemd-network/sd-ipv4acd.c \
3643 src/libsystemd-network/arp-util.h \
3644 src/libsystemd-network/arp-util.c \
3645 src/libsystemd-network/network-internal.c \
3646 src/libsystemd-network/network-internal.h \
3647 src/libsystemd-network/sd-ndisc.c \
3648 src/libsystemd-network/ndisc-internal.h \
3649 src/libsystemd-network/ndisc-router.h \
3650 src/libsystemd-network/ndisc-router.c \
3651 src/libsystemd-network/icmp6-util.h \
3652 src/libsystemd-network/icmp6-util.c \
3653 src/libsystemd-network/sd-dhcp6-client.c \
3654 src/libsystemd-network/dhcp6-internal.h \
3655 src/libsystemd-network/dhcp6-protocol.h \
3656 src/libsystemd-network/dhcp6-network.c \
3657 src/libsystemd-network/dhcp6-option.c \
3658 src/libsystemd-network/dhcp6-lease-internal.h \
3659 src/libsystemd-network/sd-dhcp6-lease.c \
3660 src/libsystemd-network/dhcp-identifier.h \
3661 src/libsystemd-network/dhcp-identifier.c \
3662 src/libsystemd-network/lldp-internal.h \
3663 src/libsystemd-network/lldp-network.h \
3664 src/libsystemd-network/lldp-network.c \
3665 src/libsystemd-network/lldp-neighbor.h \
3666 src/libsystemd-network/lldp-neighbor.c \
3667 src/libsystemd-network/sd-lldp.c
3668
3669 libsystemd_network_la_LIBADD = \
3670 $(KMOD_LIBS)
3671
3672 test_dhcp_option_SOURCES = \
3673 src/libsystemd-network/dhcp-protocol.h \
3674 src/libsystemd-network/dhcp-internal.h \
3675 src/libsystemd-network/test-dhcp-option.c
3676
3677 test_dhcp_option_LDADD = \
3678 libsystemd-network.la \
3679 libsystemd-shared.la
3680
3681 test_dhcp_client_SOURCES = \
3682 src/systemd/sd-dhcp-client.h \
3683 src/libsystemd-network/dhcp-protocol.h \
3684 src/libsystemd-network/dhcp-internal.h \
3685 src/libsystemd-network/test-dhcp-client.c
3686
3687 test_dhcp_client_LDADD = \
3688 libsystemd-network.la \
3689 libsystemd-shared.la
3690
3691 test_dhcp_server_SOURCES = \
3692 src/libsystemd-network/test-dhcp-server.c
3693
3694 test_dhcp_server_LDADD = \
3695 libsystemd-network.la \
3696 libsystemd-shared.la
3697
3698 test_ipv4ll_SOURCES = \
3699 src/systemd/sd-ipv4ll.h \
3700 src/libsystemd-network/arp-util.h \
3701 src/libsystemd-network/test-ipv4ll.c
3702
3703 test_ipv4ll_LDADD = \
3704 libsystemd-network.la \
3705 libsystemd-shared.la
3706
3707 test_ipv4ll_manual_SOURCES = \
3708 src/systemd/sd-ipv4ll.h \
3709 src/libsystemd-network/test-ipv4ll-manual.c
3710
3711 test_ipv4ll_manual_LDADD = \
3712 libsystemd-network.la \
3713 libsystemd-shared.la
3714
3715 test_acd_SOURCES = \
3716 src/systemd/sd-ipv4acd.h \
3717 src/libsystemd-network/test-acd.c
3718
3719 test_acd_LDADD = \
3720 libsystemd-network.la \
3721 libsystemd-shared.la
3722
3723 test_ndisc_rs_SOURCES = \
3724 src/systemd/sd-dhcp6-client.h \
3725 src/systemd/sd-ndisc.h \
3726 src/libsystemd-network/icmp6-util.h \
3727 src/libsystemd-network/test-ndisc-rs.c \
3728 src/libsystemd-network/dhcp-identifier.h \
3729 src/libsystemd-network/dhcp-identifier.c
3730
3731 test_ndisc_rs_LDADD = \
3732 libsystemd-network.la \
3733 libudev.la \
3734 libsystemd-shared.la
3735
3736 test_dhcp6_client_SOURCES = \
3737 src/systemd/sd-dhcp6-client.h \
3738 src/libsystemd-network/dhcp6-internal.h \
3739 src/libsystemd-network/test-dhcp6-client.c \
3740 src/libsystemd-network/dhcp-identifier.h \
3741 src/libsystemd-network/dhcp-identifier.c
3742
3743 test_dhcp6_client_LDADD = \
3744 libsystemd-network.la \
3745 libudev.la \
3746 libsystemd-shared.la
3747
3748 test_lldp_SOURCES = \
3749 src/libsystemd-network/test-lldp.c
3750
3751 test_lldp_LDADD = \
3752 libsystemd-network.la \
3753 libsystemd-shared.la
3754
3755 tests += \
3756 test-dhcp-option \
3757 test-dhcp-client \
3758 test-dhcp-server \
3759 test-ipv4ll \
3760 test-ndisc-rs \
3761 test-dhcp6-client \
3762 test-lldp
3763
3764 # ------------------------------------------------------------------------------
3765 include_HEADERS += \
3766 src/libudev/libudev.h
3767
3768 rootlib_LTLIBRARIES += \
3769 libudev.la
3770
3771 libudev_la_SOURCES =\
3772 src/libudev/libudev.sym \
3773 src/libudev/libudev-private.h \
3774 src/libudev/libudev-device-internal.h \
3775 src/libudev/libudev.c \
3776 src/libudev/libudev-list.c \
3777 src/libudev/libudev-util.c \
3778 src/libudev/libudev-device.c \
3779 src/libudev/libudev-device-private.c \
3780 src/libudev/libudev-enumerate.c \
3781 src/libudev/libudev-monitor.c \
3782 src/libudev/libudev-queue.c \
3783 src/libudev/libudev-hwdb.c
3784
3785 libudev_la_LDFLAGS = \
3786 $(AM_LDFLAGS) \
3787 -version-info $(LIBUDEV_CURRENT):$(LIBUDEV_REVISION):$(LIBUDEV_AGE) \
3788 -Wl,--version-script=$(top_srcdir)/src/libudev/libudev.sym
3789
3790 libudev_la_LIBADD = \
3791 libsystemd-internal.la \
3792 libbasic.la
3793
3794 pkgconfiglib_DATA += \
3795 src/libudev/libudev.pc
3796
3797 EXTRA_DIST += \
3798 src/libudev/libudev.pc.in
3799
3800 # ------------------------------------------------------------------------------
3801 noinst_LTLIBRARIES += \
3802 libudev-internal.la
3803
3804 libudev_internal_la_SOURCES =\
3805 $(libudev_la_SOURCES)
3806
3807 # ------------------------------------------------------------------------------
3808 INSTALL_DIRS += \
3809 $(sysconfdir)/udev/rules.d
3810
3811 dist_network_DATA = \
3812 network/99-default.link \
3813 network/80-container-host0.network \
3814 network/80-container-ve.network \
3815 network/80-container-vz.network
3816
3817 dist_udevrules_DATA += \
3818 rules/60-block.rules \
3819 rules/60-drm.rules \
3820 rules/60-evdev.rules \
3821 rules/60-persistent-storage-tape.rules \
3822 rules/60-persistent-input.rules \
3823 rules/60-persistent-alsa.rules \
3824 rules/60-persistent-storage.rules \
3825 rules/60-sensor.rules \
3826 rules/60-serial.rules \
3827 rules/64-btrfs.rules \
3828 rules/70-mouse.rules \
3829 rules/70-touchpad.rules \
3830 rules/75-net-description.rules \
3831 rules/78-sound-card.rules \
3832 rules/80-net-setup-link.rules
3833
3834 nodist_udevrules_DATA += \
3835 rules/50-udev-default.rules \
3836 rules/99-systemd.rules
3837
3838 udevconfdir = $(sysconfdir)/udev
3839 dist_udevconf_DATA = \
3840 src/udev/udev.conf
3841
3842 pkgconfigdata_DATA += \
3843 src/udev/udev.pc
3844
3845 EXTRA_DIST += \
3846 rules/50-udev-default.rules.in \
3847 rules/99-systemd.rules.in \
3848 src/udev/udev.pc.in
3849
3850 EXTRA_DIST += \
3851 units/systemd-udevd.service.in \
3852 units/systemd-udev-trigger.service.in \
3853 units/systemd-udev-settle.service.in
3854
3855 SOCKETS_TARGET_WANTS += \
3856 systemd-udevd-control.socket \
3857 systemd-udevd-kernel.socket
3858
3859 SYSINIT_TARGET_WANTS += \
3860 systemd-udevd.service \
3861 systemd-udev-trigger.service
3862
3863 rootbin_PROGRAMS += \
3864 udevadm
3865
3866 rootlibexec_PROGRAMS += \
3867 systemd-udevd
3868
3869 noinst_LTLIBRARIES += \
3870 libudev-core.la
3871
3872 src/udev/keyboard-keys-list.txt:
3873 $(AM_V_at)$(MKDIR_P) $(dir $@)
3874 $(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM -include linux/input.h - < /dev/null | $(AWK) '/^#define[ \t]+KEY_[^ ]+[ \t]+[0-9K]/ { if ($$2 != "KEY_MAX") { print $$2 } }' > $@
3875
3876 src/udev/keyboard-keys-from-name.gperf: src/udev/keyboard-keys-list.txt
3877 $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct key_name { const char* name; unsigned short id; };"; print "%null-strings"; print "%%";} { print tolower(substr($$1 ,5)) ", " $$1 }' < $< > $@
3878
3879 src/udev/keyboard-keys-from-name.h: src/udev/keyboard-keys-from-name.gperf
3880 $(AM_V_GPERF)$(GPERF) -L ANSI-C -t -N keyboard_lookup_key -H hash_key_name -p -C < $< > $@
3881
3882 gperf_txt_sources += \
3883 src/udev/keyboard-keys-list.txt
3884
3885 libudev_core_la_SOURCES = \
3886 src/udev/udev.h \
3887 src/udev/udev-event.c \
3888 src/udev/udev-watch.c \
3889 src/udev/udev-node.c \
3890 src/udev/udev-rules.c \
3891 src/udev/udev-ctrl.c \
3892 src/udev/udev-builtin.c \
3893 src/udev/udev-builtin-btrfs.c \
3894 src/udev/udev-builtin-hwdb.c \
3895 src/udev/udev-builtin-input_id.c \
3896 src/udev/udev-builtin-keyboard.c \
3897 src/udev/udev-builtin-net_id.c \
3898 src/udev/udev-builtin-net_setup_link.c \
3899 src/udev/udev-builtin-path_id.c \
3900 src/udev/udev-builtin-usb_id.c \
3901 src/udev/net/link-config.h \
3902 src/udev/net/link-config.c \
3903 src/udev/net/ethtool-util.h \
3904 src/udev/net/ethtool-util.c
3905
3906 nodist_libudev_core_la_SOURCES = \
3907 src/udev/keyboard-keys-from-name.h \
3908 src/udev/net/link-config-gperf.c
3909
3910 gperf_gperf_sources += \
3911 src/udev/net/link-config-gperf.gperf
3912
3913 libudev_core_la_CFLAGS = \
3914 $(AM_CFLAGS) \
3915 $(BLKID_CFLAGS) \
3916 $(KMOD_CFLAGS)
3917
3918 libudev_core_la_LIBADD = \
3919 libsystemd-network.la \
3920 libshared.la \
3921 $(BLKID_LIBS) \
3922 $(KMOD_LIBS)
3923
3924 if HAVE_KMOD
3925 libudev_core_la_SOURCES += \
3926 src/udev/udev-builtin-kmod.c
3927
3928 dist_udevrules_DATA += \
3929 rules/80-drivers.rules
3930 endif
3931
3932 if HAVE_BLKID
3933 libudev_core_la_SOURCES += \
3934 src/udev/udev-builtin-blkid.c
3935 endif
3936
3937 if HAVE_ACL
3938 libudev_core_la_SOURCES += \
3939 src/udev/udev-builtin-uaccess.c \
3940 src/login/logind-acl.c \
3941 src/libsystemd/sd-login/sd-login.c \
3942 src/systemd/sd-login.h
3943 endif
3944
3945 systemd_udevd_SOURCES = \
3946 src/udev/udevd.c
3947
3948 systemd_udevd_LDADD = \
3949 libudev-core.la \
3950 libbasic.la
3951
3952 udevadm_SOURCES = \
3953 src/udev/udevadm.c \
3954 src/udev/udevadm-info.c \
3955 src/udev/udevadm-control.c \
3956 src/udev/udevadm-monitor.c \
3957 src/udev/udevadm-hwdb.c \
3958 src/udev/udevadm-settle.c \
3959 src/udev/udevadm-trigger.c \
3960 src/udev/udevadm-test.c \
3961 src/udev/udevadm-test-builtin.c \
3962 src/udev/udevadm-util.c \
3963 src/udev/udevadm-util.h
3964
3965 udevadm_LDADD = \
3966 libudev-core.la \
3967 libbasic.la
3968
3969 # ------------------------------------------------------------------------------
3970 if ENABLE_HWDB
3971 INSTALL_DIRS += \
3972 $(sysconfdir)/udev/hwdb.d
3973
3974 systemd_hwdb_SOURCES = \
3975 src/libsystemd/sd-hwdb/hwdb-internal.h \
3976 src/hwdb/hwdb.c
3977
3978 systemd_hwdb_LDADD = \
3979 libshared.la
3980
3981 rootbin_PROGRAMS += \
3982 systemd-hwdb
3983
3984 dist_udevhwdb_DATA = \
3985 hwdb/20-pci-vendor-model.hwdb \
3986 hwdb/20-pci-classes.hwdb \
3987 hwdb/20-usb-vendor-model.hwdb \
3988 hwdb/20-usb-classes.hwdb \
3989 hwdb/20-sdio-vendor-model.hwdb \
3990 hwdb/20-sdio-classes.hwdb \
3991 hwdb/20-bluetooth-vendor-product.hwdb \
3992 hwdb/20-acpi-vendor.hwdb \
3993 hwdb/20-OUI.hwdb \
3994 hwdb/20-net-ifname.hwdb \
3995 hwdb/60-evdev.hwdb \
3996 hwdb/60-keyboard.hwdb \
3997 hwdb/60-sensor.hwdb \
3998 hwdb/70-mouse.hwdb \
3999 hwdb/70-pointingstick.hwdb \
4000 hwdb/70-touchpad.hwdb
4001
4002 SYSINIT_TARGET_WANTS += \
4003 systemd-hwdb-update.service
4004
4005 # Update hwdb on installation. Do not bother if installing
4006 # in DESTDIR, since this is likely for packaging purposes.
4007 hwdb-update-hook:
4008 -test -n "$(DESTDIR)" || $(rootbindir)/systemd-hwdb update
4009
4010 INSTALL_DATA_HOOKS += \
4011 hwdb-update-hook
4012
4013 hwdb-remove-hook:
4014 -test -n "$(DESTDIR)" || rm -f /etc/udev/hwdb.bin
4015 endif
4016
4017 EXTRA_DIST += \
4018 units/systemd-hwdb-update.service.in \
4019 hwdb/ids-update.pl \
4020 hwdb/sdio.ids
4021
4022 # ------------------------------------------------------------------------------
4023 if ENABLE_TESTS
4024 TESTS += \
4025 test/udev-test.pl \
4026 test/hwdb-test.sh
4027
4028 if HAVE_PYTHON
4029 TESTS += \
4030 test/rule-syntax-check.py \
4031 hwdb/parse_hwdb.py
4032
4033 if HAVE_SYSV_COMPAT
4034 TESTS += \
4035 test/sysv-generator-test.py
4036 endif
4037 endif
4038 endif
4039
4040 tests += \
4041 test-libudev
4042
4043 manual_tests += \
4044 test-udev
4045
4046 test_libudev_SOURCES = \
4047 src/test/test-libudev.c
4048
4049 test_libudev_LDADD = \
4050 libsystemd-shared.la
4051
4052 test_udev_SOURCES = \
4053 src/test/test-udev.c
4054
4055 test_udev_LDADD = \
4056 libudev-core.la \
4057 libsystemd-shared.la \
4058 $(BLKID_LIBS) \
4059 $(KMOD_LIBS) \
4060 -lrt
4061
4062 if ENABLE_TESTS
4063 check_DATA += \
4064 test/sys
4065 endif
4066
4067 # sysfs test tree
4068 test/sys: test/sys-script.py
4069 -rm -rf $@
4070 $(AM_V_at)$(MKDIR_P) $(dir $@)
4071 $(AM_V_GEN)$(top_srcdir)/test/sys-script.py $(dir $@)
4072 -touch $@
4073
4074 test-sys-distclean:
4075 -rm -rf test/sys
4076 DISTCLEAN_LOCAL_HOOKS += test-sys-distclean
4077
4078 EXTRA_DIST += \
4079 test/sys-script.py \
4080 test/udev-test.pl \
4081 test/hwdb-test.sh \
4082 test/rule-syntax-check.py \
4083 test/sysv-generator-test.py \
4084 test/mocks/fsck \
4085 hwdb/parse_hwdb.py
4086
4087 # ------------------------------------------------------------------------------
4088 ata_id_SOURCES = \
4089 src/udev/ata_id/ata_id.c
4090
4091 ata_id_LDADD = \
4092 libshared.la
4093
4094 udevlibexec_PROGRAMS += \
4095 ata_id
4096
4097 # ------------------------------------------------------------------------------
4098 cdrom_id_SOURCES = \
4099 src/udev/cdrom_id/cdrom_id.c
4100
4101 cdrom_id_LDADD = \
4102 libshared.la
4103
4104 udevlibexec_PROGRAMS += \
4105 cdrom_id
4106
4107 dist_udevrules_DATA += \
4108 rules/60-cdrom_id.rules
4109
4110 # ------------------------------------------------------------------------------
4111 collect_SOURCES = \
4112 src/udev/collect/collect.c
4113
4114 collect_LDADD = \
4115 libshared.la
4116
4117 udevlibexec_PROGRAMS += \
4118 collect
4119
4120 # ------------------------------------------------------------------------------
4121 scsi_id_SOURCES =\
4122 src/udev/scsi_id/scsi_id.c \
4123 src/udev/scsi_id/scsi_serial.c \
4124 src/udev/scsi_id/scsi.h \
4125 src/udev/scsi_id/scsi_id.h
4126
4127 scsi_id_LDADD = \
4128 libshared.la
4129
4130 udevlibexec_PROGRAMS += \
4131 scsi_id
4132
4133 EXTRA_DIST += \
4134 src/udev/scsi_id/README
4135
4136 # ------------------------------------------------------------------------------
4137 v4l_id_SOURCES = \
4138 src/udev/v4l_id/v4l_id.c
4139
4140 v4l_id_LDADD = \
4141 libshared.la
4142
4143 udevlibexec_PROGRAMS += \
4144 v4l_id
4145
4146 dist_udevrules_DATA += \
4147 rules/60-persistent-v4l.rules
4148
4149 # ------------------------------------------------------------------------------
4150 mtd_probe_SOURCES = \
4151 src/udev/mtd_probe/mtd_probe.c \
4152 src/udev/mtd_probe/mtd_probe.h \
4153 src/udev/mtd_probe/probe_smartmedia.c
4154
4155 dist_udevrules_DATA += \
4156 rules/75-probe_mtd.rules
4157
4158 udevlibexec_PROGRAMS += \
4159 mtd_probe
4160
4161 # ------------------------------------------------------------------------------
4162 test_id128_SOURCES = \
4163 src/test/test-id128.c
4164
4165 test_id128_LDADD = \
4166 libsystemd-shared.la
4167
4168 tests += \
4169 test-id128
4170
4171 # ------------------------------------------------------------------------------
4172 test_hash_SOURCES = \
4173 src/test/test-hash.c
4174
4175 test_hash_LDADD = \
4176 libsystemd-shared.la
4177
4178 tests += \
4179 test-hash
4180
4181 # ------------------------------------------------------------------------------
4182
4183 bin_PROGRAMS += \
4184 systemd-socket-activate
4185
4186 systemd_socket_activate_SOURCES = \
4187 src/activate/activate.c
4188
4189 systemd_socket_activate_LDADD = \
4190 libsystemd-shared.la
4191
4192 # ------------------------------------------------------------------------------
4193 systemd_journald_SOURCES = \
4194 src/journal/journald.c \
4195 src/journal/journald-server.h
4196
4197 systemd_journald_LDADD = \
4198 libjournal-core.la \
4199 libsystemd-shared.la
4200
4201 systemd_cat_SOURCES = \
4202 src/journal/cat.c
4203
4204 systemd_cat_LDADD = \
4205 libjournal-core.la
4206
4207 if HAVE_LIBCURL
4208 rootlibexec_PROGRAMS += \
4209 systemd-journal-upload
4210
4211 systemd_journal_upload_SOURCES = \
4212 src/journal-remote/journal-upload.h \
4213 src/journal-remote/journal-upload.c \
4214 src/journal-remote/journal-upload-journal.c
4215
4216 systemd_journal_upload_CFLAGS = \
4217 $(AM_CFLAGS) \
4218 $(LIBCURL_CFLAGS)
4219
4220 systemd_journal_upload_LDADD = \
4221 libsystemd-shared.la \
4222 $(LIBCURL_LIBS)
4223
4224 nodist_systemunit_DATA += \
4225 units/systemd-journal-upload.service
4226
4227 nodist_pkgsysconf_DATA += \
4228 src/journal-remote/journal-upload.conf
4229 endif
4230
4231 EXTRA_DIST += \
4232 units/systemd-journal-upload.service.in \
4233 src/journal-remote/journal-upload.conf.in
4234
4235 if HAVE_MICROHTTPD
4236 rootlibexec_PROGRAMS += \
4237 systemd-journal-remote
4238
4239 systemd_journal_remote_SOURCES = \
4240 src/journal-remote/journal-remote-parse.h \
4241 src/journal-remote/journal-remote-parse.c \
4242 src/journal-remote/journal-remote-write.h \
4243 src/journal-remote/journal-remote-write.c \
4244 src/journal-remote/journal-remote.h \
4245 src/journal-remote/journal-remote.c
4246
4247 systemd_journal_remote_LDADD = \
4248 libjournal-core.la
4249
4250 systemd_journal_remote_SOURCES += \
4251 src/journal-remote/microhttpd-util.h \
4252 src/journal-remote/microhttpd-util.c
4253
4254 systemd_journal_remote_CFLAGS = \
4255 $(AM_CFLAGS) \
4256 $(MICROHTTPD_CFLAGS)
4257
4258 systemd_journal_remote_LDADD += \
4259 $(MICROHTTPD_LIBS)
4260
4261 if ENABLE_TMPFILES
4262 dist_tmpfiles_DATA += \
4263 tmpfiles.d/systemd-remote.conf
4264 endif
4265
4266 if HAVE_GNUTLS
4267 systemd_journal_remote_LDADD += \
4268 $(GNUTLS_LIBS)
4269 endif
4270
4271 # systemd-journal-remote make sense mostly with full crypto stack
4272 dist_systemunit_DATA += \
4273 units/systemd-journal-remote.socket
4274
4275 nodist_systemunit_DATA += \
4276 units/systemd-journal-remote.service
4277
4278 journal-remote-install-hook: journal-install-hook
4279 -$(MKDIR_P) $(DESTDIR)/var/log/journal/remote
4280 -chown 0:0 $(DESTDIR)/var/log/journal/remote
4281 -chmod 755 $(DESTDIR)/var/log/journal/remote
4282
4283 INSTALL_EXEC_HOOKS += journal-remote-install-hook
4284
4285 nodist_pkgsysconf_DATA += \
4286 src/journal-remote/journal-remote.conf
4287
4288 EXTRA_DIST += \
4289 units/systemd-journal-remote.service.in \
4290 src/journal-remote/journal-remote.conf.in \
4291 src/journal-remote/log-generator.py
4292 endif
4293
4294 # using _CFLAGS = in the conditional below would suppress AM_CFLAGS
4295 journalctl_CFLAGS = \
4296 $(AM_CFLAGS)
4297
4298 journalctl_SOURCES = \
4299 src/journal/journalctl.c
4300
4301 journalctl_LDADD = \
4302 libsystemd-shared.la \
4303 libudev-core.la
4304
4305 if HAVE_QRENCODE
4306 journalctl_SOURCES += \
4307 src/journal/journal-qrcode.c \
4308 src/journal/journal-qrcode.h
4309
4310 journalctl_CFLAGS += \
4311 $(QRENCODE_CFLAGS)
4312
4313 journalctl_LDADD += \
4314 $(QRENCODE_LIBS)
4315 endif
4316
4317 test_journal_SOURCES = \
4318 src/journal/test-journal.c
4319
4320 test_journal_LDADD = \
4321 libjournal-core.la
4322
4323 test_journal_send_SOURCES = \
4324 src/journal/test-journal-send.c
4325
4326 test_journal_send_LDADD = \
4327 libjournal-core.la
4328
4329 test_journal_syslog_SOURCES = \
4330 src/journal/test-journal-syslog.c
4331
4332 test_journal_syslog_LDADD = \
4333 libjournal-core.la
4334
4335 test_journal_match_SOURCES = \
4336 src/journal/test-journal-match.c
4337
4338 test_journal_match_LDADD = \
4339 libjournal-core.la
4340
4341 test_journal_enum_SOURCES = \
4342 src/journal/test-journal-enum.c
4343
4344 test_journal_enum_LDADD = \
4345 libjournal-core.la
4346
4347 test_journal_stream_SOURCES = \
4348 src/journal/test-journal-stream.c
4349
4350 test_journal_stream_LDADD = \
4351 libjournal-core.la
4352
4353 test_journal_flush_SOURCES = \
4354 src/journal/test-journal-flush.c
4355
4356 test_journal_flush_LDADD = \
4357 libjournal-core.la
4358
4359 test_journal_init_SOURCES = \
4360 src/journal/test-journal-init.c
4361
4362 test_journal_init_LDADD = \
4363 libjournal-core.la
4364
4365 test_journal_verify_SOURCES = \
4366 src/journal/test-journal-verify.c
4367
4368 test_journal_verify_LDADD = \
4369 libjournal-core.la
4370
4371 test_journal_interleaving_SOURCES = \
4372 src/journal/test-journal-interleaving.c
4373
4374 test_journal_interleaving_LDADD = \
4375 libjournal-core.la
4376
4377 test_mmap_cache_SOURCES = \
4378 src/journal/test-mmap-cache.c
4379
4380 test_mmap_cache_LDADD = \
4381 libjournal-core.la
4382
4383 test_catalog_SOURCES = \
4384 src/journal/test-catalog.c
4385
4386 test_catalog_CPPFLAGS = \
4387 $(AM_CPPFLAGS) \
4388 -DCATALOG_DIR=\"$(abs_top_builddir)/catalog\"
4389
4390 test_catalog_LDADD = \
4391 libjournal-core.la
4392
4393 test_compress_SOURCES = \
4394 src/journal/test-compress.c
4395
4396 test_compress_LDADD = \
4397 libsystemd-shared.la
4398
4399 if HAVE_LZ4
4400 test_compress_LDADD += \
4401 -llz4
4402 endif
4403
4404 test_compress_benchmark_SOURCES = \
4405 src/journal/test-compress-benchmark.c
4406
4407 test_compress_benchmark_LDADD = \
4408 libsystemd-shared.la
4409
4410 test_audit_type_SOURCES = \
4411 src/journal/test-audit-type.c
4412
4413 test_audit_type_LDADD = \
4414 libjournal-core.la
4415
4416 libjournal_core_la_SOURCES = \
4417 src/journal/journald-kmsg.c \
4418 src/journal/journald-kmsg.h \
4419 src/journal/journald-syslog.c \
4420 src/journal/journald-syslog.h \
4421 src/journal/journald-stream.c \
4422 src/journal/journald-stream.h \
4423 src/journal/journald-server.c \
4424 src/journal/journald-server.h \
4425 src/journal/journald-console.c \
4426 src/journal/journald-console.h \
4427 src/journal/journald-wall.c \
4428 src/journal/journald-wall.h \
4429 src/journal/journald-native.c \
4430 src/journal/journald-native.h \
4431 src/journal/journald-audit.c \
4432 src/journal/journald-audit.h \
4433 src/journal/journald-rate-limit.c \
4434 src/journal/journald-rate-limit.h \
4435 src/journal/journal-internal.h
4436
4437 nodist_libjournal_core_la_SOURCES = \
4438 src/journal/journald-gperf.c
4439
4440 libjournal_core_la_LIBADD = \
4441 libsystemd-shared.la
4442
4443 noinst_LTLIBRARIES += \
4444 libjournal-core.la
4445
4446 journal-install-hook:
4447 -$(MKDIR_P) $(DESTDIR)/var/log/journal
4448 -chown 0:0 $(DESTDIR)/var/log/journal
4449 -chmod 755 $(DESTDIR)/var/log/journal
4450 -setfacl -nm g:adm:rx,d:g:adm:rx $(DESTDIR)/var/log/journal/
4451 -setfacl -nm g:wheel:rx,d:g:wheel:rx $(DESTDIR)/var/log/journal/
4452
4453 journal-uninstall-hook:
4454 -rmdir $(DESTDIR)/var/log/journal/remote
4455 -rmdir $(DESTDIR)/var/log/journal/
4456
4457 INSTALL_EXEC_HOOKS += journal-install-hook
4458 UNINSTALL_EXEC_HOOKS += journal-uninstall-hook
4459
4460 # ------------------------------------------------------------------------------
4461 # Update catalog on installation. Do not bother if installing
4462 # in DESTDIR, since this is likely for packaging purposes.
4463 catalog-update-hook:
4464 -test -n "$(DESTDIR)" || $(rootbindir)/journalctl --update-catalog
4465
4466 INSTALL_DATA_HOOKS += \
4467 catalog-update-hook
4468
4469 catalog-remove-hook:
4470 -test -n "$(DESTDIR)" || rm -f $(catalogstatedir)/database
4471
4472 UNINSTALL_DATA_HOOKS += \
4473 catalog-remove-hook
4474
4475 tests += \
4476 test-journal \
4477 test-journal-enum \
4478 test-journal-send \
4479 test-journal-syslog \
4480 test-journal-match \
4481 test-journal-stream \
4482 test-journal-init \
4483 test-journal-verify \
4484 test-journal-interleaving \
4485 test-journal-flush \
4486 test-mmap-cache \
4487 test-catalog \
4488 test-audit-type
4489
4490 if HAVE_COMPRESSION
4491 tests += \
4492 test-compress \
4493 test-compress-benchmark
4494 endif
4495
4496 pkginclude_HEADERS += \
4497 src/systemd/sd-journal.h \
4498 src/systemd/sd-messages.h \
4499 src/systemd/_sd-common.h
4500
4501 libsystemd_journal_internal_la_SOURCES = \
4502 src/journal/sd-journal.c \
4503 src/systemd/sd-journal.h \
4504 src/systemd/_sd-common.h \
4505 src/journal/journal-file.c \
4506 src/journal/journal-file.h \
4507 src/journal/journal-vacuum.c \
4508 src/journal/journal-vacuum.h \
4509 src/journal/journal-verify.c \
4510 src/journal/journal-verify.h \
4511 src/journal/lookup3.c \
4512 src/journal/lookup3.h \
4513 src/journal/journal-send.c \
4514 src/journal/journal-def.h \
4515 src/journal/compress.h \
4516 src/journal/catalog.c \
4517 src/journal/catalog.h \
4518 src/journal/mmap-cache.c \
4519 src/journal/mmap-cache.h \
4520 src/journal/compress.c \
4521 src/journal/audit-type.h \
4522 src/journal/audit-type.c \
4523 src/shared/gcrypt-util.h \
4524 src/shared/gcrypt-util.c
4525
4526 nodist_libsystemd_journal_internal_la_SOURCES = \
4527 src/journal/audit_type-to-name.h
4528
4529 gperf_txt_sources += \
4530 src/journal/audit_type-list.txt
4531
4532 # using _CFLAGS = in the conditional below would suppress AM_CFLAGS
4533 libsystemd_journal_internal_la_CFLAGS = \
4534 $(AM_CFLAGS)
4535
4536 libsystemd_journal_internal_la_LIBADD =
4537
4538 if HAVE_XZ
4539 libsystemd_journal_internal_la_CFLAGS += \
4540 $(XZ_CFLAGS)
4541
4542 libsystemd_journal_internal_la_LIBADD += \
4543 $(XZ_LIBS)
4544 endif
4545
4546 if HAVE_LZ4
4547 libsystemd_journal_internal_la_LIBADD += \
4548 -llz4
4549 endif
4550
4551 if HAVE_GCRYPT
4552 libsystemd_journal_internal_la_SOURCES += \
4553 src/journal/journal-authenticate.c \
4554 src/journal/journal-authenticate.h \
4555 src/journal/fsprg.c \
4556 src/journal/fsprg.h
4557
4558 libsystemd_journal_internal_la_LIBADD += \
4559 $(GCRYPT_LIBS)
4560
4561 libsystemd_journal_internal_la_CFLAGS += \
4562 $(GCRYPT_CFLAGS)
4563 endif
4564
4565 noinst_LTLIBRARIES += \
4566 libsystemd-journal-internal.la
4567
4568 rootlibexec_PROGRAMS += \
4569 systemd-journald
4570
4571 rootbin_PROGRAMS += \
4572 journalctl
4573
4574 bin_PROGRAMS += \
4575 systemd-cat
4576
4577 dist_systemunit_DATA += \
4578 units/systemd-journald.socket \
4579 units/systemd-journald-dev-log.socket \
4580 units/systemd-journald-audit.socket
4581
4582 nodist_systemunit_DATA += \
4583 units/systemd-journald.service \
4584 units/systemd-journal-flush.service \
4585 units/systemd-journal-catalog-update.service
4586
4587 dist_pkgsysconf_DATA += \
4588 src/journal/journald.conf
4589
4590 nodist_catalog_DATA = \
4591 catalog/systemd.bg.catalog \
4592 catalog/systemd.be.catalog \
4593 catalog/systemd.be@latin.catalog \
4594 catalog/systemd.fr.catalog \
4595 catalog/systemd.it.catalog \
4596 catalog/systemd.pl.catalog \
4597 catalog/systemd.pt_BR.catalog \
4598 catalog/systemd.ru.catalog \
4599 catalog/systemd.zh_CN.catalog \
4600 catalog/systemd.zh_TW.catalog \
4601 catalog/systemd.catalog
4602
4603 EXTRA_DIST += \
4604 $(nodist_catalog_DATA:.catalog=.catalog.in)
4605
4606 # Note that we don't use @@ for replacement markers here, but %%. This is
4607 # because the catalog uses @@ already for its runtime replacement handling and
4608 # we don't want to conflict with that.
4609 catalog/%.catalog: catalog/%.catalog.in
4610 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
4611 $(SED) -e 's~%SUPPORT_URL%~$(SUPPORT_URL)~' < $< > $@
4612
4613 SOCKETS_TARGET_WANTS += \
4614 systemd-journald.socket \
4615 systemd-journald-dev-log.socket \
4616 systemd-journald-audit.socket
4617
4618 SYSINIT_TARGET_WANTS += \
4619 systemd-journald.service \
4620 systemd-journal-flush.service \
4621 systemd-journal-catalog-update.service
4622
4623 EXTRA_DIST += \
4624 units/systemd-journald.service.in \
4625 units/systemd-journal-flush.service.in \
4626 units/systemd-journal-catalog-update.service.in
4627
4628 gperf_gperf_sources += \
4629 src/journal/journald-gperf.gperf
4630
4631 # ------------------------------------------------------------------------------
4632 if HAVE_MICROHTTPD
4633 gatewayddocumentrootdir=$(pkgdatadir)/gatewayd
4634
4635 rootlibexec_PROGRAMS += \
4636 systemd-journal-gatewayd
4637
4638 systemd_journal_gatewayd_SOURCES = \
4639 src/journal-remote/journal-gatewayd.c \
4640 src/journal-remote/microhttpd-util.h \
4641 src/journal-remote/microhttpd-util.c
4642
4643 systemd_journal_gatewayd_LDADD = \
4644 libsystemd-shared.la \
4645 $(MICROHTTPD_LIBS)
4646
4647 if HAVE_GNUTLS
4648 systemd_journal_gatewayd_LDADD += \
4649 $(GNUTLS_LIBS)
4650 endif
4651
4652 systemd_journal_gatewayd_CFLAGS = \
4653 $(AM_CFLAGS) \
4654 $(MICROHTTPD_CFLAGS)
4655
4656 systemd_journal_gatewayd_CPPFLAGS = \
4657 $(AM_CPPFLAGS) \
4658 -DDOCUMENT_ROOT=\"$(gatewayddocumentrootdir)\"
4659
4660 dist_systemunit_DATA += \
4661 units/systemd-journal-gatewayd.socket
4662
4663 nodist_systemunit_DATA += \
4664 units/systemd-journal-gatewayd.service
4665
4666 dist_gatewayddocumentroot_DATA = \
4667 src/journal-remote/browse.html
4668
4669 endif
4670
4671 EXTRA_DIST += \
4672 units/systemd-journal-gatewayd.service.in
4673
4674 # ------------------------------------------------------------------------------
4675
4676 systemd_socket_proxyd_SOURCES = \
4677 src/socket-proxy/socket-proxyd.c
4678
4679 systemd_socket_proxyd_LDADD = \
4680 libsystemd-shared.la
4681
4682 # ------------------------------------------------------------------------------
4683 if ENABLE_COREDUMP
4684 systemd_coredump_SOURCES = \
4685 src/coredump/coredump.c \
4686 src/coredump/coredump-vacuum.c \
4687 src/coredump/coredump-vacuum.h
4688
4689 systemd_coredump_CFLAGS = \
4690 $(AM_CFLAGS) \
4691 $(ACL_CFLAGS)
4692
4693 systemd_coredump_LDADD = \
4694 libsystemd-shared.la \
4695 $(ACL_LIBS)
4696
4697 if HAVE_ELFUTILS
4698 systemd_coredump_SOURCES += \
4699 src/coredump/stacktrace.c \
4700 src/coredump/stacktrace.h
4701
4702 systemd_coredump_LDADD += \
4703 $(ELFUTILS_LIBS)
4704 endif
4705
4706 nodist_systemunit_DATA += \
4707 units/systemd-coredump@.service
4708
4709 dist_systemunit_DATA += \
4710 units/systemd-coredump.socket
4711
4712 SOCKETS_TARGET_WANTS += \
4713 systemd-coredump.socket
4714
4715 rootlibexec_PROGRAMS += \
4716 systemd-coredump
4717
4718 dist_pkgsysconf_DATA += \
4719 src/coredump/coredump.conf
4720
4721 coredumpctl_SOURCES = \
4722 src/coredump/coredumpctl.c
4723
4724 coredumpctl_LDADD = \
4725 libsystemd-shared.la
4726
4727 bin_PROGRAMS += \
4728 coredumpctl
4729
4730 manual_tests += \
4731 test-coredump-vacuum
4732
4733 test_coredump_vacuum_SOURCES = \
4734 src/coredump/test-coredump-vacuum.c \
4735 src/coredump/coredump-vacuum.c \
4736 src/coredump/coredump-vacuum.h
4737
4738 test_coredump_vacuum_LDADD = \
4739 libsystemd-shared.la
4740
4741 dist_bashcompletion_data += \
4742 shell-completion/bash/coredumpctl
4743
4744 dist_zshcompletion_data += \
4745 shell-completion/zsh/_coredumpctl
4746
4747 nodist_sysctl_DATA = \
4748 sysctl.d/50-coredump.conf
4749
4750 CLEANFILES += \
4751 sysctl.d/50-coredump.conf
4752 endif
4753
4754 EXTRA_DIST += \
4755 sysctl.d/50-coredump.conf.in \
4756 units/systemd-coredump@.service.in
4757
4758 # ------------------------------------------------------------------------------
4759 if ENABLE_BINFMT
4760 systemd_binfmt_SOURCES = \
4761 src/binfmt/binfmt.c
4762
4763 systemd_binfmt_LDADD = \
4764 libsystemd-shared.la
4765
4766 rootlibexec_PROGRAMS += \
4767 systemd-binfmt
4768
4769 dist_systemunit_DATA += \
4770 units/proc-sys-fs-binfmt_misc.automount \
4771 units/proc-sys-fs-binfmt_misc.mount
4772
4773 nodist_systemunit_DATA += \
4774 units/systemd-binfmt.service
4775
4776 INSTALL_DIRS += \
4777 $(prefix)/lib/binfmt.d \
4778 $(sysconfdir)/binfmt.d
4779
4780 SYSINIT_TARGET_WANTS += \
4781 systemd-binfmt.service \
4782 proc-sys-fs-binfmt_misc.automount
4783
4784 endif
4785
4786 EXTRA_DIST += \
4787 units/systemd-binfmt.service.in
4788
4789 # ------------------------------------------------------------------------------
4790 if ENABLE_VCONSOLE
4791 systemd_vconsole_setup_SOURCES = \
4792 src/vconsole/vconsole-setup.c
4793
4794 systemd_vconsole_setup_LDADD = \
4795 libsystemd-shared.la
4796
4797 rootlibexec_PROGRAMS += \
4798 systemd-vconsole-setup
4799
4800 nodist_udevrules_DATA += \
4801 src/vconsole/90-vconsole.rules
4802
4803 nodist_systemunit_DATA += \
4804 units/systemd-vconsole-setup.service
4805 endif
4806
4807 EXTRA_DIST += \
4808 src/vconsole/90-vconsole.rules.in \
4809 units/systemd-vconsole-setup.service.in
4810
4811 # ------------------------------------------------------------------------------
4812 if ENABLE_QUOTACHECK
4813 rootlibexec_PROGRAMS += \
4814 systemd-quotacheck
4815
4816 nodist_systemunit_DATA += \
4817 units/systemd-quotacheck.service
4818
4819 systemd_quotacheck_SOURCES = \
4820 src/quotacheck/quotacheck.c
4821
4822 systemd_quotacheck_LDADD = \
4823 libsystemd-shared.la
4824 endif
4825
4826 EXTRA_DIST += \
4827 units/systemd-quotacheck.service.in
4828
4829 nodist_systemunit_DATA += \
4830 units/quotaon.service
4831
4832 # ------------------------------------------------------------------------------
4833 if ENABLE_RANDOMSEED
4834 rootlibexec_PROGRAMS += \
4835 systemd-random-seed
4836
4837 nodist_systemunit_DATA += \
4838 units/systemd-random-seed.service
4839
4840 systemd_random_seed_SOURCES = \
4841 src/random-seed/random-seed.c
4842
4843 systemd_random_seed_LDADD = \
4844 libsystemd-shared.la
4845
4846 SYSINIT_TARGET_WANTS += \
4847 systemd-random-seed.service
4848
4849 endif
4850
4851 EXTRA_DIST += \
4852 units/systemd-random-seed.service.in
4853
4854 # ------------------------------------------------------------------------------
4855 if ENABLE_BACKLIGHT
4856 rootlibexec_PROGRAMS += \
4857 systemd-backlight
4858
4859 nodist_systemunit_DATA += \
4860 units/systemd-backlight@.service
4861
4862 systemd_backlight_SOURCES = \
4863 src/backlight/backlight.c
4864
4865 systemd_backlight_LDADD = \
4866 libsystemd-shared.la
4867 endif
4868
4869 EXTRA_DIST += \
4870 units/systemd-backlight@.service.in
4871
4872 # ------------------------------------------------------------------------------
4873 if ENABLE_RFKILL
4874 rootlibexec_PROGRAMS += \
4875 systemd-rfkill
4876
4877 nodist_systemunit_DATA += \
4878 units/systemd-rfkill.service
4879
4880 dist_systemunit_DATA += \
4881 units/systemd-rfkill.socket
4882
4883 systemd_rfkill_SOURCES = \
4884 src/rfkill/rfkill.c
4885
4886 systemd_rfkill_LDADD = \
4887 libsystemd-shared.la
4888 endif
4889
4890 EXTRA_DIST += \
4891 units/systemd-rfkill.service.in
4892
4893 # ------------------------------------------------------------------------------
4894 if HAVE_LIBCRYPTSETUP
4895 rootlibexec_PROGRAMS += \
4896 systemd-cryptsetup \
4897 systemd-veritysetup
4898
4899 systemgenerator_PROGRAMS += \
4900 systemd-cryptsetup-generator \
4901 systemd-veritysetup-generator
4902
4903 dist_systemunit_DATA += \
4904 units/cryptsetup.target \
4905 units/cryptsetup-pre.target
4906
4907 systemd_cryptsetup_SOURCES = \
4908 src/cryptsetup/cryptsetup.c
4909
4910 systemd_cryptsetup_CFLAGS = \
4911 $(AM_CFLAGS) \
4912 $(LIBCRYPTSETUP_CFLAGS)
4913
4914 systemd_cryptsetup_LDADD = \
4915 libsystemd-shared.la \
4916 $(LIBCRYPTSETUP_LIBS)
4917
4918 systemd_cryptsetup_generator_SOURCES = \
4919 src/cryptsetup/cryptsetup-generator.c
4920
4921 systemd_cryptsetup_generator_LDADD = \
4922 libsystemd-shared.la
4923
4924 systemd_veritysetup_SOURCES = \
4925 src/veritysetup/veritysetup.c
4926
4927 systemd_veritysetup_CFLAGS = \
4928 $(AM_CFLAGS) \
4929 $(LIBCRYPTSETUP_CFLAGS)
4930
4931 systemd_veritysetup_LDADD = \
4932 libsystemd-shared.la \
4933 $(LIBCRYPTSETUP_LIBS)
4934
4935 systemd_veritysetup_generator_SOURCES = \
4936 src/veritysetup/veritysetup-generator.c
4937
4938 systemd_veritysetup_generator_LDADD = \
4939 libsystemd-shared.la
4940
4941 SYSINIT_TARGET_WANTS += \
4942 cryptsetup.target
4943
4944 endif
4945
4946 # ------------------------------------------------------------------------------
4947 if ENABLE_HOSTNAMED
4948 systemd_hostnamed_SOURCES = \
4949 src/hostname/hostnamed.c
4950
4951 systemd_hostnamed_LDADD = \
4952 libsystemd-shared.la
4953
4954 rootlibexec_PROGRAMS += \
4955 systemd-hostnamed
4956
4957 nodist_systemunit_DATA += \
4958 units/systemd-hostnamed.service
4959
4960 dist_systemunit_DATA_busnames += \
4961 units/org.freedesktop.hostname1.busname
4962
4963 dist_dbuspolicy_DATA += \
4964 src/hostname/org.freedesktop.hostname1.conf
4965
4966 dist_dbussystemservice_DATA += \
4967 src/hostname/org.freedesktop.hostname1.service
4968
4969 polkitpolicy_files += \
4970 src/hostname/org.freedesktop.hostname1.policy
4971
4972 SYSTEM_UNIT_ALIASES += \
4973 systemd-hostnamed.service dbus-org.freedesktop.hostname1.service
4974
4975 BUSNAMES_TARGET_WANTS += \
4976 org.freedesktop.hostname1.busname
4977
4978 hostnamectl_SOURCES = \
4979 src/hostname/hostnamectl.c
4980
4981 hostnamectl_LDADD = \
4982 libsystemd-shared.la
4983
4984 bin_PROGRAMS += \
4985 hostnamectl
4986
4987 dist_bashcompletion_data += \
4988 shell-completion/bash/hostnamectl
4989
4990 dist_zshcompletion_data += \
4991 shell-completion/zsh/_hostnamectl
4992 endif
4993
4994 polkitpolicy_in_files += \
4995 src/hostname/org.freedesktop.hostname1.policy.in
4996
4997 EXTRA_DIST += \
4998 units/systemd-hostnamed.service.in
4999
5000 # ------------------------------------------------------------------------------
5001 dist_systemunit_DATA_busnames += \
5002 units/org.freedesktop.systemd1.busname
5003
5004 BUSNAMES_TARGET_WANTS += \
5005 org.freedesktop.systemd1.busname
5006
5007 # ------------------------------------------------------------------------------
5008 if ENABLE_LOCALED
5009 systemd_localed_SOURCES = \
5010 src/locale/localed.c \
5011 src/locale/keymap-util.c \
5012 src/locale/keymap-util.h
5013
5014 systemd_localed_LDADD = \
5015 libsystemd-shared.la \
5016 -ldl
5017
5018 nodist_systemunit_DATA += \
5019 units/systemd-localed.service
5020
5021 dist_systemunit_DATA_busnames += \
5022 units/org.freedesktop.locale1.busname
5023
5024 rootlibexec_PROGRAMS += \
5025 systemd-localed
5026
5027 dist_dbuspolicy_DATA += \
5028 src/locale/org.freedesktop.locale1.conf
5029
5030 dist_dbussystemservice_DATA += \
5031 src/locale/org.freedesktop.locale1.service
5032
5033 polkitpolicy_files += \
5034 src/locale/org.freedesktop.locale1.policy
5035
5036 SYSTEM_UNIT_ALIASES += \
5037 systemd-localed.service dbus-org.freedesktop.locale1.service
5038
5039 BUSNAMES_TARGET_WANTS += \
5040 org.freedesktop.locale1.busname
5041
5042 dist_pkgdata_DATA = \
5043 src/locale/kbd-model-map \
5044 src/locale/language-fallback-map
5045
5046 test_keymap_util_SOURCES = \
5047 src/locale/test-keymap-util.c \
5048 src/locale/keymap-util.c \
5049 src/locale/keymap-util.h
5050
5051 test_keymap_util_LDADD = \
5052 libsystemd-shared.la \
5053 -ldl
5054
5055 tests += \
5056 test-keymap-util
5057
5058 localectl_SOURCES = \
5059 src/locale/localectl.c
5060
5061 localectl_LDADD = \
5062 libsystemd-shared.la
5063
5064 bin_PROGRAMS += \
5065 localectl
5066
5067 dist_bashcompletion_data += \
5068 shell-completion/bash/localectl
5069
5070 dist_zshcompletion_data += \
5071 shell-completion/zsh/_localectl
5072 endif
5073
5074 polkitpolicy_in_files += \
5075 src/locale/org.freedesktop.locale1.policy.in
5076
5077 EXTRA_DIST += \
5078 units/systemd-localed.service.in
5079
5080 # ------------------------------------------------------------------------------
5081 if ENABLE_TIMEDATED
5082 systemd_timedated_SOURCES = \
5083 src/timedate/timedated.c
5084
5085 systemd_timedated_LDADD = \
5086 libsystemd-shared.la
5087
5088 rootlibexec_PROGRAMS += \
5089 systemd-timedated
5090
5091 dist_dbussystemservice_DATA += \
5092 src/timedate/org.freedesktop.timedate1.service
5093
5094 dist_dbuspolicy_DATA += \
5095 src/timedate/org.freedesktop.timedate1.conf
5096
5097 nodist_systemunit_DATA += \
5098 units/systemd-timedated.service
5099
5100 dist_systemunit_DATA_busnames += \
5101 units/org.freedesktop.timedate1.busname
5102
5103 polkitpolicy_files += \
5104 src/timedate/org.freedesktop.timedate1.policy
5105
5106 SYSTEM_UNIT_ALIASES += \
5107 systemd-timedated.service dbus-org.freedesktop.timedate1.service
5108
5109 BUSNAMES_TARGET_WANTS += \
5110 org.freedesktop.timedate1.busname
5111
5112 timedatectl_SOURCES = \
5113 src/timedate/timedatectl.c
5114
5115 timedatectl_LDADD = \
5116 libsystemd-shared.la
5117
5118 bin_PROGRAMS += \
5119 timedatectl
5120
5121 dist_bashcompletion_data += \
5122 shell-completion/bash/timedatectl
5123
5124 dist_zshcompletion_data += \
5125 shell-completion/zsh/_timedatectl
5126 endif
5127
5128 polkitpolicy_in_files += \
5129 src/timedate/org.freedesktop.timedate1.policy.in
5130
5131 EXTRA_DIST += \
5132 units/systemd-timedated.service.in
5133
5134 # ------------------------------------------------------------------------------
5135 if ENABLE_TIMESYNCD
5136 systemd_timesyncd_SOURCES = \
5137 src/timesync/timesyncd.c \
5138 src/timesync/timesyncd-manager.c \
5139 src/timesync/timesyncd-manager.h \
5140 src/timesync/timesyncd-conf.c \
5141 src/timesync/timesyncd-conf.h \
5142 src/timesync/timesyncd-server.c \
5143 src/timesync/timesyncd-server.h
5144
5145 nodist_systemd_timesyncd_SOURCES = \
5146 src/timesync/timesyncd-gperf.c
5147
5148 systemd_timesyncd_LDADD = \
5149 libsystemd-network.la \
5150 libsystemd-shared.la \
5151 -lm
5152
5153 rootlibexec_PROGRAMS += \
5154 systemd-timesyncd
5155
5156 nodist_systemunit_DATA += \
5157 units/systemd-timesyncd.service
5158
5159 GENERAL_ALIASES += \
5160 $(systemunitdir)/systemd-timesyncd.service $(pkgsysconfdir)/system/sysinit.target.wants/systemd-timesyncd.service
5161
5162 nodist_pkgsysconf_DATA += \
5163 src/timesync/timesyncd.conf
5164
5165 endif
5166
5167 gperf_gperf_sources += \
5168 src/timesync/timesyncd-gperf.gperf
5169
5170 EXTRA_DIST += \
5171 units/systemd-timesyncd.service.in \
5172 src/timesync/timesyncd.conf.in
5173
5174 # ------------------------------------------------------------------------------
5175 test_nss_SOURCES = \
5176 src/test/test-nss.c
5177
5178 test_nss_LDADD = \
5179 libsystemd-internal.la \
5180 libbasic.la \
5181 -ldl
5182
5183 manual_tests += \
5184 test-nss
5185
5186 # ------------------------------------------------------------------------------
5187 libnss_systemd_la_SOURCES = \
5188 src/nss-systemd/nss-systemd.sym \
5189 src/nss-systemd/nss-systemd.c
5190
5191 libnss_systemd_la_LDFLAGS = \
5192 $(AM_LDFLAGS) \
5193 -module \
5194 -export-dynamic \
5195 -avoid-version \
5196 -shared \
5197 -shrext .so.2 \
5198 -Wl,--version-script=$(top_srcdir)/src/nss-systemd/nss-systemd.sym
5199
5200 libnss_systemd_la_LIBADD = \
5201 libsystemd-internal.la \
5202 libbasic.la
5203
5204 rootlib_LTLIBRARIES += \
5205 libnss_systemd.la
5206
5207 # ------------------------------------------------------------------------------
5208 if HAVE_MYHOSTNAME
5209 libnss_myhostname_la_SOURCES = \
5210 src/nss-myhostname/nss-myhostname.sym \
5211 src/nss-myhostname/nss-myhostname.c
5212
5213 libnss_myhostname_la_LDFLAGS = \
5214 $(AM_LDFLAGS) \
5215 -module \
5216 -export-dynamic \
5217 -avoid-version \
5218 -shared \
5219 -shrext .so.2 \
5220 -Wl,--version-script=$(top_srcdir)/src/nss-myhostname/nss-myhostname.sym
5221
5222 libnss_myhostname_la_LIBADD = \
5223 libsystemd-internal.la \
5224 libbasic.la
5225
5226 rootlib_LTLIBRARIES += \
5227 libnss_myhostname.la
5228 endif
5229
5230 # ------------------------------------------------------------------------------
5231 if ENABLE_MACHINED
5232 systemd_machined_SOURCES = \
5233 src/machine/machined.c \
5234 src/machine/machined.h
5235
5236 systemd_machined_LDADD = \
5237 libmachine-core.la
5238
5239 rootlibexec_PROGRAMS += \
5240 systemd-machined
5241
5242 libmachine_core_la_SOURCES = \
5243 src/machine/machine.c \
5244 src/machine/machine.h \
5245 src/machine/machined-dbus.c \
5246 src/machine/machine-dbus.c \
5247 src/machine/machine-dbus.h \
5248 src/machine/image-dbus.c \
5249 src/machine/image-dbus.h \
5250 src/machine/operation.c \
5251 src/machine/operation.h
5252
5253 libmachine_core_la_LIBADD = \
5254 libsystemd-shared.la
5255
5256 noinst_LTLIBRARIES += \
5257 libmachine-core.la
5258
5259 machinectl_SOURCES = \
5260 src/machine/machinectl.c
5261
5262 machinectl_LDADD = \
5263 libsystemd-shared.la
5264
5265 rootbin_PROGRAMS += \
5266 machinectl
5267
5268 test_machine_tables_SOURCES = \
5269 src/machine/test-machine-tables.c
5270
5271 test_machine_tables_LDADD = \
5272 libmachine-core.la
5273
5274 tests += \
5275 test-machine-tables
5276
5277 nodist_systemunit_DATA += \
5278 units/systemd-machined.service
5279
5280 dist_systemunit_DATA += \
5281 units/machine.slice
5282
5283 dist_systemunit_DATA_busnames += \
5284 units/org.freedesktop.machine1.busname
5285
5286 dist_dbussystemservice_DATA += \
5287 src/machine/org.freedesktop.machine1.service
5288
5289 dist_dbuspolicy_DATA += \
5290 src/machine/org.freedesktop.machine1.conf
5291
5292 polkitpolicy_files += \
5293 src/machine/org.freedesktop.machine1.policy
5294
5295 dist_bashcompletion_data += \
5296 shell-completion/bash/machinectl
5297
5298 dist_zshcompletion_data += \
5299 shell-completion/zsh/_machinectl \
5300 shell-completion/zsh/_sd_machines
5301
5302 SYSTEM_UNIT_ALIASES += \
5303 systemd-machined.service dbus-org.freedesktop.machine1.service
5304
5305 BUSNAMES_TARGET_WANTS += \
5306 org.freedesktop.machine1.busname
5307
5308 libnss_mymachines_la_SOURCES = \
5309 src/nss-mymachines/nss-mymachines.sym \
5310 src/nss-mymachines/nss-mymachines.c
5311
5312 libnss_mymachines_la_LDFLAGS = \
5313 $(AM_LDFLAGS) \
5314 -module \
5315 -export-dynamic \
5316 -avoid-version \
5317 -shared \
5318 -shrext .so.2 \
5319 -Wl,--version-script=$(top_srcdir)/src/nss-mymachines/nss-mymachines.sym
5320
5321 libnss_mymachines_la_LIBADD = \
5322 libsystemd-internal.la \
5323 libbasic.la
5324
5325 rootlib_LTLIBRARIES += \
5326 libnss_mymachines.la
5327
5328 endif
5329
5330 polkitpolicy_in_files += \
5331 src/machine/org.freedesktop.machine1.policy.in
5332
5333 EXTRA_DIST += \
5334 units/systemd-machined.service.in
5335
5336 # ------------------------------------------------------------------------------
5337 if ENABLE_IMPORTD
5338
5339 if HAVE_LIBCURL
5340 if HAVE_XZ
5341 if HAVE_ZLIB
5342 if HAVE_BZIP2
5343 if HAVE_GCRYPT
5344
5345 rootlibexec_PROGRAMS += \
5346 systemd-importd \
5347 systemd-pull \
5348 systemd-import \
5349 systemd-export
5350
5351 systemd_importd_SOURCES = \
5352 src/import/importd.c
5353
5354 systemd_importd_CFLAGS = \
5355 $(AM_CFLAGS) \
5356 -D SYSTEMD_PULL_PATH=\"$(rootlibexecdir)/systemd-pull\" \
5357 -D SYSTEMD_IMPORT_PATH=\"$(rootlibexecdir)/systemd-import\" \
5358 -D SYSTEMD_EXPORT_PATH=\"$(rootlibexecdir)/systemd-export\"
5359
5360 systemd_importd_LDADD = \
5361 libsystemd-shared.la
5362
5363 systemd_pull_SOURCES = \
5364 src/import/pull.c \
5365 src/import/pull-raw.c \
5366 src/import/pull-raw.h \
5367 src/import/pull-tar.c \
5368 src/import/pull-tar.h \
5369 src/import/pull-job.c \
5370 src/import/pull-job.h \
5371 src/import/pull-common.c \
5372 src/import/pull-common.h \
5373 src/import/import-common.c \
5374 src/import/import-common.h \
5375 src/import/import-compress.c \
5376 src/import/import-compress.h \
5377 src/import/curl-util.c \
5378 src/import/curl-util.h \
5379 src/import/qcow2-util.c \
5380 src/import/qcow2-util.h
5381
5382 systemd_pull_CFLAGS = \
5383 $(AM_CFLAGS) \
5384 $(LIBCURL_CFLAGS) \
5385 $(XZ_CFLAGS) \
5386 $(ZLIB_CFLAGS) \
5387 $(GCRYPT_CFLAGS) \
5388 -D VENDOR_KEYRING_PATH=\"$(rootlibexecdir)/import-pubring.gpg\" \
5389 -D USER_KEYRING_PATH=\"$(pkgsysconfdir)/import-pubring.gpg\"
5390
5391 systemd_pull_LDADD = \
5392 libsystemd-shared.la \
5393 $(LIBCURL_LIBS) \
5394 $(XZ_LIBS) \
5395 $(ZLIB_LIBS) \
5396 -lbz2 \
5397 $(GCRYPT_LIBS)
5398
5399 systemd_import_SOURCES = \
5400 src/import/import.c \
5401 src/import/import-raw.c \
5402 src/import/import-raw.h \
5403 src/import/import-tar.c \
5404 src/import/import-tar.h \
5405 src/import/import-common.c \
5406 src/import/import-common.h \
5407 src/import/import-compress.c \
5408 src/import/import-compress.h \
5409 src/import/qcow2-util.c \
5410 src/import/qcow2-util.h
5411
5412 systemd_import_CFLAGS = \
5413 $(AM_CFLAGS) \
5414 $(XZ_CFLAGS) \
5415 $(ZLIB_CFLAGS)
5416
5417 systemd_import_LDADD = \
5418 libsystemd-shared.la \
5419 $(XZ_LIBS) \
5420 $(ZLIB_LIBS) \
5421 -lbz2
5422
5423 systemd_export_SOURCES = \
5424 src/import/export.c \
5425 src/import/export-tar.c \
5426 src/import/export-tar.h \
5427 src/import/export-raw.c \
5428 src/import/export-raw.h \
5429 src/import/import-common.c \
5430 src/import/import-common.h \
5431 src/import/import-compress.c \
5432 src/import/import-compress.h
5433
5434 systemd_export_CFLAGS = \
5435 $(AM_CFLAGS) \
5436 $(XZ_CFLAGS) \
5437 $(ZLIB_CFLAGS)
5438
5439 systemd_export_LDADD = \
5440 libsystemd-shared.la \
5441 $(XZ_LIBS) \
5442 $(ZLIB_LIBS) \
5443 -lbz2
5444
5445 dist_rootlibexec_DATA += \
5446 src/import/import-pubring.gpg
5447
5448 nodist_systemunit_DATA += \
5449 units/systemd-importd.service
5450
5451 dist_systemunit_DATA_busnames += \
5452 units/org.freedesktop.import1.busname
5453
5454 BUSNAMES_TARGET_WANTS += \
5455 org.freedesktop.import1.busname
5456
5457 SYSTEM_UNIT_ALIASES += \
5458 systemd-importd.service dbus-org.freedesktop.import1.service
5459
5460 dist_dbussystemservice_DATA += \
5461 src/import/org.freedesktop.import1.service
5462
5463 dist_dbuspolicy_DATA += \
5464 src/import/org.freedesktop.import1.conf
5465
5466 polkitpolicy_files += \
5467 src/import/org.freedesktop.import1.policy
5468
5469 manual_tests += \
5470 test-qcow2
5471
5472 test_qcow2_SOURCES = \
5473 src/import/test-qcow2.c \
5474 src/import/qcow2-util.c \
5475 src/import/qcow2-util.h
5476
5477 test_qcow2_CFLAGS = \
5478 $(AM_CFLAGS) \
5479 $(ZLIB_CFLAGS)
5480
5481 test_qcow2_LDADD = \
5482 libsystemd-shared.la \
5483 $(ZLIB_LIBS)
5484
5485 endif
5486 endif
5487 endif
5488 endif
5489 endif
5490
5491 endif
5492
5493 polkitpolicy_in_files += \
5494 src/import/org.freedesktop.import1.policy.in
5495
5496 EXTRA_DIST += \
5497 units/systemd-importd.service.in
5498
5499
5500 # ------------------------------------------------------------------------------
5501 if ENABLE_RESOLVED
5502
5503 basic_dns_sources = \
5504 src/resolve/resolved-dns-dnssec.c \
5505 src/resolve/resolved-dns-dnssec.h \
5506 src/resolve/resolved-dns-packet.c \
5507 src/resolve/resolved-dns-packet.h \
5508 src/resolve/resolved-dns-rr.c \
5509 src/resolve/resolved-dns-rr.h \
5510 src/resolve/resolved-dns-answer.c \
5511 src/resolve/resolved-dns-answer.h \
5512 src/resolve/resolved-dns-question.c \
5513 src/resolve/resolved-dns-question.h \
5514 src/resolve/dns-type.c \
5515 src/resolve/dns-type.h
5516
5517 systemd_resolved_SOURCES = \
5518 src/resolve/resolved.c \
5519 src/resolve/resolved-manager.c \
5520 src/resolve/resolved-manager.h \
5521 src/resolve/resolved-conf.c \
5522 src/resolve/resolved-conf.h \
5523 src/resolve/resolved-resolv-conf.c \
5524 src/resolve/resolved-resolv-conf.h \
5525 src/resolve/resolved-bus.c \
5526 src/resolve/resolved-bus.h \
5527 src/resolve/resolved-link.h \
5528 src/resolve/resolved-link.c \
5529 src/resolve/resolved-link-bus.c \
5530 src/resolve/resolved-link-bus.h \
5531 src/resolve/resolved-llmnr.h \
5532 src/resolve/resolved-llmnr.c \
5533 src/resolve/resolved-mdns.h \
5534 src/resolve/resolved-mdns.c \
5535 src/resolve/resolved-def.h \
5536 $(basic_dns_sources) \
5537 src/resolve/resolved-dns-query.h \
5538 src/resolve/resolved-dns-query.c \
5539 src/resolve/resolved-dns-synthesize.h \
5540 src/resolve/resolved-dns-synthesize.c \
5541 src/resolve/resolved-dns-transaction.h \
5542 src/resolve/resolved-dns-transaction.c \
5543 src/resolve/resolved-dns-scope.h \
5544 src/resolve/resolved-dns-scope.c \
5545 src/resolve/resolved-dns-server.h \
5546 src/resolve/resolved-dns-server.c \
5547 src/resolve/resolved-dns-search-domain.h \
5548 src/resolve/resolved-dns-search-domain.c \
5549 src/resolve/resolved-dns-cache.h \
5550 src/resolve/resolved-dns-cache.c \
5551 src/resolve/resolved-dns-zone.h \
5552 src/resolve/resolved-dns-zone.c \
5553 src/resolve/resolved-dns-stream.h \
5554 src/resolve/resolved-dns-stream.c \
5555 src/resolve/resolved-dns-trust-anchor.h \
5556 src/resolve/resolved-dns-trust-anchor.c \
5557 src/resolve/resolved-dns-stub.h \
5558 src/resolve/resolved-dns-stub.c \
5559 src/resolve/resolved-etc-hosts.h \
5560 src/resolve/resolved-etc-hosts.c \
5561 src/shared/gcrypt-util.c \
5562 src/shared/gcrypt-util.h
5563
5564 nodist_systemd_resolved_SOURCES = \
5565 src/resolve/dns_type-from-name.h \
5566 src/resolve/dns_type-to-name.h \
5567 src/resolve/resolved-gperf.c
5568
5569 systemd_resolved_CFLAGS = \
5570 $(AM_CFLAGS) \
5571 $(GCRYPT_CFLAGS)
5572
5573 systemd_resolved_LDADD = \
5574 libsystemd-network.la \
5575 libsystemd-shared.la \
5576 $(GCRYPT_LIBS) \
5577 -lm
5578
5579 rootlibexec_PROGRAMS += \
5580 systemd-resolved
5581
5582 nodist_systemunit_DATA += \
5583 units/systemd-resolved.service
5584
5585 dist_systemunit_DATA_busnames += \
5586 units/org.freedesktop.resolve1.busname
5587
5588 dist_dbuspolicy_DATA += \
5589 src/resolve/org.freedesktop.resolve1.conf
5590
5591 dist_dbussystemservice_DATA += \
5592 src/resolve/org.freedesktop.resolve1.service
5593
5594 BUSNAMES_TARGET_WANTS += \
5595 org.freedesktop.resolve1.busname
5596
5597 GENERAL_ALIASES += \
5598 $(systemunitdir)/systemd-resolved.service $(pkgsysconfdir)/system/multi-user.target.wants/systemd-resolved.service \
5599 $(systemunitdir)/systemd-resolved.service $(pkgsysconfdir)/system/dbus-org.freedesktop.resolve1.service
5600
5601 nodist_pkgsysconf_DATA += \
5602 src/resolve/resolved.conf
5603
5604 dist_rootlibexec_DATA += \
5605 src/resolve/resolv.conf
5606
5607 libnss_resolve_la_SOURCES = \
5608 src/nss-resolve/nss-resolve.sym \
5609 src/nss-resolve/nss-resolve.c
5610
5611 libnss_resolve_la_LDFLAGS = \
5612 $(AM_LDFLAGS) \
5613 -module \
5614 -export-dynamic \
5615 -avoid-version \
5616 -shared \
5617 -shrext .so.2 \
5618 -Wl,--version-script=$(top_srcdir)/src/nss-resolve/nss-resolve.sym
5619
5620 libnss_resolve_la_LIBADD = \
5621 libsystemd-internal.la \
5622 libbasic.la \
5623 -ldl
5624
5625 rootlib_LTLIBRARIES += \
5626 libnss_resolve.la
5627
5628 systemd_resolve_SOURCES = \
5629 src/resolve/resolve-tool.c \
5630 $(basic_dns_sources) \
5631 src/shared/gcrypt-util.c \
5632 src/shared/gcrypt-util.h
5633
5634 nodist_systemd_resolve_SOURCES = \
5635 src/resolve/dns_type-from-name.h \
5636 src/resolve/dns_type-to-name.h
5637
5638 systemd_resolve_CFLAGS = \
5639 $(AM_CFLAGS) \
5640 $(GCRYPT_CFLAGS)
5641
5642 systemd_resolve_LDADD = \
5643 libsystemd-shared.la \
5644 $(GCRYPT_LIBS) \
5645 -lm
5646
5647 bin_PROGRAMS += \
5648 systemd-resolve
5649
5650 dist_bashcompletion_data += \
5651 shell-completion/bash/systemd-resolve
5652
5653 dist_zshcompletion_data += \
5654 shell-completion/zsh/_systemd-resolve
5655
5656 tests += \
5657 test-dns-packet \
5658 test-resolve-tables \
5659 test-dnssec
5660
5661 manual_tests += \
5662 test-dnssec-complex
5663
5664 test_resolve_tables_SOURCES = \
5665 src/resolve/test-resolve-tables.c \
5666 src/resolve/dns_type-from-name.h \
5667 src/resolve/dns_type-to-name.h \
5668 $(basic_dns_sources) \
5669 src/shared/test-tables.h
5670
5671 test_resolve_tables_CFLAGS = \
5672 $(AM_CFLAGS) \
5673 $(GCRYPT_CFLAGS)
5674
5675 test_resolve_tables_LDADD = \
5676 libsystemd-shared.la \
5677 $(GCRYPT_LIBS) \
5678 -lm
5679
5680 test_dns_packet_SOURCES = \
5681 src/resolve/test-dns-packet.c \
5682 $(basic_dns_sources)
5683
5684 test_dns_packet_CPPFLAGS = \
5685 $(AM_CPPFLAGS) \
5686 -I $(top_srcdir)/src/test
5687
5688 test_dns_packet_CFLAGS = \
5689 $(AM_CFLAGS) \
5690 $(GCRYPT_CFLAGS)
5691
5692 test_dns_packet_LDADD = \
5693 libsystemd-shared.la \
5694 $(GCRYPT_LIBS) \
5695 -lm
5696
5697 TEST_DATA_FILES += \
5698 test/test-resolve/_openpgpkey.fedoraproject.org.pkts \
5699 test/test-resolve/fedoraproject.org.pkts \
5700 test/test-resolve/gandi.net.pkts \
5701 test/test-resolve/google.com.pkts \
5702 test/test-resolve/root.pkts \
5703 test/test-resolve/sw1a1aa-sw1a2aa-sw1a2ab-sw1a2ac.find.me.uk.pkts \
5704 test/test-resolve/teamits.com.pkts \
5705 test/test-resolve/zbyszek@fedoraproject.org.pkts \
5706 test/test-resolve/_443._tcp.fedoraproject.org.pkts \
5707 test/test-resolve/kyhwana.org.pkts \
5708 test/test-resolve/fake-caa.pkts
5709
5710 EXTRA_DIST += $(TEST_DATA_FILES)
5711
5712 test_dnssec_SOURCES = \
5713 src/resolve/test-dnssec.c \
5714 $(basic_dns_sources)
5715
5716 test_dnssec_CFLAGS = \
5717 $(AM_CFLAGS) \
5718 $(GCRYPT_CFLAGS)
5719
5720 test_dnssec_LDADD = \
5721 libsystemd-shared.la \
5722 $(GCRYPT_LIBS) \
5723 -lm
5724
5725 test_dnssec_complex_SOURCES = \
5726 src/resolve/test-dnssec-complex.c \
5727 src/resolve/dns-type.c \
5728 src/resolve/dns-type.h
5729
5730 test_dnssec_complex_LDADD = \
5731 libsystemd-shared.la
5732
5733 endif
5734
5735 gperf_txt_sources += \
5736 src/resolve/dns_type-list.txt
5737
5738 gperf_gperf_sources += \
5739 src/resolve/resolved-gperf.gperf
5740
5741 EXTRA_DIST += \
5742 units/systemd-resolved.service.m4.in \
5743 src/resolve/resolved.conf.in
5744
5745 # ------------------------------------------------------------------------------
5746 if ENABLE_NETWORKD
5747 rootlibexec_PROGRAMS += \
5748 systemd-networkd
5749
5750 systemd_networkd_SOURCES = \
5751 src/network/networkd.c
5752
5753 systemd_networkd_LDADD = \
5754 libnetworkd-core.la
5755
5756 if HAVE_LIBIPTC
5757 systemd_networkd_LDADD += \
5758 libfirewall.la
5759 endif
5760
5761 noinst_LTLIBRARIES += \
5762 libnetworkd-core.la
5763
5764 libnetworkd_core_la_CFLAGS = \
5765 $(AM_CFLAGS)
5766
5767 libnetworkd_core_la_SOURCES = \
5768 src/libsystemd-network/network-internal.h \
5769 src/network/netdev/netdev.h \
5770 src/network/netdev/netdev.c \
5771 src/network/netdev/vrf.h \
5772 src/network/netdev/vrf.c \
5773 src/network/netdev/tunnel.h \
5774 src/network/netdev/tunnel.c \
5775 src/network/netdev/veth.h \
5776 src/network/netdev/veth.c \
5777 src/network/netdev/vxlan.h \
5778 src/network/netdev/vxlan.c \
5779 src/network/netdev/geneve.h \
5780 src/network/netdev/geneve.c \
5781 src/network/netdev/vlan.h \
5782 src/network/netdev/vlan.c \
5783 src/network/netdev/macvlan.h \
5784 src/network/netdev/macvlan.c \
5785 src/network/netdev/ipvlan.h \
5786 src/network/netdev/ipvlan.c \
5787 src/network/netdev/dummy.h \
5788 src/network/netdev/dummy.c \
5789 src/network/netdev/tuntap.h \
5790 src/network/netdev/tuntap.c \
5791 src/network/netdev/bond.h \
5792 src/network/netdev/bond.c \
5793 src/network/netdev/bridge.h \
5794 src/network/netdev/bridge.c \
5795 src/network/netdev/vcan.h \
5796 src/network/netdev/vcan.c \
5797 src/network/networkd-manager.h \
5798 src/network/networkd-manager.c \
5799 src/network/networkd-manager-bus.c \
5800 src/network/networkd-conf.h \
5801 src/network/networkd-conf.c \
5802 src/network/networkd-link.h \
5803 src/network/networkd-link.c \
5804 src/network/networkd-link-bus.c \
5805 src/network/networkd-ipv4ll.c \
5806 src/network/networkd-ipv6-proxy-ndp.h \
5807 src/network/networkd-ipv6-proxy-ndp.c \
5808 src/network/networkd-dhcp4.c \
5809 src/network/networkd-dhcp6.c \
5810 src/network/networkd-ndisc.h \
5811 src/network/networkd-ndisc.c \
5812 src/network/networkd-network.h \
5813 src/network/networkd-network.c \
5814 src/network/networkd-network-bus.c \
5815 src/network/networkd-address.h \
5816 src/network/networkd-address.c \
5817 src/network/networkd-address-label.h \
5818 src/network/networkd-address-label.c \
5819 src/network/networkd-route.h \
5820 src/network/networkd-route.c \
5821 src/network/networkd-fdb.h \
5822 src/network/networkd-fdb.c \
5823 src/network/networkd-brvlan.h \
5824 src/network/networkd-brvlan.c \
5825 src/network/networkd-address-pool.h \
5826 src/network/networkd-address-pool.c \
5827 src/network/networkd-util.h \
5828 src/network/networkd-util.c \
5829 src/network/networkd-lldp-tx.h \
5830 src/network/networkd-lldp-tx.c
5831
5832 nodist_libnetworkd_core_la_SOURCES = \
5833 src/network/networkd-gperf.c \
5834 src/network/networkd-network-gperf.c \
5835 src/network/netdev/netdev-gperf.c
5836
5837 libnetworkd_core_la_LIBADD = \
5838 libsystemd-network.la \
5839 libsystemd-shared.la
5840
5841 rootlibexec_PROGRAMS += \
5842 systemd-networkd-wait-online
5843
5844 systemd_networkd_wait_online_CFLAGS = \
5845 $(AM_CFLAGS)
5846
5847 systemd_networkd_wait_online_SOURCES = \
5848 src/libsystemd-network/network-internal.h \
5849 src/network/wait-online/link.h \
5850 src/network/wait-online/link.c \
5851 src/network/wait-online/manager.h \
5852 src/network/wait-online/manager.c \
5853 src/network/wait-online/wait-online.c
5854
5855 systemd_networkd_wait_online_LDADD = \
5856 libsystemd-network.la \
5857 libsystemd-shared.la
5858
5859 rootbin_PROGRAMS += \
5860 networkctl
5861
5862 networkctl_SOURCES = \
5863 src/network/networkctl.c
5864
5865 networkctl_LDADD = \
5866 libsystemd-shared.la \
5867 libsystemd-network.la
5868
5869 dist_bashcompletion_data += \
5870 shell-completion/bash/networkctl
5871
5872 dist_zshcompletion_data += \
5873 shell-completion/zsh/_networkctl
5874
5875 test_networkd_conf_SOURCES = \
5876 src/network/test-networkd-conf.c
5877
5878 test_networkd_conf_LDADD = \
5879 libnetworkd-core.la
5880
5881 test_network_SOURCES = \
5882 src/network/test-network.c
5883
5884 test_network_LDADD = \
5885 libnetworkd-core.la
5886
5887 if HAVE_LIBIPTC
5888 test_network_LDADD += \
5889 libfirewall.la
5890 endif
5891
5892 test_network_tables_SOURCES = \
5893 src/network/test-network-tables.c \
5894 src/shared/test-tables.h
5895
5896 test_network_tables_LDADD = \
5897 libnetworkd-core.la \
5898 libudev-core.la
5899
5900 if HAVE_LIBIPTC
5901 test_network_tables_LDADD += \
5902 libfirewall.la
5903 endif
5904
5905 tests += \
5906 test-networkd-conf \
5907 test-network \
5908 test-network-tables
5909
5910 dist_systemunit_DATA += \
5911 units/systemd-networkd.socket
5912
5913 nodist_systemunit_DATA += \
5914 units/systemd-networkd.service \
5915 units/systemd-networkd-wait-online.service
5916
5917 dist_systemunit_DATA_busnames += \
5918 units/org.freedesktop.network1.busname
5919
5920 dist_dbussystemservice_DATA += \
5921 src/network/org.freedesktop.network1.service
5922
5923 dist_dbuspolicy_DATA += \
5924 src/network/org.freedesktop.network1.conf
5925
5926 GENERAL_ALIASES += \
5927 $(systemunitdir)/systemd-networkd.socket $(pkgsysconfdir)/system/sockets.target.wants/systemd-networkd.socket \
5928 $(systemunitdir)/systemd-networkd.service $(pkgsysconfdir)/system/multi-user.target.wants/systemd-networkd.service \
5929 $(systemunitdir)/systemd-networkd-wait-online.service $(pkgsysconfdir)/system/network-online.target.wants/systemd-networkd-wait-online.service \
5930 $(systemunitdir)/systemd-networkd.service $(pkgsysconfdir)/system/dbus-org.freedesktop.network1.service
5931
5932 BUSNAMES_TARGET_WANTS += \
5933 org.freedesktop.network1.busname
5934
5935 polkitrules_files += \
5936 src/network/systemd-networkd.rules
5937
5938 polkitpkla_files += \
5939 src/network/systemd-networkd.pkla
5940
5941 endif
5942
5943 gperf_gperf_sources += \
5944 src/network/networkd-gperf.gperf \
5945 src/network/networkd-network-gperf.gperf \
5946 src/network/netdev/netdev-gperf.gperf
5947
5948 EXTRA_DIST += \
5949 src/network/systemd-networkd.rules \
5950 src/network/systemd-networkd.pkla \
5951 units/systemd-networkd.service.m4.in \
5952 units/systemd-networkd-wait-online.service.in \
5953 test/networkd-test.py \
5954 test/test-exec-deserialization.py
5955
5956 # ------------------------------------------------------------------------------
5957 if ENABLE_LOGIND
5958 systemd_logind_SOURCES = \
5959 src/login/logind.c \
5960 src/login/logind.h
5961
5962 nodist_systemd_logind_SOURCES = \
5963 src/login/logind-gperf.c
5964
5965 systemd_logind_LDADD = \
5966 liblogind-core.la
5967
5968 liblogind_core_la_SOURCES = \
5969 src/login/logind-core.c \
5970 src/login/logind-device.c \
5971 src/login/logind-device.h \
5972 src/login/logind-button.c \
5973 src/login/logind-button.h \
5974 src/login/logind-action.c \
5975 src/login/logind-action.h \
5976 src/login/logind-seat.c \
5977 src/login/logind-seat.h \
5978 src/login/logind-session.c \
5979 src/login/logind-session.h \
5980 src/login/logind-session-device.c \
5981 src/login/logind-session-device.h \
5982 src/login/logind-user.c \
5983 src/login/logind-user.h \
5984 src/login/logind-inhibit.c \
5985 src/login/logind-inhibit.h \
5986 src/login/logind-dbus.c \
5987 src/login/logind-session-dbus.c \
5988 src/login/logind-seat-dbus.c \
5989 src/login/logind-user-dbus.c \
5990 src/login/logind-utmp.c \
5991 src/login/logind-acl.h
5992
5993 liblogind_core_la_LIBADD = \
5994 libsystemd-shared.la
5995
5996 if HAVE_ACL
5997 liblogind_core_la_SOURCES += \
5998 src/login/logind-acl.c
5999 endif
6000
6001 noinst_LTLIBRARIES += \
6002 liblogind-core.la
6003
6004 rootlibexec_PROGRAMS += \
6005 systemd-logind
6006
6007 loginctl_SOURCES = \
6008 src/login/loginctl.c \
6009 src/login/sysfs-show.h \
6010 src/login/sysfs-show.c
6011
6012 loginctl_LDADD = \
6013 libsystemd-shared.la
6014
6015 rootbin_PROGRAMS += \
6016 loginctl
6017
6018 dist_bashcompletion_data += \
6019 shell-completion/bash/loginctl
6020
6021 dist_zshcompletion_data += \
6022 shell-completion/zsh/_loginctl \
6023 shell-completion/zsh/_systemd-inhibit
6024
6025 systemd_inhibit_SOURCES = \
6026 src/login/inhibit.c
6027
6028 systemd_inhibit_LDADD = \
6029 libsystemd-shared.la
6030
6031 rootbin_PROGRAMS += \
6032 systemd-inhibit
6033
6034 test_login_SOURCES = \
6035 src/libsystemd/sd-login/test-login.c
6036
6037 test_login_LDADD = \
6038 libsystemd-shared.la
6039
6040 test_login_shared_SOURCES = \
6041 src/login/test-login-shared.c
6042
6043 test_login_shared_LDADD = \
6044 libsystemd-shared.la
6045
6046 test_inhibit_SOURCES = \
6047 src/login/test-inhibit.c
6048
6049 test_inhibit_LDADD = \
6050 libsystemd-shared.la
6051
6052 test_login_tables_SOURCES = \
6053 src/login/test-login-tables.c
6054
6055 test_login_tables_LDADD = \
6056 liblogind-core.la
6057
6058 manual_tests += \
6059 test-login \
6060 test-inhibit
6061
6062 tests += \
6063 test-login-tables \
6064 test-login-shared
6065
6066 if HAVE_PAM
6067 pam_systemd_la_SOURCES = \
6068 src/login/pam_systemd.sym \
6069 src/login/pam_systemd.c
6070
6071 pam_systemd_la_CFLAGS = \
6072 $(AM_CFLAGS) \
6073 $(PAM_CFLAGS)
6074
6075 pam_systemd_la_LDFLAGS = \
6076 $(AM_LDFLAGS) \
6077 -module \
6078 -export-dynamic \
6079 -avoid-version \
6080 -shared \
6081 -Wl,--version-script=$(top_srcdir)/src/login/pam_systemd.sym
6082
6083 pam_systemd_la_LIBADD = \
6084 libshared.la \
6085 $(PAM_LIBS)
6086
6087 pamlib_LTLIBRARIES = \
6088 pam_systemd.la
6089
6090 if ENABLE_PAM_CONFIG
6091 dist_pamconf_DATA = \
6092 src/login/systemd-user
6093 endif
6094
6095 EXTRA_DIST += \
6096 src/login/systemd-user.m4
6097 endif
6098
6099 nodist_systemunit_DATA += \
6100 units/systemd-logind.service
6101
6102 dist_systemunit_DATA += \
6103 units/user.slice
6104
6105 dist_systemunit_DATA_busnames += \
6106 units/org.freedesktop.login1.busname
6107
6108 dist_dbussystemservice_DATA += \
6109 src/login/org.freedesktop.login1.service
6110
6111 dist_dbuspolicy_DATA += \
6112 src/login/org.freedesktop.login1.conf
6113
6114 nodist_pkgsysconf_DATA += \
6115 src/login/logind.conf
6116
6117 polkitpolicy_files += \
6118 src/login/org.freedesktop.login1.policy
6119
6120 INSTALL_DIRS += \
6121 $(systemdstatedir)
6122
6123 MULTI_USER_TARGET_WANTS += \
6124 systemd-logind.service
6125
6126 SYSTEM_UNIT_ALIASES += \
6127 systemd-logind.service dbus-org.freedesktop.login1.service
6128
6129 BUSNAMES_TARGET_WANTS += \
6130 org.freedesktop.login1.busname
6131
6132 dist_udevrules_DATA += \
6133 src/login/70-uaccess.rules \
6134 src/login/70-power-switch.rules
6135
6136 nodist_udevrules_DATA += \
6137 src/login/71-seat.rules \
6138 src/login/73-seat-late.rules
6139
6140 endif
6141
6142 polkitpolicy_in_files += \
6143 src/login/org.freedesktop.login1.policy.in
6144
6145 gperf_gperf_sources += \
6146 src/login/logind-gperf.gperf
6147
6148 EXTRA_DIST += \
6149 src/login/71-seat.rules.in \
6150 src/login/73-seat-late.rules.in \
6151 units/systemd-logind.service.in \
6152 src/login/logind.conf.in
6153
6154 # ------------------------------------------------------------------------------
6155 if HAVE_PAM
6156
6157 systemd_user_sessions_SOURCES = \
6158 src/user-sessions/user-sessions.c
6159
6160 systemd_user_sessions_LDADD = \
6161 libsystemd-shared.la
6162
6163 rootlibexec_PROGRAMS += \
6164 systemd-user-sessions
6165
6166 nodist_systemunit_DATA += \
6167 units/systemd-user-sessions.service
6168
6169 MULTI_USER_TARGET_WANTS += \
6170 systemd-user-sessions.service
6171
6172 endif
6173
6174 EXTRA_DIST += \
6175 units/systemd-user-sessions.service.in
6176
6177 # ------------------------------------------------------------------------------
6178 EXTRA_DIST += \
6179 test/Makefile \
6180 test/README.testsuite \
6181 test/TEST-01-BASIC \
6182 test/TEST-01-BASIC/Makefile \
6183 test/TEST-01-BASIC/test.sh \
6184 test/TEST-02-CRYPTSETUP \
6185 test/TEST-02-CRYPTSETUP/Makefile \
6186 test/TEST-02-CRYPTSETUP/test.sh \
6187 test/TEST-03-JOBS \
6188 test/TEST-03-JOBS/Makefile \
6189 test/TEST-03-JOBS/test-jobs.sh \
6190 test/TEST-03-JOBS/test.sh \
6191 test/TEST-04-JOURNAL/Makefile \
6192 test/TEST-04-JOURNAL/test-journal.sh \
6193 test/TEST-04-JOURNAL/test.sh \
6194 test/TEST-05-RLIMITS/Makefile \
6195 test/TEST-05-RLIMITS/test-rlimits.sh \
6196 test/TEST-05-RLIMITS/test.sh \
6197 test/TEST-06-SELINUX/Makefile \
6198 test/TEST-06-SELINUX/test-selinux-checks.sh \
6199 test/TEST-06-SELINUX/test.sh \
6200 test/TEST-06-SELINUX/systemd_test.te \
6201 test/TEST-06-SELINUX/systemd_test.if \
6202 test/TEST-07-ISSUE-1981/Makefile \
6203 test/TEST-07-ISSUE-1981/test-segfault.sh \
6204 test/TEST-07-ISSUE-1981/test.sh \
6205 test/TEST-08-ISSUE-2730/Makefile \
6206 test/TEST-08-ISSUE-2730/test.sh \
6207 test/TEST-09-ISSUE-2691/Makefile \
6208 test/TEST-09-ISSUE-2691/test.sh \
6209 test/TEST-10-ISSUE-2467/Makefile \
6210 test/TEST-10-ISSUE-2467/test.sh \
6211 test/TEST-11-ISSUE-3166/Makefile \
6212 test/TEST-11-ISSUE-3166/test.sh \
6213 test/TEST-12-ISSUE-3171/Makefile \
6214 test/TEST-12-ISSUE-3171/test.sh \
6215 test/TEST-13-NSPAWN-SMOKE/Makefile \
6216 test/TEST-13-NSPAWN-SMOKE/create-busybox-container \
6217 test/TEST-13-NSPAWN-SMOKE/test.sh \
6218 test/TEST-14-MACHINE-ID/Makefile \
6219 test/TEST-14-MACHINE-ID/test.sh \
6220 test/test-functions
6221
6222 EXTRA_DIST += \
6223 test/loopy2.service \
6224 test/loopy3.service \
6225 test/loopy4.service \
6226 test/loopy.service \
6227 test/loopy.service.d \
6228 test/loopy.service.d/compat.conf
6229
6230 # ------------------------------------------------------------------------------
6231 substitutions = \
6232 '|rootlibdir=$(rootlibdir)|' \
6233 '|rootlibexecdir=$(rootlibexecdir)|' \
6234 '|rootbindir=$(rootbindir)|' \
6235 '|bindir=$(bindir)|' \
6236 '|SYSTEMCTL=$(rootbindir)/systemctl|' \
6237 '|SYSTEMD_NOTIFY=$(rootbindir)/systemd-notify|' \
6238 '|pkgsysconfdir=$(pkgsysconfdir)|' \
6239 '|SYSTEM_CONFIG_UNIT_PATH=$(pkgsysconfdir)/system|' \
6240 '|USER_CONFIG_UNIT_PATH=$(pkgsysconfdir)/user|' \
6241 '|pkgdatadir=$(pkgdatadir)|' \
6242 '|systemunitdir=$(systemunitdir)|' \
6243 '|userunitdir=$(userunitdir)|' \
6244 '|systempresetdir=$(systempresetdir)|' \
6245 '|userpresetdir=$(userpresetdir)|' \
6246 '|udevhwdbdir=$(udevhwdbdir)|' \
6247 '|udevrulesdir=$(udevrulesdir)|' \
6248 '|catalogdir=$(catalogdir)|' \
6249 '|tmpfilesdir=$(tmpfilesdir)|' \
6250 '|sysusersdir=$(sysusersdir)|' \
6251 '|sysctldir=$(sysctldir)|' \
6252 '|systemgeneratordir=$(systemgeneratordir)|' \
6253 '|usergeneratordir=$(usergeneratordir)|' \
6254 '|systemenvgeneratordir=$(systemenvgeneratordir)|' \
6255 '|userenvgeneratordir=$(userenvgeneratordir)|' \
6256 '|CERTIFICATEROOT=$(CERTIFICATEROOT)|' \
6257 '|PACKAGE_VERSION=$(PACKAGE_VERSION)|' \
6258 '|PACKAGE_NAME=$(PACKAGE_NAME)|' \
6259 '|PACKAGE_URL=$(PACKAGE_URL)|' \
6260 '|RANDOM_SEED_DIR=$(localstatedir)/lib/systemd/|' \
6261 '|RANDOM_SEED=$(localstatedir)/lib/systemd/random-seed|' \
6262 '|prefix=$(prefix)|' \
6263 '|exec_prefix=$(exec_prefix)|' \
6264 '|libdir=$(libdir)|' \
6265 '|includedir=$(includedir)|' \
6266 '|rootprefix=$(rootprefix)|' \
6267 '|udevlibexecdir=$(udevlibexecdir)|' \
6268 '|SUSHELL=$(SUSHELL)|' \
6269 '|SULOGIN=$(SULOGIN)|' \
6270 '|DEBUGTTY=$(DEBUGTTY)|' \
6271 '|KILL=$(KILL)|' \
6272 '|KMOD=$(KMOD)|' \
6273 '|MOUNT_PATH=$(MOUNT_PATH)|' \
6274 '|UMOUNT_PATH=$(UMOUNT_PATH)|' \
6275 '|MKDIR_P=$(MKDIR_P)|' \
6276 '|QUOTAON=$(QUOTAON)|' \
6277 '|QUOTACHECK=$(QUOTACHECK)|' \
6278 '|SYSTEM_SYSVINIT_PATH=$(sysvinitdir)|' \
6279 '|VARLOGDIR=$(varlogdir)|' \
6280 '|RC_LOCAL_SCRIPT_PATH_START=$(RC_LOCAL_SCRIPT_PATH_START)|' \
6281 '|RC_LOCAL_SCRIPT_PATH_STOP=$(RC_LOCAL_SCRIPT_PATH_STOP)|' \
6282 '|PYTHON=$(PYTHON)|' \
6283 '|NTP_SERVERS=$(NTP_SERVERS)|' \
6284 '|DNS_SERVERS=$(DNS_SERVERS)|' \
6285 '|DEFAULT_DNSSEC_MODE=$(DEFAULT_DNSSEC_MODE)|' \
6286 '|KILL_USER_PROCESSES=$(KILL_USER_PROCESSES)|' \
6287 '|systemuidmax=$(SYSTEM_UID_MAX)|' \
6288 '|systemgidmax=$(SYSTEM_GID_MAX)|' \
6289 '|DEV_KVM_MODE=$(DEV_KVM_MODE)|' \
6290 '|TTY_GID=$(TTY_GID)|' \
6291 '|systemsleepdir=$(systemsleepdir)|' \
6292 '|systemshutdowndir=$(systemshutdowndir)|' \
6293 '|binfmtdir=$(binfmtdir)|' \
6294 '|modulesloaddir=$(modulesloaddir)|'
6295
6296 SED_PROCESS = \
6297 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
6298 $(SED) $(subst '|,-e 's|@,$(subst =,\@|,$(subst |',|g',$(substitutions)))) \
6299 -e '/^\#\# /d' \
6300 < $< > $@
6301
6302 units/%: units/%.in
6303 $(SED_PROCESS)
6304
6305 man/%: man/%.in
6306 $(SED_PROCESS)
6307
6308 sysctl.d/%: sysctl.d/%.in
6309 $(SED_PROCESS)
6310
6311 %.pc: %.pc.in
6312 $(SED_PROCESS)
6313
6314 %.conf: %.conf.in
6315 $(SED_PROCESS)
6316
6317 src/core/%.systemd: src/core/%.systemd.in
6318 $(SED_PROCESS)
6319
6320 src/%.policy.in: src/%.policy.in.in
6321 $(SED_PROCESS)
6322
6323 src/sulogin-shell/%: src/sulogin-shell/%.in
6324 $(SED_PROCESS)
6325 $(AM_V_GEN)chmod +x $@
6326
6327 shell-completion/%: shell-completion/%.in
6328 $(SED_PROCESS)
6329
6330 %.rules: %.rules.in
6331 $(SED_PROCESS)
6332
6333 %.conf: %.conf.in
6334 $(SED_PROCESS)
6335
6336 %.sh: %.sh.in
6337 $(SED_PROCESS)
6338 $(AM_V_GEN)chmod +x $@
6339
6340 src/%.c: src/%.gperf
6341 $(AM_V_at)$(MKDIR_P) $(dir $@)
6342 $(AM_V_GPERF)$(GPERF) < $< > $@
6343
6344 src/%: src/%.m4 $(top_builddir)/config.status
6345 $(AM_V_at)$(MKDIR_P) $(dir $@)
6346 $(AM_V_M4)$(M4) -P $(M4_DEFINES) < $< > $@
6347
6348 sysusers.d/%: sysusers.d/%.m4 $(top_builddir)/config.status
6349 $(AM_V_at)$(MKDIR_P) $(dir $@)
6350 $(AM_V_M4)$(M4) -P $(M4_DEFINES) < $< > $@
6351
6352 tmpfiles.d/%: tmpfiles.d/%.m4 $(top_builddir)/config.status
6353 $(AM_V_at)$(MKDIR_P) $(dir $@)
6354 $(AM_V_M4)$(M4) -P $(M4_DEFINES) < $< > $@
6355
6356
6357 units/%: units/%.m4 $(top_builddir)/config.status
6358 $(AM_V_at)$(MKDIR_P) $(dir $@)
6359 $(AM_V_M4)$(M4) -P $(M4_DEFINES) -DFOR_SYSTEM=1 < $< > $@
6360
6361 units/user/%: units/user/%.m4 $(top_builddir)/config.status
6362 $(AM_V_at)$(MKDIR_P) $(dir $@)
6363 $(AM_V_M4)$(M4) -P $(M4_DEFINES) -DFOR_USER=1 < $< > $@
6364
6365 if ENABLE_POLKIT
6366 nodist_polkitpolicy_DATA = \
6367 $(polkitpolicy_files) \
6368 $(polkitpolicy_in_in_files:.policy.in.in=.policy)
6369 polkitrules_DATA = $(polkitrules_files)
6370 if ENABLE_POLKIT_PKLA
6371 polkitpkla_DATA = $(polkitpkla_files)
6372 endif
6373 endif
6374
6375 EXTRA_DIST += \
6376 $(polkitpolicy_in_files) \
6377 $(polkitpolicy_in_in_files)
6378
6379 # ------------------------------------------------------------------------------
6380 man/custom-entities.ent: configure.ac
6381 $(AM_V_GEN)$(MKDIR_P) $(dir $@)
6382 $(AM_V_GEN)(echo '<?xml version="1.0" encoding="utf-8" ?>' && \
6383 printf '$(subst '|,<!ENTITY ,$(subst =, ",$(subst |',">\n,$(substitutions))))') \
6384 > $@ # '
6385
6386 CLEANFILES += \
6387 man/custom-entities.ent
6388
6389 XSLTPROC_FLAGS = \
6390 --nonet \
6391 --xinclude \
6392 --stringparam man.output.quietly 1 \
6393 --stringparam funcsynopsis.style ansi \
6394 --stringparam man.authors.section.enabled 0 \
6395 --stringparam man.copyright.section.enabled 0 \
6396 --stringparam systemd.version $(PACKAGE_VERSION) \
6397 --path '$(builddir)/man:$(srcdir)/man'
6398
6399 XSLT = $(if $(XSLTPROC), $(XSLTPROC), xsltproc)
6400 XSLTPROC_PROCESS_MAN = \
6401 $(AM_V_XSLT)$(XSLT) -o $@ $(XSLTPROC_FLAGS) $(srcdir)/man/custom-man.xsl $<
6402
6403 XSLTPROC_PROCESS_HTML = \
6404 $(AM_V_XSLT)$(XSLT) -o $@ $(XSLTPROC_FLAGS) $(srcdir)/man/custom-html.xsl $<
6405
6406 man/%.1: man/%.xml man/custom-man.xsl man/custom-entities.ent
6407 $(XSLTPROC_PROCESS_MAN)
6408
6409 man/%.3: man/%.xml man/custom-man.xsl man/custom-entities.ent
6410 $(XSLTPROC_PROCESS_MAN)
6411
6412 man/%.5: man/%.xml man/custom-man.xsl man/custom-entities.ent
6413 $(XSLTPROC_PROCESS_MAN)
6414
6415 man/%.7: man/%.xml man/custom-man.xsl man/custom-entities.ent
6416 $(XSLTPROC_PROCESS_MAN)
6417
6418 man/%.8: man/%.xml man/custom-man.xsl man/custom-entities.ent
6419 $(XSLTPROC_PROCESS_MAN)
6420
6421 man/%.html: man/%.xml man/custom-html.xsl man/custom-entities.ent
6422 $(XSLTPROC_PROCESS_HTML)
6423
6424 define html-alias
6425 $(AM_V_LN)$(LN_S) -f $(notdir $<) $@
6426 endef
6427
6428 EXTRA_DIST += \
6429 man/custom-html.xsl \
6430 man/custom-man.xsl
6431
6432 # ------------------------------------------------------------------------------
6433 if HAVE_SYSV_COMPAT
6434 sysvinit_DATA = \
6435 docs/sysvinit/README
6436
6437 varlog_DATA = \
6438 docs/var-log/README
6439
6440 docs/sysvinit/README: docs/sysvinit/README.in
6441 $(SED_PROCESS)
6442
6443 docs/var-log/README: docs/var-log/README.in
6444 $(SED_PROCESS)
6445
6446 CLEANFILES += \
6447 docs/sysvinit/README \
6448 docs/var-log/README
6449 endif
6450
6451 EXTRA_DIST += \
6452 docs/sysvinit/README.in \
6453 docs/var-log/README.in
6454
6455 SOCKETS_TARGET_WANTS += \
6456 systemd-initctl.socket
6457
6458 if HAVE_UTMP
6459 if HAVE_SYSV_COMPAT
6460 MULTI_USER_TARGET_WANTS += \
6461 systemd-update-utmp-runlevel.service
6462 GRAPHICAL_TARGET_WANTS += \
6463 systemd-update-utmp-runlevel.service
6464 RESCUE_TARGET_WANTS += \
6465 systemd-update-utmp-runlevel.service
6466 endif
6467
6468 SYSINIT_TARGET_WANTS += \
6469 systemd-update-utmp.service
6470 endif
6471
6472 SYSINIT_TARGET_WANTS += \
6473 systemd-update-done.service
6474
6475 LOCAL_FS_TARGET_WANTS += \
6476 systemd-remount-fs.service \
6477 tmp.mount \
6478 var-lib-machines.mount
6479
6480 MULTI_USER_TARGET_WANTS += \
6481 getty.target \
6482 systemd-ask-password-wall.path
6483
6484 SYSINIT_TARGET_WANTS += \
6485 dev-hugepages.mount \
6486 dev-mqueue.mount \
6487 sys-kernel-config.mount \
6488 sys-kernel-debug.mount \
6489 sys-fs-fuse-connections.mount \
6490 systemd-sysctl.service \
6491 systemd-ask-password-console.path
6492
6493 if HAVE_SYSV_COMPAT
6494 SYSTEM_UNIT_ALIASES += \
6495 poweroff.target runlevel0.target \
6496 rescue.target runlevel1.target \
6497 multi-user.target runlevel2.target \
6498 multi-user.target runlevel3.target \
6499 multi-user.target runlevel4.target \
6500 graphical.target runlevel5.target \
6501 reboot.target runlevel6.target
6502 endif
6503
6504 SYSTEM_UNIT_ALIASES += \
6505 graphical.target default.target \
6506 reboot.target ctrl-alt-del.target \
6507 getty@.service autovt@.service
6508
6509 GENERAL_ALIASES += \
6510 $(systemunitdir)/remote-fs.target $(pkgsysconfdir)/system/multi-user.target.wants/remote-fs.target \
6511 $(systemunitdir)/getty@.service $(pkgsysconfdir)/system/getty.target.wants/getty@tty1.service \
6512 $(pkgsysconfdir)/user $(sysconfdir)/xdg/systemd/user \
6513 $(dbussystemservicedir)/org.freedesktop.systemd1.service $(dbussessionservicedir)/org.freedesktop.systemd1.service
6514
6515 if HAVE_SYSV_COMPAT
6516 INSTALL_DIRS += \
6517 $(systemunitdir)/runlevel1.target.wants \
6518 $(systemunitdir)/runlevel2.target.wants \
6519 $(systemunitdir)/runlevel3.target.wants \
6520 $(systemunitdir)/runlevel4.target.wants \
6521 $(systemunitdir)/runlevel5.target.wants
6522 endif
6523
6524 INSTALL_DIRS += \
6525 $(environmentdir) \
6526 $(prefix)/lib/modules-load.d \
6527 $(sysconfdir)/modules-load.d \
6528 $(prefix)/lib/systemd/network \
6529 $(sysconfdir)/systemd/network \
6530 $(prefix)/lib/sysctl.d \
6531 $(sysconfdir)/sysctl.d \
6532 $(prefix)/lib/kernel/install.d \
6533 $(sysconfdir)/kernel/install.d \
6534 $(systemshutdowndir) \
6535 $(systemsleepdir) \
6536 $(systemgeneratordir) \
6537 $(usergeneratordir) \
6538 \
6539 $(userunitdir) \
6540 $(pkgsysconfdir)/system \
6541 $(pkgsysconfdir)/system/multi-user.target.wants \
6542 $(pkgsysconfdir)/system/getty.target.wants \
6543 $(pkgsysconfdir)/user \
6544 $(dbussessionservicedir) \
6545 $(sysconfdir)/xdg/systemd
6546
6547 install-exec-hook: $(INSTALL_EXEC_HOOKS)
6548
6549 uninstall-hook: $(UNINSTALL_DATA_HOOKS) $(UNINSTALL_EXEC_HOOKS)
6550
6551 install-data-hook: $(INSTALL_DATA_HOOKS)
6552
6553 distclean-local: $(DISTCLEAN_LOCAL_HOOKS)
6554
6555 clean-local: $(CLEAN_LOCAL_HOOKS)
6556 rm -rf $(abs_srcdir)/install-tree
6557 rm -f $(abs_srcdir)/hwdb/usb.ids $(abs_srcdir)/hwdb/pci.ids $(abs_srcdir)/hwdb/oui.txt \
6558 $(abs_srcdir)/hwdb/iab.txt
6559
6560 DISTCHECK_CONFIGURE_FLAGS = \
6561 --with-dbuspolicydir=$$dc_install_base/$(dbuspolicydir) \
6562 --with-dbussessionservicedir=$$dc_install_base/$(dbussessionservicedir) \
6563 --with-dbussystemservicedir=$$dc_install_base/$(dbussystemservicedir) \
6564 --with-bashcompletiondir=$$dc_install_base/$(bashcompletiondir) \
6565 --with-zshcompletiondir=$$dc_install_base/$(zshcompletiondir) \
6566 --with-pamlibdir=$$dc_install_base/$(pamlibdir) \
6567 --with-pamconfdir=$$dc_install_base/$(pamconfdir) \
6568 --with-rpmmacrosdir=$$dc_install_base/$(rpmmacrosdir) \
6569 --with-rootprefix=$$dc_install_base \
6570 --enable-compat-libs
6571
6572 if HAVE_SYSV_COMPAT
6573 DISTCHECK_CONFIGURE_FLAGS += \
6574 --with-sysvinit-path=$$dc_install_base/$(sysvinitdir) \
6575 --with-sysvrcnd-path=$$dc_install_base/$(sysvrcnddir)
6576 else
6577 DISTCHECK_CONFIGURE_FLAGS += \
6578 --with-sysvinit-path= \
6579 --with-sysvrcnd-path=
6580 endif
6581
6582 if ENABLE_SPLIT_USR
6583 DISTCHECK_CONFIGURE_FLAGS += \
6584 --enable-split-usr
6585 else
6586 DISTCHECK_CONFIGURE_FLAGS += \
6587 --disable-split-usr
6588 endif
6589
6590 .PHONY: dist-check-help
6591 dist-check-help: $(rootbin_PROGRAMS) $(bin_PROGRAMS)
6592 for i in $(abspath $^); do \
6593 if $$i --help | grep -v 'default:' | grep -E -q '.{80}.' ; then \
6594 echo "$(basename $$i) --help output is too wide:"; \
6595 $$i --help | awk 'length > 80' | grep -E --color=yes '.{80}'; \
6596 exit 1; \
6597 fi; done
6598
6599 include_compilers = "$(CC)" "$(CC) -ansi" "$(CC) -std=iso9899:1990"
6600 public_headers = $(filter-out src/systemd/_sd-common.h, $(pkginclude_HEADERS) $(include_HEADERS))
6601 .PHONY: dist-check-includes
6602 dist-check-includes: $(public_headers)
6603 @res=0; \
6604 for i in $(abspath $^); do \
6605 for cc in $(include_compilers); do \
6606 echo "$$cc -o/dev/null -c -x c -include "$$i" - </dev/null"; \
6607 $$cc -o/dev/null -c -x c -include "$$i" - </dev/null || res=1; \
6608 done; \
6609 done; exit $$res
6610
6611 .PHONY: hwdb-update
6612 hwdb-update: tools/meson-hwdb-update.sh
6613 $< $(top_srcdir)/hwdb
6614
6615 .PHONY: built-sources
6616 built-sources: $(BUILT_SOURCES)
6617
6618 .PHONY: git-tag
6619 git-tag:
6620 git tag -s "v$(PACKAGE_VERSION)" -m "systemd $(PACKAGE_VERSION)"
6621
6622 .PHONY: git-tar
6623 git-tar:
6624 git archive -o systemd-$(PACKAGE_VERSION).tar.gz --prefix=systemd-$(PACKAGE_VERSION)/ HEAD
6625
6626 %.asc: %
6627 gpg2 --detach-sign -a -o $@ $<
6628
6629 www_target = www.freedesktop.org:/srv/www.freedesktop.org/www/software/systemd
6630
6631 .PHONY: doc-sync
6632 doc-sync: man
6633 rsync -rlv --delete-excluded --include="*.html" --exclude="*" --omit-dir-times man/ $(www_target)/man/
6634
6635 .PHONY: install-tree
6636 install-tree: all
6637 rm -rf $(abs_srcdir)/install-tree
6638 $(MAKE) install DESTDIR=$(abs_srcdir)/install-tree
6639 tree $(abs_srcdir)/install-tree
6640
6641 # Let's run all tests of the test suite, but under valgrind. Let's
6642 # exclude perl/python/shell scripts we have in there
6643 .PHONY: valgrind-tests
6644 valgrind-tests: $(TESTS)
6645 $(AM_V_GEN)for f in $(filter-out %.pl %.py, $^); do \
6646 if $(LIBTOOL) --mode=execute file $$f | grep -q shell; then \
6647 echo -e "$${x}Skipping non-binary $$f"; else \
6648 echo -e "$${x}Running $$f"; \
6649 $(AM_TESTS_ENVIRONMENT) $(LIBTOOL) --mode=execute valgrind -q --leak-check=full --max-stackframe=5242880 --error-exitcode=55 $(builddir)/$$f ; fi; \
6650 x="\n\n"; \
6651 done
6652
6653 exported-%: %
6654 $(AM_V_GEN)$(NM) -g --defined-only $(builddir)/.libs/$(<:.la=.so) 2>&1 /dev/null | grep " T " | cut -d" " -f3 > $@
6655
6656 exported: $(addprefix exported-, $(lib_LTLIBRARIES))
6657 $(AM_V_GEN)sort -u $^ > $@
6658
6659 .PHONY: check-api-docs
6660 check-api-docs: exported man
6661 $(AM_V_GEN)for symbol in `cat exported` ; do \
6662 if test -f $(builddir)/man/$$symbol.html ; then \
6663 echo " Symbol $$symbol() is documented." ; \
6664 else \
6665 echo "‣ Symbol $$symbol() lacks documentation." ; \
6666 fi ; \
6667 done
6668
6669 OBJECT_VARIABLES:=$(filter %_OBJECTS,$(.VARIABLES))
6670 ALL_OBJECTS:=$(foreach v,$(OBJECT_VARIABLES),$($(v)))
6671
6672 undefined defined: $(ALL_OBJECTS)
6673 $(AM_V_GEN)for f in $(ALL_OBJECTS) ; do \
6674 $(NM) -g --$@-only `echo $(builddir)/"$$f" | sed -e 's,\([^/]*\).lo$$,.libs/\1.o,'` ; \
6675 done | cut -c 20- | cut -d @ -f 1 | sort -u > $@
6676
6677 CLEANFILES += \
6678 defined \
6679 undefined
6680
6681 .PHONY: check-api-unused
6682 check-api-unused: defined undefined exported
6683 ( cat exported undefined ) | sort -u | diff -u - defined | grep ^+ | grep -v ^+++ | cut -c2-
6684
6685 .PHONY: check-includes
6686 check-includes: $(top_srcdir)/tools/check-includes.pl
6687 $(AM_V_GEN) find * -name '*.[hcS]' -type f -print | sort -u \
6688 | xargs $(top_srcdir)/tools/check-includes.pl
6689
6690 EXTRA_DIST += \
6691 $(top_srcdir)/tools/check-includes.pl
6692
6693 # Stupid test that everything purported to be exported really is
6694 define generate-sym-test
6695 $(AM_V_at)$(MKDIR_P) $(dir $@)
6696 $(AM_V_at)printf '#include <stdio.h>\n' > $@
6697 $(AM_V_at)printf '#include "%s"\n' $(notdir $(filter %.h, $^)) >> $@
6698 $(AM_V_at)printf 'void* functions[] = {\n' >> $@
6699 $(AM_V_GEN)sed -r -n 's/^ +([a-zA-Z0-9_]+);/\1,/p' $< >> $@
6700 $(AM_V_at)printf '};\nint main(void) {\n' >> $@
6701 $(AM_V_at)printf 'unsigned i; for (i=0;i<sizeof(functions)/sizeof(void*);i++) printf("%%p\\n", functions[i]);\n' >> $@
6702 $(AM_V_at)printf 'return 0; }\n' >> $@
6703 endef
6704
6705 test-libsystemd-sym.c: \
6706 $(top_builddir)/src/libsystemd/libsystemd.sym \
6707 src/systemd/sd-journal.h \
6708 src/systemd/sd-daemon.h \
6709 src/systemd/sd-login.h \
6710 src/systemd/sd-bus.h \
6711 src/systemd/sd-utf8.h \
6712 src/systemd/sd-resolve.h \
6713 src/systemd/sd-path.h \
6714 src/systemd/sd-event.h
6715 $(generate-sym-test)
6716
6717 test-libudev-sym.c: \
6718 src/libudev/libudev.sym \
6719 src/udev/udev.h
6720 $(generate-sym-test)
6721
6722 nodist_test_libsystemd_sym_SOURCES = \
6723 test-libsystemd-sym.c
6724 test_libsystemd_sym_LDADD = \
6725 libsystemd.la
6726
6727 nodist_test_libudev_sym_SOURCES = \
6728 test-libudev-sym.c
6729 test_libudev_sym_CFLAGS = \
6730 $(AM_CFLAGS) \
6731 -Wno-deprecated-declarations
6732 test_libudev_sym_LDADD = \
6733 libudev.la
6734
6735 BUILT_SOURCES += \
6736 test-libsystemd-sym.c \
6737 test-libudev-sym.c
6738
6739 CLEANFILES += \
6740 test-libsystemd-sym.c \
6741 test-libudev-sym.c
6742
6743 tests += \
6744 test-libsystemd-sym \
6745 test-libudev-sym
6746
6747 .PHONY: install-tests
6748 install-tests: $(tests) $(TEST_DATA_FILES)
6749 for f in $(tests); do \
6750 if [ -x $(top_builddir)/.libs/$$f ]; then \
6751 install -D -m 755 $(top_builddir)/.libs/$$f $(DESTDIR)/$(testsdir)/$$f; \
6752 else \
6753 install -D -m 755 $(top_builddir)/$$f $(DESTDIR)/$(testsdir)/$$f; \
6754 fi; \
6755 done
6756 for f in $(TEST_DATA_FILES); do \
6757 install -D -m 644 $(top_srcdir)/$$f $(DESTDIR)/$(testsdir)/testdata/$${f#test/}; \
6758 done
6759
6760
6761 .PHONY: cppcheck
6762 cppcheck:
6763 cppcheck --enable=all -q $(top_srcdir)
6764
6765 # Used to extract compile flags for YCM.
6766 print-%:
6767 @echo $($*)
6768
6769 .PHONY: git-contrib
6770 git-contrib:
6771 @git shortlog -s `git describe --abbrev=0`.. | cut -c8- | sed 's/ / /g' | awk '{ print $$0 "," }' | sort -u
6772
6773 EXTRA_DIST += \
6774 tools/gdb-sd_dump_hashmaps.py
6775
6776 .PHONY: list-keys
6777 list-keys:
6778 gpg --verbose --no-options --no-default-keyring --no-auto-key-locate --batch --trust-model=always --keyring=$(srcdir)/src/import/import-pubring.gpg --list-keys
6779
6780 .PHONY: add-key
6781 add-key:
6782 gpg --verbose --no-options --no-default-keyring --no-auto-key-locate --batch --trust-model=always --keyring=$(srcdir)/src/import/import-pubring.gpg --import -