chiark / gitweb /
systemd-verify: a simple tool for offline unit verification
[elogind.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 SUBDIRS = . po
28
29 # remove targets if the command fails
30 .DELETE_ON_ERROR:
31
32 # keep intermediate files
33 .SECONDARY:
34
35 # Keep the test-suite.log
36 .PRECIOUS: $(TEST_SUITE_LOG) Makefile
37
38 LIBUDEV_CURRENT=6
39 LIBUDEV_REVISION=0
40 LIBUDEV_AGE=5
41
42 LIBGUDEV_CURRENT=2
43 LIBGUDEV_REVISION=0
44 LIBGUDEV_AGE=2
45
46 LIBSYSTEMD_CURRENT=3
47 LIBSYSTEMD_REVISION=1
48 LIBSYSTEMD_AGE=3
49
50 # The following four libraries only exist for compatibility reasons,
51 # their version info should not be bumped anymore
52 LIBSYSTEMD_LOGIN_CURRENT=9
53 LIBSYSTEMD_LOGIN_REVISION=3
54 LIBSYSTEMD_LOGIN_AGE=9
55
56 LIBSYSTEMD_DAEMON_CURRENT=0
57 LIBSYSTEMD_DAEMON_REVISION=12
58 LIBSYSTEMD_DAEMON_AGE=0
59
60 LIBSYSTEMD_ID128_CURRENT=0
61 LIBSYSTEMD_ID128_REVISION=28
62 LIBSYSTEMD_ID128_AGE=0
63
64 LIBSYSTEMD_JOURNAL_CURRENT=11
65 LIBSYSTEMD_JOURNAL_REVISION=5
66 LIBSYSTEMD_JOURNAL_AGE=11
67
68 # Dirs of external packages
69 dbuspolicydir=@dbuspolicydir@
70 dbussessionservicedir=@dbussessionservicedir@
71 dbussystemservicedir=@dbussystemservicedir@
72 pamlibdir=@pamlibdir@
73 pamconfdir=@pamconfdir@
74 pkgconfigdatadir=$(datadir)/pkgconfig
75 pkgconfiglibdir=$(libdir)/pkgconfig
76 polkitpolicydir=$(datadir)/polkit-1/actions
77 bashcompletiondir=@bashcompletiondir@
78 zshcompletiondir=@zshcompletiondir@
79 rpmmacrosdir=$(prefix)/lib/rpm/macros.d
80 sysvinitdir=$(SYSTEM_SYSVINIT_PATH)
81 sysvrcnddir=$(SYSTEM_SYSVRCND_PATH)
82 varlogdir=$(localstatedir)/log
83 systemdstatedir=$(localstatedir)/lib/systemd
84 catalogstatedir=$(systemdstatedir)/catalog
85
86 # Our own, non-special dirs
87 pkgsysconfdir=$(sysconfdir)/systemd
88 userunitdir=$(prefix)/lib/systemd/user
89 userpresetdir=$(prefix)/lib/systemd/user-preset
90 tmpfilesdir=$(prefix)/lib/tmpfiles.d
91 sysusersdir=$(prefix)/lib/sysusers.d
92 sysctldir=$(prefix)/lib/sysctl.d
93 binfmtdir=$(prefix)/lib/binfmt.d
94 modulesloaddir=$(prefix)/lib/modules-load.d
95 networkdir=$(rootprefix)/lib/systemd/network
96 pkgincludedir=$(includedir)/systemd
97 systemgeneratordir=$(rootlibexecdir)/system-generators
98 usergeneratordir=$(prefix)/lib/systemd/user-generators
99 systemshutdowndir=$(rootlibexecdir)/system-shutdown
100 systemsleepdir=$(rootlibexecdir)/system-sleep
101 systemunitdir=$(rootprefix)/lib/systemd/system
102 systempresetdir=$(rootprefix)/lib/systemd/system-preset
103 udevlibexecdir=$(rootprefix)/lib/udev
104 udevhomedir=$(udevlibexecdir)
105 udevrulesdir=$(udevlibexecdir)/rules.d
106 udevhwdbdir=$(udevlibexecdir)/hwdb.d
107 catalogdir=$(prefix)/lib/systemd/catalog
108 kernelinstalldir = $(prefix)/lib/kernel/install.d
109
110 # And these are the special ones for /
111 rootprefix=@rootprefix@
112 rootbindir=$(rootprefix)/bin
113 rootlibexecdir=$(rootprefix)/lib/systemd
114
115 CLEANFILES = $(BUILT_SOURCES)
116 DISTCLEANFILES =
117 EXTRA_DIST =
118 BUILT_SOURCES =
119 INSTALL_EXEC_HOOKS =
120 UNINSTALL_EXEC_HOOKS =
121 INSTALL_DATA_HOOKS =
122 UNINSTALL_DATA_HOOKS =
123 DISTCLEAN_LOCAL_HOOKS =
124 CLEAN_LOCAL_HOOKS =
125 pkginclude_HEADERS =
126 noinst_LTLIBRARIES =
127 lib_LTLIBRARIES =
128 include_HEADERS =
129 noinst_DATA =
130 pkgconfiglib_DATA =
131 polkitpolicy_in_in_files =
132 polkitpolicy_in_files =
133 polkitpolicy_files =
134 dist_udevrules_DATA =
135 nodist_udevrules_DATA =
136 dist_pkgsysconf_DATA =
137 nodist_pkgsysconf_DATA =
138 dist_pkgdata_DATA =
139 dist_dbuspolicy_DATA =
140 dist_dbussystemservice_DATA =
141 check_PROGRAMS =
142 check_DATA =
143 tests=
144 manual_tests =
145 if ENABLE_TESTS
146 noinst_PROGRAMS = $(manual_tests) $(tests)
147 TESTS = $(tests)
148 else
149 noinst_PROGRAMS =
150 TESTS =
151 endif
152 udevlibexec_PROGRAMS =
153
154 .PHONY: $(INSTALL_EXEC_HOOKS) $(UNINSTALL_EXEC_HOOKS) \
155         $(INSTALL_DATA_HOOKS) $(UNINSTALL_DATA_HOOKS) \
156         $(DISTCLEAN_LOCAL_HOOKS) $(CLEAN_LOCAL_HOOKS)
157
158 AM_CPPFLAGS = \
159         -include $(top_builddir)/config.h \
160         -DPKGSYSCONFDIR=\"$(pkgsysconfdir)\" \
161         -DSYSTEM_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/system\" \
162         -DSYSTEM_DATA_UNIT_PATH=\"$(systemunitdir)\" \
163         -DSYSTEM_SYSVINIT_PATH=\"$(SYSTEM_SYSVINIT_PATH)\" \
164         -DSYSTEM_SYSVRCND_PATH=\"$(SYSTEM_SYSVRCND_PATH)\" \
165         -DUSER_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/user\" \
166         -DUSER_DATA_UNIT_PATH=\"$(userunitdir)\" \
167         -DCERTIFICATE_ROOT=\"$(CERTIFICATEROOT)\" \
168         -DCATALOG_DATABASE=\"$(catalogstatedir)/database\" \
169         -DSYSTEMD_CGROUP_AGENT_PATH=\"$(rootlibexecdir)/systemd-cgroups-agent\" \
170         -DSYSTEMD_BINARY_PATH=\"$(rootlibexecdir)/systemd\" \
171         -DSYSTEMD_SHUTDOWN_BINARY_PATH=\"$(rootlibexecdir)/systemd-shutdown\" \
172         -DSYSTEMD_SLEEP_BINARY_PATH=\"$(rootlibexecdir)/systemd-sleep\" \
173         -DSYSTEMCTL_BINARY_PATH=\"$(rootbindir)/systemctl\" \
174         -DSYSTEMD_TTY_ASK_PASSWORD_AGENT_BINARY_PATH=\"$(rootbindir)/systemd-tty-ask-password-agent\" \
175         -DSYSTEMD_STDIO_BRIDGE_BINARY_PATH=\"$(bindir)/systemd-stdio-bridge\" \
176         -DROOTPREFIX=\"$(rootprefix)\" \
177         -DRANDOM_SEED_DIR=\"$(localstatedir)/lib/systemd/\" \
178         -DRANDOM_SEED=\"$(localstatedir)/lib/systemd/random-seed\" \
179         -DSYSTEMD_CRYPTSETUP_PATH=\"$(rootlibexecdir)/systemd-cryptsetup\" \
180         -DSYSTEM_GENERATOR_PATH=\"$(systemgeneratordir)\" \
181         -DUSER_GENERATOR_PATH=\"$(usergeneratordir)\" \
182         -DSYSTEM_SHUTDOWN_PATH=\"$(systemshutdowndir)\" \
183         -DSYSTEM_SLEEP_PATH=\"$(systemsleepdir)\" \
184         -DSYSTEMD_KBD_MODEL_MAP=\"$(pkgdatadir)/kbd-model-map\" \
185         -DX_SERVER=\"$(bindir)/X\" \
186         -DUDEVLIBEXECDIR=\"$(udevlibexecdir)\" \
187         -DPOLKIT_AGENT_BINARY_PATH=\"$(bindir)/pkttyagent\" \
188         -DQUOTACHECK=\"$(QUOTACHECK)\" \
189         -DKEXEC=\"$(KEXEC)\" \
190         -DLIBDIR=\"$(libdir)\" \
191         -DROOTLIBDIR=\"$(rootlibdir)\" \
192         -DTEST_DIR=\"$(abs_top_srcdir)/test\" \
193         -I $(top_srcdir)/src \
194         -I $(top_builddir)/src/shared \
195         -I $(top_srcdir)/src/shared \
196         -I $(top_srcdir)/src/network \
197         -I $(top_srcdir)/src/login \
198         -I $(top_srcdir)/src/journal \
199         -I $(top_srcdir)/src/timedate \
200         -I $(top_srcdir)/src/timesync \
201         -I $(top_srcdir)/src/resolve \
202         -I $(top_srcdir)/src/systemd \
203         -I $(top_builddir)/src/core \
204         -I $(top_srcdir)/src/core \
205         -I $(top_srcdir)/src/libudev \
206         -I $(top_srcdir)/src/udev \
207         -I $(top_srcdir)/src/udev/net \
208         -I $(top_builddir)/src/udev \
209         -I $(top_srcdir)/src/libsystemd/sd-bus \
210         -I $(top_srcdir)/src/libsystemd/sd-event \
211         -I $(top_srcdir)/src/libsystemd/sd-rtnl \
212         -I $(top_srcdir)/src/libsystemd-network \
213         -I $(top_srcdir)/src/libsystemd-terminal \
214         $(OUR_CPPFLAGS)
215
216 AM_CFLAGS = $(OUR_CFLAGS)
217 AM_LDFLAGS = $(OUR_LDFLAGS)
218
219 # ------------------------------------------------------------------------------
220 define move-to-rootlibdir
221         if test "$(libdir)" != "$(rootlibdir)"; then \
222                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
223                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/$$libname) && \
224                 rm -f $(DESTDIR)$(libdir)/$$libname && \
225                 $(LN_S) --relative -f $(DESTDIR)$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/$$libname && \
226                 mv $(DESTDIR)$(libdir)/$$libname.* $(DESTDIR)$(rootlibdir); \
227         fi
228 endef
229
230 INSTALL_DIRS =
231
232 RUNLEVEL1_TARGET_WANTS =
233 RUNLEVEL2_TARGET_WANTS =
234 RUNLEVEL3_TARGET_WANTS =
235 RUNLEVEL4_TARGET_WANTS =
236 RUNLEVEL5_TARGET_WANTS =
237 SHUTDOWN_TARGET_WANTS =
238 LOCAL_FS_TARGET_WANTS =
239 MULTI_USER_TARGET_WANTS =
240 SYSINIT_TARGET_WANTS =
241 SOCKETS_TARGET_WANTS =
242 BUSNAMES_TARGET_WANTS =
243 TIMERS_TARGET_WANTS =
244 USER_SOCKETS_TARGET_WANTS =
245 USER_BUSNAMES_TARGET_WANTS =
246
247 SYSTEM_UNIT_ALIASES =
248 USER_UNIT_ALIASES =
249 GENERAL_ALIASES =
250
251 install-target-wants-hook:
252         what="$(RUNLEVEL1_TARGET_WANTS)" && wants=runlevel1.target && dir=$(systemunitdir) && $(add-wants)
253         what="$(RUNLEVEL2_TARGET_WANTS)" && wants=runlevel2.target && dir=$(systemunitdir) && $(add-wants)
254         what="$(RUNLEVEL3_TARGET_WANTS)" && wants=runlevel3.target && dir=$(systemunitdir) && $(add-wants)
255         what="$(RUNLEVEL4_TARGET_WANTS)" && wants=runlevel4.target && dir=$(systemunitdir) && $(add-wants)
256         what="$(RUNLEVEL5_TARGET_WANTS)" && wants=runlevel5.target && dir=$(systemunitdir) && $(add-wants)
257         what="$(SHUTDOWN_TARGET_WANTS)" && wants=shutdown.target && dir=$(systemunitdir) && $(add-wants)
258         what="$(LOCAL_FS_TARGET_WANTS)" && wants=local-fs.target && dir=$(systemunitdir) && $(add-wants)
259         what="$(MULTI_USER_TARGET_WANTS)" && wants=multi-user.target && dir=$(systemunitdir) && $(add-wants)
260         what="$(SYSINIT_TARGET_WANTS)" && wants=sysinit.target && dir=$(systemunitdir) && $(add-wants)
261         what="$(SOCKETS_TARGET_WANTS)" && wants=sockets.target && dir=$(systemunitdir) && $(add-wants)
262         what="$(BUSNAMES_TARGET_WANTS)" && wants=busnames.target && dir=$(systemunitdir) && $(add-wants)
263         what="$(TIMERS_TARGET_WANTS)" && wants=timers.target && dir=$(systemunitdir) && $(add-wants)
264         what="$(SLICES_TARGET_WANTS)" && wants=slices.target && dir=$(systemunitdir) && $(add-wants)
265         what="$(USER_SOCKETS_TARGET_WANTS)" && wants=sockets.target && dir=$(userunitdir) && $(add-wants)
266         what="$(USER_BUSNAMES_TARGET_WANTS)" && wants=busnames.target && dir=$(userunitdir) && $(add-wants)
267
268 define add-wants
269         [ -z "$$what" ] || ( \
270           dir=$(DESTDIR)$$dir/$$wants.wants && \
271           $(MKDIR_P) -m 0755 $$dir && \
272           cd $$dir && \
273           rm -f $$what && \
274           for i in $$what; do $(LN_S) ../$$i . || exit $$? ; done )
275 endef
276
277 install-directories-hook:
278         $(MKDIR_P) $(addprefix $(DESTDIR),$(INSTALL_DIRS))
279
280 install-aliases-hook:
281         set -- $(SYSTEM_UNIT_ALIASES) && \
282                 dir=$(systemunitdir) && $(install-aliases)
283         set -- $(USER_UNIT_ALIASES) && \
284                 dir=$(userunitdir) && $(install-relative-aliases)
285         set -- $(GENERAL_ALIASES) && \
286                 dir= && $(install-relative-aliases)
287
288 define install-aliases
289         while [ -n "$$1" ]; do \
290                 $(MKDIR_P) `dirname $(DESTDIR)$$dir/$$2` && \
291                 rm -f $(DESTDIR)$$dir/$$2 && \
292                 $(LN_S) $$1 $(DESTDIR)$$dir/$$2 && \
293                 shift 2 || exit $$?; \
294         done
295 endef
296
297 define install-relative-aliases
298         while [ -n "$$1" ]; do \
299                 $(MKDIR_P) `dirname $(DESTDIR)$$dir/$$2` && \
300                 rm -f $(DESTDIR)$$dir/$$2 && \
301                 $(LN_S) --relative $(DESTDIR)$$1 $(DESTDIR)$$dir/$$2 && \
302                 shift 2 || exit $$?; \
303         done
304 endef
305
306 install-touch-usr-hook:
307         touch -c $(DESTDIR)/$(prefix)
308
309 INSTALL_EXEC_HOOKS += \
310         install-target-wants-hook \
311         install-directories-hook \
312         install-aliases-hook \
313         install-touch-usr-hook
314
315 # ------------------------------------------------------------------------------
316 AM_V_M4 = $(AM_V_M4_$(V))
317 AM_V_M4_ = $(AM_V_M4_$(AM_DEFAULT_VERBOSITY))
318 AM_V_M4_0 = @echo "  M4      " $@;
319
320 AM_V_XSLT = $(AM_V_XSLT_$(V))
321 AM_V_XSLT_ = $(AM_V_XSLT_$(AM_DEFAULT_VERBOSITY))
322 AM_V_XSLT_0 = @echo "  XSLT    " $@;
323
324 AM_V_GPERF = $(AM_V_GPERF_$(V))
325 AM_V_GPERF_ = $(AM_V_GPERF_$(AM_DEFAULT_VERBOSITY))
326 AM_V_GPERF_0 = @echo "  GPERF   " $@;
327
328 AM_V_LN = $(AM_V_LN_$(V))
329 AM_V_LN_ = $(AM_V_LN_$(AM_DEFAULT_VERBOSITY))
330 AM_V_LN_0 = @echo "  LN      " $@;
331
332 AM_V_RM = $(AM_V_RM_$(V))
333 AM_V_RM_ = $(AM_V_RM_$(AM_DEFAULT_VERBOSITY))
334 AM_V_RM_0 = @echo "  RM      " $@;
335
336 # ------------------------------------------------------------------------------
337 rootbin_PROGRAMS = \
338         systemctl \
339         systemd-notify \
340         systemd-ask-password \
341         systemd-tty-ask-password-agent \
342         systemd-machine-id-setup \
343         systemd-escape
344
345 bin_PROGRAMS = \
346         systemd-cgls \
347         systemd-cgtop \
348         systemd-nspawn \
349         systemd-detect-virt \
350         systemd-delta \
351         systemd-analyze \
352         systemd-run \
353         systemd-path \
354         systemd-verify
355
356 dist_bin_SCRIPTS = \
357         src/kernel-install/kernel-install
358
359 dist_kernelinstall_SCRIPTS = \
360         src/kernel-install/50-depmod.install \
361         src/kernel-install/90-loaderentry.install
362
363 rootlibexec_PROGRAMS = \
364         systemd \
365         systemd-cgroups-agent \
366         systemd-initctl \
367         systemd-update-utmp \
368         systemd-shutdownd \
369         systemd-shutdown \
370         systemd-remount-fs \
371         systemd-reply-password \
372         systemd-fsck \
373         systemd-ac-power \
374         systemd-sysctl \
375         systemd-sleep \
376         systemd-bus-proxyd \
377         systemd-socket-proxyd \
378         systemd-update-done
379
380 systemgenerator_PROGRAMS = \
381         systemd-getty-generator \
382         systemd-fstab-generator \
383         systemd-system-update-generator \
384         systemd-debug-generator
385
386 dist_bashcompletion_DATA = \
387         shell-completion/bash/busctl \
388         shell-completion/bash/journalctl \
389         shell-completion/bash/systemd-analyze \
390         shell-completion/bash/systemd-cat \
391         shell-completion/bash/systemd-cgls \
392         shell-completion/bash/systemd-cgtop \
393         shell-completion/bash/systemd-delta \
394         shell-completion/bash/systemd-detect-virt \
395         shell-completion/bash/systemd-nspawn \
396         shell-completion/bash/systemd-run \
397         shell-completion/bash/udevadm \
398         shell-completion/bash/kernel-install
399
400 nodist_bashcompletion_DATA = \
401         shell-completion/bash/systemctl
402
403 dist_zshcompletion_DATA = \
404         shell-completion/zsh/_journalctl \
405         shell-completion/zsh/_udevadm \
406         shell-completion/zsh/_kernel-install \
407         shell-completion/zsh/_systemd-nspawn \
408         shell-completion/zsh/_systemd-analyze \
409         shell-completion/zsh/_systemd-run \
410         shell-completion/zsh/_sd_hosts_or_user_at_host \
411         shell-completion/zsh/_systemd-delta \
412         shell-completion/zsh/_systemd
413
414 nodist_zshcompletion_DATA = \
415         shell-completion/zsh/_systemctl
416
417 EXTRA_DIST += \
418         shell-completion/bash/systemctl.in \
419         shell-completion/zsh/_systemctl.in
420
421 CLEANFILES += \
422         $(nodist_bashcompletion_DATA) \
423         $(nodist_zshcompletion_DATA)
424
425 dist_sysctl_DATA = \
426         sysctl.d/50-default.conf
427
428 dist_systemunit_DATA = \
429         units/graphical.target \
430         units/multi-user.target \
431         units/emergency.target \
432         units/sysinit.target \
433         units/basic.target \
434         units/getty.target \
435         units/halt.target \
436         units/kexec.target \
437         units/local-fs.target \
438         units/local-fs-pre.target \
439         units/initrd.target \
440         units/initrd-fs.target \
441         units/initrd-root-fs.target \
442         units/remote-fs.target \
443         units/remote-fs-pre.target \
444         units/network.target \
445         units/network-pre.target \
446         units/network-online.target \
447         units/nss-lookup.target \
448         units/nss-user-lookup.target \
449         units/hibernate.target \
450         units/hybrid-sleep.target \
451         units/poweroff.target \
452         units/reboot.target \
453         units/rescue.target \
454         units/rpcbind.target \
455         units/time-sync.target \
456         units/shutdown.target \
457         units/final.target \
458         units/umount.target \
459         units/sigpwr.target \
460         units/sleep.target \
461         units/sockets.target \
462         units/busnames.target \
463         units/timers.target \
464         units/paths.target \
465         units/suspend.target \
466         units/swap.target \
467         units/slices.target \
468         units/system.slice \
469         units/x-.slice \
470         units/systemd-initctl.socket \
471         units/systemd-shutdownd.socket \
472         units/syslog.socket \
473         units/dev-hugepages.mount \
474         units/dev-mqueue.mount \
475         units/sys-kernel-config.mount \
476         units/sys-kernel-debug.mount \
477         units/sys-fs-fuse-connections.mount \
478         units/tmp.mount \
479         units/printer.target \
480         units/sound.target \
481         units/bluetooth.target \
482         units/smartcard.target \
483         units/systemd-ask-password-wall.path \
484         units/systemd-ask-password-console.path \
485         units/systemd-udevd-control.socket \
486         units/systemd-udevd-kernel.socket \
487         units/system-update.target \
488         units/initrd-switch-root.target \
489         units/ldconfig.service
490
491 nodist_systemunit_DATA = \
492         units/getty@.service \
493         units/serial-getty@.service \
494         units/console-shell.service \
495         units/console-getty.service \
496         units/container-getty@.service \
497         units/systemd-initctl.service \
498         units/systemd-shutdownd.service \
499         units/systemd-remount-fs.service \
500         units/systemd-update-utmp.service \
501         units/systemd-update-utmp-runlevel.service \
502         units/systemd-ask-password-wall.service \
503         units/systemd-ask-password-console.service \
504         units/systemd-sysctl.service \
505         units/emergency.service \
506         units/rescue.service \
507         units/user@.service \
508         units/systemd-hibernate.service \
509         units/systemd-hybrid-sleep.service \
510         units/systemd-suspend.service \
511         units/systemd-halt.service \
512         units/systemd-poweroff.service \
513         units/systemd-reboot.service \
514         units/systemd-kexec.service \
515         units/systemd-fsck@.service \
516         units/systemd-fsck-root.service \
517         units/systemd-udevd.service \
518         units/systemd-udev-trigger.service \
519         units/systemd-udev-settle.service \
520         units/systemd-udev-hwdb-update.service \
521         units/debug-shell.service \
522         units/initrd-parse-etc.service \
523         units/initrd-cleanup.service \
524         units/initrd-udevadm-cleanup-db.service \
525         units/initrd-switch-root.service \
526         units/systemd-nspawn@.service \
527         units/systemd-update-done.service
528
529 dist_userunit_DATA = \
530         units/user/basic.target \
531         units/user/default.target \
532         units/user/exit.target
533
534 nodist_userunit_DATA = \
535         units/user/systemd-exit.service
536
537 dist_systempreset_DATA = \
538         system-preset/90-systemd.preset
539
540 EXTRA_DIST += \
541         units/getty@.service.m4 \
542         units/serial-getty@.service.m4 \
543         units/console-shell.service.m4.in \
544         units/console-getty.service.m4.in \
545         units/container-getty@.service.m4.in \
546         units/rescue.service.m4.in \
547         units/systemd-initctl.service.in \
548         units/systemd-shutdownd.service.in \
549         units/systemd-remount-fs.service.in \
550         units/systemd-update-utmp.service.in \
551         units/systemd-update-utmp-runlevel.service.in \
552         units/systemd-ask-password-wall.service.in \
553         units/systemd-ask-password-console.service.in \
554         units/systemd-sysctl.service.in \
555         units/emergency.service.in \
556         units/systemd-halt.service.in \
557         units/systemd-poweroff.service.in \
558         units/systemd-reboot.service.in \
559         units/systemd-kexec.service.in \
560         units/user/systemd-exit.service.in \
561         units/systemd-fsck@.service.in \
562         units/systemd-fsck-root.service.in \
563         units/user@.service.in \
564         units/debug-shell.service.in \
565         units/systemd-hibernate.service.in \
566         units/systemd-hybrid-sleep.service.in \
567         units/systemd-suspend.service.in \
568         units/quotaon.service.in \
569         units/initrd-parse-etc.service.in \
570         units/initrd-cleanup.service.in \
571         units/initrd-udevadm-cleanup-db.service.in \
572         units/initrd-switch-root.service.in \
573         units/systemd-nspawn@.service.in \
574         units/systemd-update-done.service.in
575
576 CLEANFILES += \
577         units/console-shell.service.m4 \
578         units/console-getty.service.m4 \
579         units/container-getty@.service.m4 \
580         units/rescue.service.m4 \
581         units/user@.service.m4
582
583 if HAVE_SYSV_COMPAT
584 nodist_systemunit_DATA += \
585         units/rc-local.service \
586         units/halt-local.service
587
588 systemgenerator_PROGRAMS += \
589         systemd-sysv-generator \
590         systemd-rc-local-generator
591 endif
592
593 EXTRA_DIST += \
594         units/rc-local.service.in \
595         units/halt-local.service.in
596
597 # automake is broken and can't handle files with a dash in front
598 # http://debbugs.gnu.org/cgi/bugreport.cgi?bug=14728#8
599 units-install-hook:
600         mv $(DESTDIR)$(systemunitdir)/x-.slice $(DESTDIR)/$(systemunitdir)/-.slice
601
602 units-uninstall-hook:
603         rm -f $(DESTDIR)/$(systemunitdir)/-.slice
604
605 INSTALL_DATA_HOOKS += units-install-hook
606 UNINSTALL_DATA_HOOKS += units-uninstall-hook
607
608 dist_doc_DATA = \
609         README \
610         NEWS \
611         LICENSE.LGPL2.1 \
612         LICENSE.GPL2 \
613         LICENSE.MIT \
614         DISTRO_PORTING \
615         src/libsystemd/sd-bus/PORTING-DBUS1 \
616         src/libsystemd/sd-bus/DIFFERENCES \
617         src/libsystemd/sd-bus/GVARIANT-SERIALIZATION
618
619 @INTLTOOL_POLICY_RULE@
620
621 # ------------------------------------------------------------------------------
622
623 MANPAGES =
624 MANPAGES_ALIAS =
625
626 include Makefile-man.am
627
628 .PHONY: man update-man-list
629 man: $(MANPAGES) $(MANPAGES_ALIAS) $(HTML_FILES) $(HTML_ALIAS)
630
631 XML_FILES = \
632         ${patsubst %.1,%.xml,${patsubst %.3,%.xml,${patsubst %.5,%.xml,${patsubst %.7,%.xml,${patsubst %.8,%.xml,$(MANPAGES)}}}}}
633 HTML_FILES = \
634         ${XML_FILES:.xml=.html}
635 HTML_ALIAS = \
636         ${patsubst %.1,%.html,${patsubst %.3,%.html,${patsubst %.5,%.html,${patsubst %.7,%.html,${patsubst %.8,%.html,$(MANPAGES_ALIAS)}}}}}
637
638 if ENABLE_MANPAGES
639 man_MANS = \
640         $(MANPAGES) \
641         $(MANPAGES_ALIAS)
642
643 noinst_DATA += \
644         $(HTML_FILES) \
645         $(HTML_ALIAS)
646
647 CLEANFILES += \
648         $(man_MANS) \
649         $(HTML_FILES) \
650         $(HTML_ALIAS)
651
652 docs/html/man:
653         $(AM_V_at)$(MKDIR_P) $(dir $@)
654         $(AM_V_LN)$(LN_S) -f ../../man $@
655
656 noinst_DATA += \
657         docs/html/man
658
659 CLEANFILES += \
660         docs/html/man
661
662 if HAVE_PYTHON
663 man/index.html: man/systemd.index.html
664         $(AM_V_LN)$(LN_S) -f systemd.index.html $@
665
666 noinst_DATA += \
667         man/index.html
668
669 CLEANFILES += \
670         man/index.html
671
672 XML_GLOB = $(wildcard $(top_srcdir)/man/*.xml $(top_builddir)/man/*.xml)
673 NON_INDEX_XML_FILES = $(filter-out man/systemd.index.xml,$(XML_FILES))
674 SOURCE_XML_FILES = $(filter-out man/systemd.directives.xml,$(NON_INDEX_XML_FILES))
675
676 update-man-list: $(top_srcdir)/tools/make-man-rules.py $(XML_GLOB)
677         $(AM_V_GEN)$(PYTHON) $^ > $(top_srcdir)/Makefile-man.tmp
678         $(AM_V_at)mv $(top_srcdir)/Makefile-man.tmp $(top_srcdir)/Makefile-man.am
679         @echo "Makefile-man.am has been regenerated"
680
681 man/systemd.index.xml: $(top_srcdir)/tools/make-man-index.py $(NON_INDEX_XML_FILES)
682         $(AM_V_at)$(MKDIR_P) $(dir $@)
683         $(AM_V_GEN)$(PYTHON) $< $@ $(filter-out $<,$^)
684
685 man/systemd.directives.xml: $(top_srcdir)/tools/make-directive-index.py $(SOURCE_XML_FILES)
686         $(AM_V_at)$(MKDIR_P) $(dir $@)
687         $(AM_V_GEN)$(PYTHON) $< $@ $(filter-out $<,$^)
688
689 EXTRA_DIST += \
690         man/systemd.index.xml \
691         man/index.html \
692         man/systemd.directives.xml
693
694 CLEANFILES += \
695         man/systemd.index.xml \
696         man/systemd.directives.xml
697
698 endif
699
700 endif
701
702 EXTRA_DIST += \
703         $(XML_FILES) \
704         $(HTML_FILES) \
705         $(HTML_ALIAS) \
706         $(man_MANS) \
707         tools/make-man-index.py \
708         tools/make-directive-index.py \
709         tools/make-man-rules.py \
710         tools/xml_helper.py
711
712 # ------------------------------------------------------------------------------
713 noinst_LTLIBRARIES += \
714         libsystemd-shared.la
715
716 libsystemd_shared_la_SOURCES = \
717         src/shared/linux/auto_dev-ioctl.h \
718         src/shared/linux/fanotify.h \
719         src/shared/ioprio.h \
720         src/shared/missing.h \
721         src/shared/initreq.h \
722         src/shared/securebits.h \
723         src/shared/special.h \
724         src/shared/list.h \
725         src/shared/macro.h \
726         src/shared/def.h \
727         src/shared/sparse-endian.h \
728         src/shared/refcnt.h \
729         src/shared/udev-util.h \
730         src/shared/bus-errors.h \
731         src/shared/device-nodes.c \
732         src/shared/device-nodes.h \
733         src/shared/util.c \
734         src/shared/util.h \
735         src/shared/virt.c \
736         src/shared/virt.h \
737         src/shared/architecture.c \
738         src/shared/architecture.h \
739         src/shared/efivars.c \
740         src/shared/efivars.h \
741         src/shared/path-util.c \
742         src/shared/path-util.h \
743         src/shared/time-util.c \
744         src/shared/time-util.h \
745         src/shared/locale-util.c \
746         src/shared/locale-util.h \
747         src/shared/hashmap.c \
748         src/shared/hashmap.h \
749         src/shared/siphash24.c \
750         src/shared/siphash24.h \
751         src/shared/set.c \
752         src/shared/set.h \
753         src/shared/fdset.c \
754         src/shared/fdset.h \
755         src/shared/prioq.c \
756         src/shared/prioq.h \
757         src/shared/sleep-config.c \
758         src/shared/sleep-config.h \
759         src/shared/strv.c \
760         src/shared/strv.h \
761         src/shared/env-util.c \
762         src/shared/env-util.h \
763         src/shared/strbuf.c \
764         src/shared/strbuf.h \
765         src/shared/strxcpyx.c \
766         src/shared/strxcpyx.h \
767         src/shared/conf-parser.c \
768         src/shared/conf-parser.h \
769         src/shared/log.c \
770         src/shared/log.h \
771         src/shared/ratelimit.h \
772         src/shared/ratelimit.c \
773         src/shared/exit-status.c \
774         src/shared/exit-status.h \
775         src/shared/utf8.c \
776         src/shared/utf8.h \
777         src/shared/gunicode.c \
778         src/shared/gunicode.h \
779         src/shared/pager.c \
780         src/shared/pager.h \
781         src/shared/socket-util.c \
782         src/shared/socket-util.h \
783         src/shared/in-addr-util.c \
784         src/shared/in-addr-util.h \
785         src/shared/conf-files.c \
786         src/shared/conf-files.h \
787         src/shared/cgroup-util.c \
788         src/shared/cgroup-util.h \
789         src/shared/cgroup-show.c \
790         src/shared/cgroup-show.h \
791         src/shared/unit-name.c \
792         src/shared/unit-name.h \
793         src/shared/utmp-wtmp.c \
794         src/shared/utmp-wtmp.h \
795         src/shared/watchdog.c \
796         src/shared/watchdog.h \
797         src/shared/spawn-ask-password-agent.c \
798         src/shared/spawn-ask-password-agent.h \
799         src/shared/replace-var.c \
800         src/shared/replace-var.h \
801         src/shared/spawn-polkit-agent.c \
802         src/shared/spawn-polkit-agent.h \
803         src/shared/clock-util.c \
804         src/shared/clock-util.h \
805         src/shared/time-dst.c \
806         src/shared/time-dst.h \
807         src/shared/calendarspec.c \
808         src/shared/calendarspec.h \
809         src/shared/fileio.c \
810         src/shared/fileio.h \
811         src/shared/output-mode.h \
812         src/shared/MurmurHash2.c \
813         src/shared/MurmurHash2.h \
814         src/shared/acpi-fpdt.h \
815         src/shared/acpi-fpdt.c \
816         src/shared/boot-timestamps.h \
817         src/shared/boot-timestamps.c \
818         src/shared/mkdir.c \
819         src/shared/mkdir.h \
820         src/shared/smack-util.c \
821         src/shared/smack-util.h \
822         src/shared/apparmor-util.c \
823         src/shared/apparmor-util.h \
824         src/shared/ima-util.c \
825         src/shared/ima-util.h \
826         src/shared/ptyfwd.c \
827         src/shared/ptyfwd.h \
828         src/shared/errno-list.c \
829         src/shared/errno-list.h \
830         src/shared/af-list.c \
831         src/shared/af-list.h \
832         src/shared/audit.c \
833         src/shared/audit.h \
834         src/shared/xml.c \
835         src/shared/xml.h \
836         src/shared/condition-util.c \
837         src/shared/condition-util.h \
838         src/shared/bus-label.c \
839         src/shared/bus-label.h \
840         src/shared/gpt.h \
841         src/shared/clean-ipc.h \
842         src/shared/clean-ipc.c \
843         src/shared/login-shared.c \
844         src/shared/login-shared.h \
845         src/shared/ring.c \
846         src/shared/ring.h \
847         src/shared/barrier.c \
848         src/shared/barrier.h \
849         src/shared/pty.c \
850         src/shared/pty.h \
851         src/shared/async.c \
852         src/shared/async.h \
853         src/shared/copy.c \
854         src/shared/copy.h \
855         src/shared/base-filesystem.c \
856         src/shared/base-filesystem.h \
857         src/shared/nss-util.h
858
859 nodist_libsystemd_shared_la_SOURCES = \
860         src/shared/errno-from-name.h \
861         src/shared/errno-to-name.h \
862         src/shared/af-from-name.h \
863         src/shared/af-to-name.h
864
865 libsystemd_shared_la_CFLAGS = \
866         $(AM_CFLAGS) \
867         $(SECCOMP_CFLAGS) \
868         -pthread
869
870 # ------------------------------------------------------------------------------
871 noinst_LTLIBRARIES += \
872         libsystemd-units.la
873
874 libsystemd_units_la_SOURCES = \
875         src/shared/install.c \
876         src/shared/install.h \
877         src/shared/install-printf.c \
878         src/shared/install-printf.h \
879         src/shared/path-lookup.c \
880         src/shared/path-lookup.h \
881         src/shared/specifier.c \
882         src/shared/specifier.h
883
884 # ------------------------------------------------------------------------------
885 noinst_LTLIBRARIES += \
886         libsystemd-label.la
887
888 libsystemd_label_la_SOURCES = \
889         src/shared/socket-label.c \
890         src/shared/label.c \
891         src/shared/label.h \
892         src/shared/selinux-util.c \
893         src/shared/selinux-util.h \
894         src/shared/mkdir-label.c \
895         src/shared/ask-password-api.c \
896         src/shared/ask-password-api.h \
897         src/shared/fileio-label.c \
898         src/shared/fileio-label.h \
899         src/shared/dev-setup.c \
900         src/shared/dev-setup.h \
901         src/shared/dropin.c \
902         src/shared/dropin.h \
903         src/shared/generator.h \
904         src/shared/generator.c
905
906 libsystemd_label_la_CFLAGS = \
907         $(AM_CFLAGS) \
908         $(SELINUX_CFLAGS)
909
910 libsystemd_label_la_LIBADD = \
911         $(SELINUX_LIBS)
912
913 # ------------------------------------------------------------------------------
914
915 if HAVE_SECCOMP
916 noinst_LTLIBRARIES += \
917         libsystemd-seccomp.la
918
919 libsystemd_seccomp_la_SOURCES = \
920         src/shared/seccomp-util.h \
921         src/shared/seccomp-util.c
922
923 libsystemd_seccomp_la_CFLAGS = \
924         $(AM_CFLAGS) \
925         $(SECCOMP_CFLAGS)
926
927 libsystemd_seccomp_la_LIBADD = \
928         $(SECCOMP_LIBS)
929 endif
930
931 # ------------------------------------------------------------------------------
932 noinst_LTLIBRARIES += \
933         libsystemd-logs.la
934
935 libsystemd_logs_la_SOURCES = \
936         src/shared/logs-show.c \
937         src/shared/logs-show.h
938
939 # ------------------------------------------------------------------------------
940 noinst_LTLIBRARIES += \
941         libsystemd-capability.la
942
943 libsystemd_capability_la_SOURCES = \
944         src/shared/capability.c \
945         src/shared/capability.h
946
947 libsystemd_capability_la_CFLAGS = \
948         $(AM_CFLAGS) \
949         $(CAP_CFLAGS)
950
951 libsystemd_capability_la_LIBADD = \
952         $(CAP_LIBS)
953
954 # ------------------------------------------------------------------------------
955 if HAVE_ACL
956 noinst_LTLIBRARIES += \
957         libsystemd-acl.la
958
959 libsystemd_acl_la_SOURCES = \
960         src/shared/acl-util.c \
961         src/shared/acl-util.h
962
963 libsystemd_acl_la_CFLAGS = \
964         $(AM_CFLAGS) \
965         $(ACL_CFLAGS)
966
967 libsystemd_acl_la_LIBADD = \
968         $(ACL_LIBS)
969 endif
970
971 # ------------------------------------------------------------------------------
972 noinst_LTLIBRARIES += \
973         libsystemd-core.la
974
975 libsystemd_core_la_SOURCES = \
976         src/core/unit.c \
977         src/core/unit.h \
978         src/core/unit-printf.c \
979         src/core/unit-printf.h \
980         src/core/job.c \
981         src/core/job.h \
982         src/core/manager.c \
983         src/core/manager.h \
984         src/core/transaction.c \
985         src/core/transaction.h \
986         src/core/load-fragment.c \
987         src/core/load-fragment.h \
988         src/core/service.c \
989         src/core/service.h \
990         src/core/socket.c \
991         src/core/socket.h \
992         src/core/busname.c \
993         src/core/busname.h \
994         src/core/target.c \
995         src/core/target.h \
996         src/core/snapshot.c \
997         src/core/snapshot.h \
998         src/core/device.c \
999         src/core/device.h \
1000         src/core/mount.c \
1001         src/core/mount.h \
1002         src/core/automount.c \
1003         src/core/automount.h \
1004         src/core/swap.c \
1005         src/core/swap.h \
1006         src/core/timer.c \
1007         src/core/timer.h \
1008         src/core/path.c \
1009         src/core/path.h \
1010         src/core/slice.c \
1011         src/core/slice.h \
1012         src/core/scope.c \
1013         src/core/scope.h \
1014         src/core/load-dropin.c \
1015         src/core/load-dropin.h \
1016         src/core/execute.c \
1017         src/core/execute.h \
1018         src/core/kill.c \
1019         src/core/kill.h \
1020         src/core/dbus.c \
1021         src/core/dbus.h \
1022         src/core/dbus-manager.c \
1023         src/core/dbus-manager.h \
1024         src/core/dbus-unit.c \
1025         src/core/dbus-unit.h \
1026         src/core/dbus-job.c \
1027         src/core/dbus-job.h \
1028         src/core/dbus-service.c \
1029         src/core/dbus-service.h \
1030         src/core/dbus-socket.c \
1031         src/core/dbus-socket.h \
1032         src/core/dbus-busname.c \
1033         src/core/dbus-busname.h \
1034         src/core/dbus-target.c \
1035         src/core/dbus-target.h \
1036         src/core/dbus-snapshot.c \
1037         src/core/dbus-snapshot.h \
1038         src/core/dbus-device.c \
1039         src/core/dbus-device.h \
1040         src/core/dbus-mount.c \
1041         src/core/dbus-mount.h \
1042         src/core/dbus-automount.c \
1043         src/core/dbus-automount.h \
1044         src/core/dbus-swap.c \
1045         src/core/dbus-swap.h \
1046         src/core/dbus-timer.c \
1047         src/core/dbus-timer.h \
1048         src/core/dbus-path.c \
1049         src/core/dbus-path.h \
1050         src/core/dbus-slice.c \
1051         src/core/dbus-slice.h \
1052         src/core/dbus-scope.c \
1053         src/core/dbus-scope.h \
1054         src/core/dbus-execute.c \
1055         src/core/dbus-execute.h \
1056         src/core/dbus-kill.c \
1057         src/core/dbus-kill.h \
1058         src/core/dbus-cgroup.c \
1059         src/core/dbus-cgroup.h \
1060         src/core/cgroup.c \
1061         src/core/cgroup.h \
1062         src/core/selinux-access.c \
1063         src/core/selinux-access.h \
1064         src/core/selinux-setup.c \
1065         src/core/selinux-setup.h \
1066         src/core/smack-setup.c \
1067         src/core/smack-setup.h \
1068         src/core/ima-setup.c \
1069         src/core/ima-setup.h \
1070         src/core/locale-setup.h \
1071         src/core/locale-setup.c \
1072         src/core/hostname-setup.c \
1073         src/core/hostname-setup.h \
1074         src/core/machine-id-setup.c \
1075         src/core/machine-id-setup.h \
1076         src/core/mount-setup.c \
1077         src/core/mount-setup.h \
1078         src/core/loopback-setup.h \
1079         src/core/loopback-setup.c \
1080         src/core/condition.c \
1081         src/core/condition.h \
1082         src/core/namespace.c \
1083         src/core/namespace.h \
1084         src/core/build.h \
1085         src/core/sysfs-show.h \
1086         src/core/switch-root.h \
1087         src/core/switch-root.c \
1088         src/core/killall.h \
1089         src/core/killall.c \
1090         src/core/audit-fd.c \
1091         src/core/audit-fd.h \
1092         src/core/show-status.c \
1093         src/core/show-status.h
1094
1095 if HAVE_KMOD
1096 libsystemd_core_la_SOURCES += \
1097         src/core/kmod-setup.c \
1098         src/core/kmod-setup.h
1099 endif
1100
1101 nodist_libsystemd_core_la_SOURCES = \
1102         src/core/load-fragment-gperf.c \
1103         src/core/load-fragment-gperf-nulstr.c
1104
1105 libsystemd_core_la_CFLAGS = \
1106         $(AM_CFLAGS) \
1107         $(PAM_CFLAGS) \
1108         $(AUDIT_CFLAGS) \
1109         $(CAP_CFLAGS) \
1110         $(KMOD_CFLAGS) \
1111         $(APPARMOR_CFLAGS) \
1112         $(SECCOMP_CFLAGS) \
1113         -pthread
1114
1115 libsystemd_core_la_LIBADD = \
1116         libsystemd-capability.la \
1117         libsystemd-units.la \
1118         libsystemd-label.la \
1119         libudev-internal.la \
1120         libsystemd-shared.la \
1121         libsystemd-internal.la \
1122         $(PAM_LIBS) \
1123         $(AUDIT_LIBS) \
1124         $(CAP_LIBS) \
1125         $(KMOD_LIBS) \
1126         $(APPARMOR_LIBS) \
1127         $(SECCOMP_LIBS)
1128
1129 if HAVE_SECCOMP
1130 libsystemd_core_la_LIBADD += \
1131         libsystemd-seccomp.la
1132 endif
1133
1134 src/core/load-fragment-gperf-nulstr.c: src/core/load-fragment-gperf.gperf
1135         $(AM_V_at)$(MKDIR_P) $(dir $@)
1136         $(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 ";" }' < $< > $@
1137
1138 EXTRA_DIST += \
1139         src/core/load-fragment-gperf.gperf.m4
1140
1141 CLEANFILES += \
1142         src/core/load-fragment-gperf.gperf \
1143         src/core/load-fragment-gperf.c \
1144         src/core/load-fragment-gperf-nulstr.c \
1145         src/shared/errno-list.txt \
1146         src/shared/errno-from-name.gperf \
1147         src/shared/af-list.txt \
1148         src/shared/af-from-name.gperf
1149
1150 BUILT_SOURCES += \
1151         src/shared/errno-from-name.h \
1152         src/shared/errno-to-name.h \
1153         src/shared/af-from-name.h \
1154         src/shared/af-to-name.h
1155
1156 src/shared/errno-list.txt:
1157         $(AM_V_at)$(MKDIR_P) $(dir $@)
1158         $(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM -include errno.h - < /dev/null | $(AWK) '/^#define[ \t]+E[^ _]+[ \t]+/ { print $$2; }'  > $@
1159
1160 src/shared/errno-from-name.gperf: src/shared/errno-list.txt
1161         $(AM_V_at)$(MKDIR_P) $(dir $@)
1162         $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct errno_name { const char* name; int id; };"; print "%null-strings"; print "%%";} { printf "%s, %s\n", $$1, $$1 }' < $< > $@
1163
1164 src/shared/errno-from-name.h: src/shared/errno-from-name.gperf
1165         $(AM_V_at)$(MKDIR_P) $(dir $@)
1166         $(AM_V_GPERF)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_errno -H hash_errno_name -p -C < $< > $@
1167
1168 src/shared/errno-to-name.h: src/shared/errno-list.txt
1169         $(AM_V_at)$(MKDIR_P) $(dir $@)
1170         $(AM_V_GEN)$(AWK) 'BEGIN{ print "static const char* const errno_names[] = { "} !/EDEADLOCK/ && !/EWOULDBLOCK/ && !/ENOTSUP/ { printf "[%s] = \"%s\",\n", $$1, $$1 } END{print "};"}' < $< > $@
1171
1172 src/shared/af-list.txt:
1173         $(AM_V_at)$(MKDIR_P) $(dir $@)
1174         $(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; }'  > $@
1175
1176 src/shared/af-from-name.gperf: src/shared/af-list.txt
1177         $(AM_V_at)$(MKDIR_P) $(dir $@)
1178         $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct af_name { const char* name; int id; };"; print "%null-strings"; print "%%";} { printf "%s, %s\n", $$1, $$1 }' < $< > $@
1179
1180 src/shared/af-from-name.h: src/shared/af-from-name.gperf
1181         $(AM_V_at)$(MKDIR_P) $(dir $@)
1182         $(AM_V_GPERF)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_af -H hash_af_name -p -C < $< > $@
1183
1184 src/shared/af-to-name.h: src/shared/af-list.txt
1185         $(AM_V_at)$(MKDIR_P) $(dir $@)
1186         $(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 "};"}' < $< > $@
1187
1188 # ------------------------------------------------------------------------------
1189 systemd_SOURCES = \
1190         src/core/main.c
1191
1192 systemd_CFLAGS = \
1193         $(AM_CFLAGS) \
1194         $(SECCOMP_CFLAGS)
1195
1196 systemd_LDADD = \
1197         libsystemd-core.la \
1198         $(RT_LIBS)
1199
1200 dist_pkgsysconf_DATA += \
1201         src/core/system.conf \
1202         src/core/user.conf
1203
1204 dist_dbuspolicy_DATA += \
1205         src/core/org.freedesktop.systemd1.conf
1206
1207 dist_dbussystemservice_DATA += \
1208         src/core/org.freedesktop.systemd1.service
1209
1210 polkitpolicy_in_in_files += \
1211         src/core/org.freedesktop.systemd1.policy.in.in
1212
1213 pkgconfigdata_DATA = \
1214         src/core/systemd.pc
1215
1216 nodist_rpmmacros_DATA = \
1217         src/core/macros.systemd
1218
1219 EXTRA_DIST += \
1220         src/core/systemd.pc.in \
1221         src/core/macros.systemd.in
1222
1223 CLEANFILES += \
1224         src/core/macros.systemd \
1225         src/core/org.freedesktop.systemd1.policy.in
1226
1227 # ------------------------------------------------------------------------------
1228
1229 systemd_verify_SOURCES = \
1230         src/verify/verify.c
1231
1232 systemd_verify_CFLAGS = \
1233         $(AM_CFLAGS) \
1234         $(SECCOMP_CFLAGS)
1235
1236 systemd_verify_LDADD = \
1237         libsystemd-core.la \
1238         $(RT_LIBS)
1239
1240 # ------------------------------------------------------------------------------
1241
1242 manual_tests += \
1243         test-ns \
1244         test-loopback \
1245         test-hostname \
1246         test-daemon \
1247         test-cgroup \
1248         test-install \
1249         test-watchdog \
1250         test-log \
1251         test-ipcrm
1252
1253 if HAVE_KMOD
1254 manual_tests += \
1255         test-rtnl-manual
1256 endif
1257
1258 tests += \
1259         test-engine \
1260         test-cgroup-mask \
1261         test-job-type \
1262         test-env-replace \
1263         test-strbuf \
1264         test-strv \
1265         test-path-util \
1266         test-strxcpyx \
1267         test-unit-name \
1268         test-unit-file \
1269         test-utf8 \
1270         test-ellipsize \
1271         test-util \
1272         test-ring \
1273         test-barrier \
1274         test-pty \
1275         test-tmpfiles \
1276         test-namespace \
1277         test-date \
1278         test-sleep \
1279         test-replace-var \
1280         test-sched-prio \
1281         test-calendarspec \
1282         test-strip-tab-ansi \
1283         test-cgroup-util \
1284         test-prioq \
1285         test-fileio \
1286         test-time \
1287         test-hashmap \
1288         test-list \
1289         test-tables \
1290         test-device-nodes \
1291         test-xml \
1292         test-architecture \
1293         test-socket-util \
1294         test-fdset \
1295         test-conf-files \
1296         test-capability \
1297         test-async \
1298         test-ratelimit
1299
1300 EXTRA_DIST += \
1301         test/sched_idle_bad.service \
1302         test/sched_idle_ok.service \
1303         test/sched_rr_bad.service \
1304         test/sched_rr_ok.service \
1305         test/sched_rr_change.service \
1306         test/son.service \
1307         test/daughter.service \
1308         test/parent.slice
1309
1310 EXTRA_DIST += \
1311         src/test/test-helper.h
1312
1313 test_device_nodes_SOURCES = \
1314         src/test/test-device-nodes.c
1315
1316 test_device_nodes_LDADD = \
1317         libsystemd-shared.la
1318
1319 test_engine_SOURCES = \
1320         src/test/test-engine.c
1321
1322 test_engine_CFLAGS = \
1323         $(AM_CFLAGS) \
1324         $(SECCOMP_CFLAGS)
1325
1326 test_engine_LDADD = \
1327         libsystemd-core.la \
1328         $(RT_LIBS)
1329
1330 test_job_type_SOURCES = \
1331         src/test/test-job-type.c
1332
1333 test_job_type_CFLAGS = \
1334         $(AM_CFLAGS) \
1335         $(SECCOMP_CFLAGS)
1336
1337 test_job_type_LDADD = \
1338         libsystemd-core.la \
1339         $(RT_LIBS)
1340
1341 test_ns_SOURCES = \
1342         src/test/test-ns.c
1343
1344 test_ns_CFLAGS = \
1345         $(AM_CFLAGS) \
1346         $(SECCOMP_CFLAGS)
1347
1348 test_ns_LDADD = \
1349         libsystemd-core.la
1350
1351 test_loopback_SOURCES = \
1352         src/test/test-loopback.c
1353
1354 test_loopback_LDADD = \
1355         libsystemd-core.la
1356
1357 test_hostname_SOURCES = \
1358         src/test/test-hostname.c
1359
1360 test_hostname_LDADD = \
1361         libsystemd-core.la
1362
1363 if ENABLE_EFI
1364 manual_tests += \
1365         test-boot-timestamp
1366
1367 test_boot_timestamp_SOURCES = \
1368         src/test/test-boot-timestamps.c
1369
1370 test_boot_timestamp_LDADD = \
1371         libsystemd-shared.la
1372 endif
1373
1374 test_unit_name_SOURCES = \
1375         src/test/test-unit-name.c
1376
1377 test_unit_name_CFLAGS = \
1378         $(AM_CFLAGS) \
1379         $(SECCOMP_CFLAGS)
1380
1381 test_unit_name_LDADD = \
1382         libsystemd-core.la \
1383         $(RT_LIBS)
1384
1385 test_unit_file_SOURCES = \
1386         src/test/test-unit-file.c
1387
1388 test_unit_file_CFLAGS = \
1389         $(AM_CFLAGS) \
1390         $(SECCOMP_CFLAGS)
1391
1392 test_unit_file_LDADD = \
1393         libsystemd-core.la \
1394         $(RT_LIBS)
1395
1396 test_utf8_SOURCES = \
1397         src/test/test-utf8.c
1398
1399 test_utf8_LDADD = \
1400         libsystemd-shared.la
1401
1402 test_capability_SOURCES = \
1403         src/test/test-capability.c
1404
1405 test_capability_LDADD = \
1406         libsystemd-shared.la \
1407         libsystemd-capability.la
1408
1409 test_async_SOURCES = \
1410         src/test/test-async.c
1411
1412 test_async_LDADD = \
1413         libsystemd-shared.la
1414
1415 test_fdset_SOURCES = \
1416         src/test/test-fdset.c
1417
1418 test_fdset_LDADD = \
1419         libsystemd-core.la
1420
1421 test_ratelimit_SOURCES = \
1422         src/test/test-ratelimit.c
1423
1424 test_ratelimit_LDADD = \
1425         libsystemd-shared.la
1426
1427 test_util_SOURCES = \
1428         src/test/test-util.c
1429
1430 test_util_LDADD = \
1431         libsystemd-core.la
1432
1433 test_socket_util_SOURCES = \
1434         src/test/test-socket-util.c
1435
1436 test_socket_util_LDADD = \
1437         libsystemd-core.la
1438
1439 test_ring_SOURCES = \
1440         src/test/test-ring.c
1441
1442 test_ring_LDADD = \
1443         libsystemd-core.la
1444
1445 test_barrier_SOURCES = \
1446         src/test/test-barrier.c
1447
1448 test_barrier_LDADD = \
1449         libsystemd-core.la
1450
1451 test_pty_SOURCES = \
1452         src/test/test-pty.c
1453
1454 test_pty_LDADD = \
1455         libsystemd-core.la
1456
1457 test_tmpfiles_SOURCES = \
1458         src/test/test-tmpfiles.c
1459
1460 test_tmpfiles_LDADD = \
1461         libsystemd-shared.la
1462
1463 test_namespace_SOURCES = \
1464         src/test/test-namespace.c
1465
1466 test_namespace_LDADD = \
1467         libsystemd-core.la
1468
1469 test_hashmap_SOURCES = \
1470         src/test/test-hashmap.c
1471
1472 test_hashmap_LDADD = \
1473         libsystemd-core.la
1474
1475 test_xml_SOURCES = \
1476         src/test/test-xml.c
1477
1478 test_xml_LDADD = \
1479         libsystemd-shared.la
1480
1481 test_list_SOURCES = \
1482         src/test/test-list.c
1483
1484 test_list_LDADD = \
1485         libsystemd-core.la
1486
1487 test_tables_SOURCES = \
1488         src/test/test-tables.c \
1489         src/shared/test-tables.h \
1490         src/bus-proxyd/bus-policy.c \
1491         src/bus-proxyd/bus-policy.h \
1492         src/journal/journald-server.c \
1493         src/journal/journald-server.h
1494
1495 test_tables_CPPFLAGS = \
1496         $(AM_CPPFLAGS) \
1497         -I$(top_srcdir)/src/bus-proxyd
1498
1499 test_tables_CFLAGS = \
1500         $(AM_CFLAGS) \
1501         $(SECCOMP_CFLAGS)
1502
1503 test_tables_LDADD = \
1504         libsystemd-logs.la \
1505         libsystemd-journal-internal.la \
1506         libsystemd-core.la \
1507         libudev-core.la \
1508         $(RT_LIBS)
1509
1510 test_prioq_SOURCES = \
1511         src/test/test-prioq.c
1512
1513 test_prioq_LDADD = \
1514         libsystemd-core.la
1515
1516 test_fileio_SOURCES = \
1517         src/test/test-fileio.c
1518
1519 test_fileio_LDADD = \
1520         libsystemd-core.la
1521
1522 test_time_SOURCES = \
1523         src/test/test-time.c
1524
1525 test_time_LDADD = \
1526         libsystemd-core.la
1527
1528 test_architecture_SOURCES = \
1529         src/test/test-architecture.c
1530
1531 test_architecture_LDADD = \
1532         libsystemd-shared.la
1533
1534 test_log_SOURCES = \
1535         src/test/test-log.c
1536
1537 test_log_LDADD = \
1538         libsystemd-core.la
1539
1540 test_ipcrm_SOURCES = \
1541         src/test/test-ipcrm.c
1542
1543 test_ipcrm_LDADD = \
1544         libsystemd-shared.la \
1545         -lrt
1546
1547 test_rtnl_manual_SOURCES = \
1548         src/test/test-rtnl-manual.c
1549
1550 test_rtnl_manual_CFLAGS = \
1551         $(AM_CFLAGS) \
1552         $(KMOD_CFLAGS)
1553
1554 test_rtnl_manual_LDADD = \
1555         libsystemd-internal.la \
1556         libsystemd-shared.la \
1557         $(KMOD_LIBS)
1558
1559 test_ellipsize_SOURCES = \
1560         src/test/test-ellipsize.c
1561
1562 test_ellipsize_LDADD = \
1563         libsystemd-core.la
1564
1565 test_date_SOURCES = \
1566         src/test/test-date.c
1567
1568 test_date_LDADD = \
1569         libsystemd-core.la
1570
1571 test_sleep_SOURCES = \
1572         src/test/test-sleep.c
1573
1574 test_sleep_LDADD = \
1575         libsystemd-core.la
1576
1577 test_replace_var_SOURCES = \
1578         src/test/test-replace-var.c
1579
1580 test_replace_var_LDADD = \
1581         libsystemd-shared.la
1582
1583 test_calendarspec_SOURCES = \
1584         src/test/test-calendarspec.c
1585
1586 test_calendarspec_LDADD = \
1587         libsystemd-shared.la
1588
1589 test_strip_tab_ansi_SOURCES = \
1590         src/test/test-strip-tab-ansi.c
1591
1592 test_strip_tab_ansi_LDADD = \
1593         libsystemd-shared.la
1594
1595 test_daemon_SOURCES = \
1596         src/test/test-daemon.c
1597
1598 test_daemon_LDADD = \
1599         libsystemd-internal.la \
1600         libsystemd-shared.la
1601
1602 test_cgroup_SOURCES = \
1603         src/test/test-cgroup.c
1604
1605 test_cgroup_LDADD = \
1606         libsystemd-label.la \
1607         libsystemd-shared.la \
1608         libsystemd-internal.la
1609
1610 test_cgroup_mask_SOURCES = \
1611         src/test/test-cgroup-mask.c
1612
1613 test_cgroup_mask_CPPFLAGS = \
1614         $(AM_CPPFLAGS) \
1615         -DTEST_DIR=\"$(abs_top_srcdir)/test\"
1616
1617 test_cgroup_mask_CFLAGS = \
1618         $(AM_CFLAGS) \
1619         $(SECCOMP_CFLAGS)
1620
1621 test_cgroup_mask_LDADD = \
1622         libsystemd-core.la \
1623         $(RT_LIBS)
1624
1625 test_cgroup_util_SOURCES = \
1626         src/test/test-cgroup-util.c
1627
1628 test_cgroup_util_LDADD = \
1629         libsystemd-label.la \
1630         libsystemd-internal.la \
1631         libsystemd-shared.la
1632
1633 test_env_replace_SOURCES = \
1634         src/test/test-env-replace.c
1635
1636 test_env_replace_LDADD = \
1637         libsystemd-shared.la
1638
1639 test_strbuf_SOURCES = \
1640         src/test/test-strbuf.c
1641
1642 test_strbuf_LDADD = \
1643         libsystemd-shared.la
1644
1645 test_strv_SOURCES = \
1646         src/test/test-strv.c
1647
1648 test_strv_LDADD = \
1649         libsystemd-units.la \
1650         libsystemd-internal.la \
1651         libsystemd-shared.la
1652
1653 test_path_util_SOURCES = \
1654         src/test/test-path-util.c
1655
1656 test_path_util_LDADD = \
1657         libsystemd-shared.la
1658
1659 test_strxcpyx_SOURCES = \
1660         src/test/test-strxcpyx.c
1661
1662 test_strxcpyx_LDADD = \
1663         libsystemd-shared.la
1664
1665 test_install_SOURCES = \
1666         src/test/test-install.c
1667
1668 test_install_LDADD = \
1669         libsystemd-units.la \
1670         libsystemd-label.la \
1671         libsystemd-shared.la \
1672         libsystemd-internal.la
1673
1674 test_watchdog_SOURCES = \
1675         src/test/test-watchdog.c
1676
1677 test_watchdog_LDADD = \
1678         libsystemd-shared.la
1679
1680 test_sched_prio_SOURCES = \
1681         src/test/test-sched-prio.c
1682
1683 test_sched_prio_CPPFLAGS = \
1684         $(AM_CPPFLAGS) \
1685         -DTEST_DIR=\"$(abs_top_srcdir)/test\"
1686
1687 test_sched_prio_CFLAGS = \
1688         $(AM_CFLAGS) \
1689         $(SECCOMP_CFLAGS)
1690
1691 test_sched_prio_LDADD = \
1692         libsystemd-core.la \
1693         $(RT_LIBS)
1694
1695 test_conf_files_SOURCES = \
1696         src/test/test-conf-files.c
1697
1698 test_conf_files_LDADD = \
1699         libsystemd-shared.la
1700
1701 # ------------------------------------------------------------------------------
1702 ## .PHONY so it always rebuilds it
1703 .PHONY: coverage lcov-run lcov-report coverage-sync
1704
1705 # run lcov from scratch, always
1706 coverage: all
1707         $(MAKE) lcov-run
1708         $(MAKE) lcov-report
1709
1710 coverage_dir = coverage
1711 coverage_opts = --base-directory $(srcdir) --directory $(builddir) --rc 'geninfo_adjust_src_path=$(abspath $(srcdir))=>$(abspath $(builddir))'
1712
1713 if ENABLE_COVERAGE
1714 # reset run coverage tests
1715 lcov-run:
1716         @rm -rf $(coverage_dir)
1717         lcov $(coverage_opts) --zerocounters
1718         -$(MAKE) check
1719
1720 # generate report based on current coverage data
1721 lcov-report:
1722         $(MKDIR_P) $(coverage_dir)
1723         lcov $(coverage_opts) --compat-libtool --capture --no-external \
1724                 | sed 's|$(abspath $(builddir))|$(abspath $(srcdir))|' > $(coverage_dir)/.lcov.info
1725         genhtml -t "systemd test coverage" -o $(coverage_dir) $(coverage_dir)/.lcov.info
1726         @echo "Coverage report generated in $(abs_builddir)/$(coverage_dir)/index.html"
1727
1728 # lcov doesn't work properly with vpath builds, make sure that bad
1729 # output is not uploaded by mistake.
1730 coverage-sync: coverage
1731         test "$(builddir)" = "$(srcdir)"
1732         rsync -rlv --delete --omit-dir-times coverage/ $(www_target)/coverage
1733
1734 else
1735 lcov-run lcov-report:
1736         echo "Need to reconfigure with --enable-coverage"
1737 endif
1738
1739 # ------------------------------------------------------------------------------
1740 systemd_analyze_SOURCES = \
1741         src/analyze/analyze.c
1742
1743 systemd_analyze_LDADD = \
1744         libsystemd-internal.la \
1745         libsystemd-shared.la
1746
1747 # ------------------------------------------------------------------------------
1748 systemd_initctl_SOURCES = \
1749         src/initctl/initctl.c
1750
1751 systemd_initctl_LDADD = \
1752         libsystemd-internal.la \
1753         libsystemd-shared.la
1754
1755 # ------------------------------------------------------------------------------
1756 systemd_update_utmp_SOURCES = \
1757         src/update-utmp/update-utmp.c
1758
1759 systemd_update_utmp_CFLAGS = \
1760         $(AM_CFLAGS) \
1761         $(AUDIT_CFLAGS)
1762
1763 systemd_update_utmp_LDADD = \
1764         libsystemd-internal.la \
1765         libsystemd-shared.la \
1766         $(AUDIT_LIBS)
1767
1768 # ------------------------------------------------------------------------------
1769 systemd_update_done_SOURCES = \
1770         src/update-done/update-done.c
1771
1772 systemd_update_done_LDADD = \
1773         libsystemd-internal.la \
1774         libsystemd-shared.la
1775
1776 # ------------------------------------------------------------------------------
1777 systemd_shutdownd_SOURCES = \
1778         src/shutdownd/shutdownd.c
1779
1780 systemd_shutdownd_LDADD = \
1781         libsystemd-label.la \
1782         libsystemd-internal.la \
1783         libsystemd-shared.la
1784
1785 dist_doc_DATA += \
1786         src/systemd/sd-shutdown.h
1787
1788 # ------------------------------------------------------------------------------
1789 systemd_shutdown_SOURCES = \
1790         src/core/umount.c \
1791         src/core/umount.h \
1792         src/core/shutdown.c \
1793         src/core/mount-setup.c \
1794         src/core/mount-setup.h \
1795         src/core/killall.h \
1796         src/core/killall.c
1797
1798 systemd_shutdown_LDADD = \
1799         libsystemd-label.la \
1800         libudev-internal.la \
1801         libsystemd-shared.la
1802
1803 # ------------------------------------------------------------------------------
1804 if HAVE_KMOD
1805 systemd_modules_load_SOURCES = \
1806         src/modules-load/modules-load.c
1807
1808 systemd_modules_load_CFLAGS = \
1809         $(AM_CFLAGS) \
1810         $(KMOD_CFLAGS)
1811
1812 systemd_modules_load_LDADD = \
1813         libsystemd-shared.la \
1814         $(KMOD_LIBS)
1815
1816 rootlibexec_PROGRAMS += \
1817         systemd-modules-load
1818
1819 nodist_systemunit_DATA += \
1820         units/systemd-modules-load.service
1821
1822 SYSINIT_TARGET_WANTS += \
1823         systemd-modules-load.service
1824
1825 if ENABLE_TMPFILES
1826 nodist_systemunit_DATA += \
1827         units/kmod-static-nodes.service
1828
1829 SYSINIT_TARGET_WANTS += \
1830         kmod-static-nodes.service
1831 endif
1832 endif
1833
1834 EXTRA_DIST += \
1835         units/systemd-modules-load.service.in \
1836         units/kmod-static-nodes.service.in
1837
1838 # ------------------------------------------------------------------------------
1839 if ENABLE_TMPFILES
1840 systemd_tmpfiles_SOURCES = \
1841         src/tmpfiles/tmpfiles.c
1842
1843 systemd_tmpfiles_LDADD = \
1844         libsystemd-units.la \
1845         libsystemd-label.la \
1846         libsystemd-capability.la \
1847         libsystemd-internal.la \
1848         libsystemd-shared.la
1849
1850 rootbin_PROGRAMS += \
1851         systemd-tmpfiles
1852
1853 dist_systemunit_DATA += \
1854         units/systemd-tmpfiles-clean.timer
1855
1856 nodist_systemunit_DATA += \
1857         units/systemd-tmpfiles-setup-dev.service \
1858         units/systemd-tmpfiles-setup.service \
1859         units/systemd-tmpfiles-clean.service
1860
1861 dist_tmpfiles_DATA = \
1862         tmpfiles.d/systemd.conf \
1863         tmpfiles.d/systemd-nologin.conf \
1864         tmpfiles.d/systemd-remote.conf \
1865         tmpfiles.d/tmp.conf \
1866         tmpfiles.d/x11.conf \
1867         tmpfiles.d/var.conf \
1868         tmpfiles.d/etc.conf
1869
1870 if HAVE_SYSV_COMPAT
1871 dist_tmpfiles_DATA += \
1872         tmpfiles.d/legacy.conf
1873 endif
1874
1875 SYSINIT_TARGET_WANTS += \
1876         systemd-tmpfiles-setup-dev.service \
1877         systemd-tmpfiles-setup.service
1878
1879 dist_zshcompletion_DATA += \
1880         shell-completion/zsh/_systemd-tmpfiles
1881
1882 TIMERS_TARGET_WANTS += \
1883         systemd-tmpfiles-clean.timer
1884
1885 INSTALL_DIRS += \
1886         $(tmpfilesdir) \
1887         $(sysconfdir)/tmpfiles.d
1888 endif
1889
1890 EXTRA_DIST += \
1891         units/systemd-tmpfiles-setup-dev.service.in \
1892         units/systemd-tmpfiles-setup.service.in \
1893         units/systemd-tmpfiles-clean.service.in
1894
1895 # ------------------------------------------------------------------------------
1896 if ENABLE_SYSUSERS
1897 systemd_sysusers_SOURCES = \
1898         src/sysusers/sysusers.c
1899
1900 systemd_sysusers_LDADD = \
1901         libsystemd-units.la \
1902         libsystemd-label.la \
1903         libsystemd-capability.la \
1904         libsystemd-internal.la \
1905         libsystemd-shared.la
1906
1907 rootbin_PROGRAMS += \
1908         systemd-sysusers
1909
1910 nodist_systemunit_DATA += \
1911         units/systemd-sysusers.service
1912
1913 SYSINIT_TARGET_WANTS += \
1914         systemd-sysusers.service
1915
1916 dist_sysusers_DATA = \
1917         sysusers.d/systemd.conf
1918
1919 nodist_sysusers_DATA = \
1920         sysusers.d/basic.conf
1921
1922 EXTRA_DIST += \
1923         units/systemd-sysusers.service.in \
1924         sysusers.d/basic.conf.in
1925
1926 CLEANFILES += \
1927         sysusers.d/basic.conf
1928
1929 INSTALL_DIRS += \
1930         $(sysusersdir)
1931 endif
1932
1933 # ------------------------------------------------------------------------------
1934 if ENABLE_FIRSTBOOT
1935 systemd_firstboot_SOURCES = \
1936         src/firstboot/firstboot.c
1937
1938 systemd_firstboot_LDADD = \
1939         libsystemd-units.la \
1940         libsystemd-label.la \
1941         libsystemd-capability.la \
1942         libsystemd-internal.la \
1943         libsystemd-shared.la \
1944         -lcrypt
1945
1946 rootbin_PROGRAMS += \
1947         systemd-firstboot
1948
1949 nodist_systemunit_DATA += \
1950         units/systemd-firstboot.service
1951
1952 EXTRA_DIST += \
1953         units/systemd-firstboot.service.in
1954
1955 SYSINIT_TARGET_WANTS += \
1956         systemd-firstboot.service
1957
1958 endif
1959
1960 # ------------------------------------------------------------------------------
1961 systemd_machine_id_setup_SOURCES = \
1962         src/machine-id-setup/machine-id-setup-main.c \
1963         src/core/machine-id-setup.c \
1964         src/core/machine-id-setup.h
1965
1966 systemd_machine_id_setup_LDADD = \
1967         libsystemd-label.la \
1968         libsystemd-internal.la \
1969         libsystemd-shared.la
1970
1971 # ------------------------------------------------------------------------------
1972 systemd_sysctl_SOURCES = \
1973         src/sysctl/sysctl.c
1974
1975 systemd_sysctl_LDADD = \
1976         libsystemd-shared.la
1977
1978 # ------------------------------------------------------------------------------
1979 systemd_sleep_SOURCES = \
1980         src/sleep/sleep.c
1981
1982 systemd_sleep_LDADD = \
1983         libsystemd-shared.la
1984
1985 # ------------------------------------------------------------------------------
1986 systemd_fsck_SOURCES = \
1987         src/fsck/fsck.c
1988
1989 systemd_fsck_LDADD = \
1990         libsystemd-internal.la \
1991         libudev-internal.la \
1992         libsystemd-shared.la
1993
1994 # ------------------------------------------------------------------------------
1995 systemd_ac_power_SOURCES = \
1996         src/ac-power/ac-power.c
1997
1998 systemd_ac_power_LDADD = \
1999         libudev-internal.la \
2000         libsystemd-shared.la
2001
2002 # ------------------------------------------------------------------------------
2003 systemd_detect_virt_SOURCES = \
2004         src/detect-virt/detect-virt.c
2005
2006 systemd_detect_virt_LDADD = \
2007         libsystemd-shared.la
2008
2009 INSTALL_EXEC_HOOKS += \
2010         systemd-detect-virt-install-hook
2011
2012 # ------------------------------------------------------------------------------
2013 systemd_delta_SOURCES = \
2014         src/delta/delta.c
2015
2016 systemd_delta_LDADD = \
2017         libsystemd-shared.la
2018
2019 # ------------------------------------------------------------------------------
2020 systemd_getty_generator_SOURCES = \
2021         src/getty-generator/getty-generator.c
2022
2023 systemd_getty_generator_LDADD = \
2024         libsystemd-label.la \
2025         libsystemd-shared.la
2026
2027 # ------------------------------------------------------------------------------
2028 systemd_debug_generator_SOURCES = \
2029         src/debug-generator/debug-generator.c
2030
2031 systemd_debug_generator_LDADD = \
2032         libsystemd-label.la \
2033         libsystemd-shared.la
2034
2035 # ------------------------------------------------------------------------------
2036 systemd_fstab_generator_SOURCES = \
2037         src/fstab-generator/fstab-generator.c \
2038         src/core/mount-setup.c
2039
2040 systemd_fstab_generator_LDADD = \
2041         libsystemd-label.la \
2042         libsystemd-shared.la
2043
2044 # ------------------------------------------------------------------------------
2045 systemd_system_update_generator_SOURCES = \
2046         src/system-update-generator/system-update-generator.c
2047
2048 systemd_system_update_generator_LDADD = \
2049         libsystemd-label.la \
2050         libsystemd-shared.la
2051
2052 if ENABLE_EFI
2053 # ------------------------------------------------------------------------------
2054 systemgenerator_PROGRAMS +=  \
2055         systemd-efi-boot-generator
2056
2057 systemd_efi_boot_generator_SOURCES = \
2058         src/efi-boot-generator/efi-boot-generator.c
2059
2060 systemd_efi_boot_generator_LDADD = \
2061         libsystemd-label.la \
2062         libsystemd-shared.la
2063
2064 # ------------------------------------------------------------------------------
2065 bootctl_SOURCES = \
2066         src/boot/boot.h \
2067         src/boot/boot-loader.h \
2068         src/boot/bootctl.c \
2069         src/boot/boot-loader.c \
2070         src/boot/boot-efi.c
2071
2072 bootctl_LDADD = \
2073         libsystemd-shared.la \
2074         libsystemd-internal.la
2075
2076 bin_PROGRAMS += \
2077         bootctl
2078
2079 dist_bashcompletion_DATA += \
2080         shell-completion/bash/bootctl
2081
2082 dist_zshcompletion_DATA += \
2083         shell-completion/zsh/_bootctl
2084
2085 endif
2086
2087 # ------------------------------------------------------------------------------
2088 if HAVE_BLKID
2089 systemgenerator_PROGRAMS +=  \
2090         systemd-gpt-auto-generator
2091
2092 systemd_gpt_auto_generator_SOURCES = \
2093         src/gpt-auto-generator/gpt-auto-generator.c \
2094         src/shared/blkid-util.h
2095
2096 systemd_gpt_auto_generator_LDADD = \
2097         libsystemd-label.la \
2098         libsystemd-internal.la \
2099         libudev-internal.la \
2100         libsystemd-shared.la \
2101         $(BLKID_LIBS)
2102
2103 systemd_gpt_auto_generator_CFLAGS = \
2104         $(AM_CFLAGS) \
2105         $(BLKID_CFLAGS)
2106 endif
2107
2108 # ------------------------------------------------------------------------------
2109 if ENABLE_KDBUS
2110 systemgenerator_PROGRAMS +=  \
2111         systemd-dbus1-generator
2112
2113 systemd_dbus1_generator_SOURCES = \
2114         src/dbus1-generator/dbus1-generator.c
2115
2116 systemd_dbus1_generator_LDADD = \
2117         libsystemd-label.la \
2118         libsystemd-shared.la \
2119         libsystemd-internal.la
2120
2121 dbus1-generator-install-hook:
2122         $(AM_V_at)$(MKDIR_P) $(DESTDIR)$(usergeneratordir)
2123         $(AM_V_RM)rm -f $(DESTDIR)$(usergeneratordir)/systemd-dbus1-generator
2124         $(AM_V_LN)$(LN_S) --relative -f $(DESTDIR)$(systemgeneratordir)/systemd-dbus1-generator $(DESTDIR)$(usergeneratordir)/systemd-dbus1-generator
2125
2126 dbus1-generator-uninstall-hook:
2127         rm -f $(DESTDIR)$(usergeneratordir)/systemd-dbus1-generator
2128
2129 INSTALL_EXEC_HOOKS += dbus1-generator-install-hook
2130 UNINSTALL_EXEC_HOOKS += dbus1-generator-uninstall-hook
2131 endif
2132
2133 # ------------------------------------------------------------------------------
2134 systemd_sysv_generator_SOURCES = \
2135         src/sysv-generator/sysv-generator.c
2136
2137 systemd_sysv_generator_LDADD = \
2138         libsystemd-core.la \
2139         libsystemd-label.la \
2140         libsystemd-shared.la
2141
2142 # ------------------------------------------------------------------------------
2143 systemd_rc_local_generator_SOURCES = \
2144         src/rc-local-generator/rc-local-generator.c
2145
2146 systemd_rc_local_generator_LDADD = \
2147         libsystemd-label.la \
2148         libsystemd-shared.la
2149
2150 # ------------------------------------------------------------------------------
2151 systemd_remount_fs_SOURCES = \
2152         src/remount-fs/remount-fs.c \
2153         src/core/mount-setup.c \
2154         src/core/mount-setup.h
2155
2156 systemd_remount_fs_LDADD = \
2157         libsystemd-label.la \
2158         libsystemd-shared.la
2159
2160 # ------------------------------------------------------------------------------
2161 systemd_cgroups_agent_SOURCES = \
2162         src/cgroups-agent/cgroups-agent.c
2163
2164 systemd_cgroups_agent_LDADD = \
2165         libsystemd-internal.la \
2166         libsystemd-shared.la
2167
2168 # ------------------------------------------------------------------------------
2169 systemd_escape_SOURCES = \
2170         src/escape/escape.c
2171
2172 systemd_escape_LDADD = \
2173         libsystemd-shared.la
2174
2175 # -----------------------------------------------------------------------------
2176 systemctl_SOURCES = \
2177         src/systemctl/systemctl.c
2178
2179 systemctl_LDADD = \
2180         libsystemd-units.la \
2181         libsystemd-label.la \
2182         libsystemd-internal.la \
2183         libsystemd-logs.la \
2184         libsystemd-journal-internal.la \
2185         libsystemd-shared.la
2186
2187 # ------------------------------------------------------------------------------
2188 systemd_notify_SOURCES = \
2189         src/notify/notify.c \
2190         src/readahead/sd-readahead.c
2191
2192 systemd_notify_LDADD = \
2193         libsystemd-internal.la \
2194         libsystemd-shared.la
2195
2196 # ------------------------------------------------------------------------------
2197 systemd_path_SOURCES = \
2198         src/path/path.c
2199
2200 systemd_path_LDADD = \
2201         libsystemd-internal.la \
2202         libsystemd-shared.la
2203
2204 # ------------------------------------------------------------------------------
2205 systemd_ask_password_SOURCES = \
2206         src/ask-password/ask-password.c
2207
2208 systemd_ask_password_LDADD = \
2209         libsystemd-label.la \
2210         libsystemd-shared.la
2211
2212 # ------------------------------------------------------------------------------
2213 systemd_reply_password_SOURCES = \
2214         src/reply-password/reply-password.c
2215
2216 systemd_reply_password_LDADD = \
2217         libsystemd-shared.la
2218
2219 # ------------------------------------------------------------------------------
2220 systemd_cgls_SOURCES = \
2221         src/cgls/cgls.c
2222
2223 systemd_cgls_LDADD = \
2224         libsystemd-internal.la \
2225         libsystemd-shared.la
2226
2227 # ------------------------------------------------------------------------------
2228 systemd_cgtop_SOURCES = \
2229         src/cgtop/cgtop.c
2230
2231 systemd_cgtop_LDADD = \
2232         libsystemd-shared.la
2233
2234 # ------------------------------------------------------------------------------
2235 systemd_nspawn_SOURCES = \
2236         src/nspawn/nspawn.c \
2237         src/core/mount-setup.c \
2238         src/core/mount-setup.h \
2239         src/core/loopback-setup.c \
2240         src/core/loopback-setup.h
2241
2242 systemd_nspawn_CFLAGS = \
2243         $(AM_CFLAGS) \
2244         $(SECCOMP_CFLAGS) \
2245         $(BLKID_CFLAGS)
2246
2247 systemd_nspawn_LDADD = \
2248         libsystemd-label.la \
2249         libsystemd-capability.la \
2250         libsystemd-internal.la \
2251         libudev-internal.la \
2252         libsystemd-shared.la \
2253         $(BLKID_LIBS)
2254
2255 if HAVE_SECCOMP
2256 systemd_nspawn_LDADD += \
2257         libsystemd-seccomp.la \
2258         $(SECCOMP_LIBS)
2259 endif
2260
2261 # ------------------------------------------------------------------------------
2262 systemd_run_SOURCES = \
2263         src/run/run.c
2264
2265 systemd_run_LDADD = \
2266         libsystemd-label.la \
2267         libsystemd-capability.la \
2268         libsystemd-internal.la \
2269         libsystemd-shared.la
2270
2271 # ------------------------------------------------------------------------------
2272 systemd_bus_proxyd_SOURCES = \
2273         src/bus-proxyd/bus-proxyd.c \
2274         src/bus-proxyd/bus-policy.c \
2275         src/bus-proxyd/bus-policy.h
2276
2277 systemd_bus_proxyd_LDADD = \
2278         libsystemd-capability.la \
2279         libsystemd-internal.la \
2280         libsystemd-shared.la
2281
2282 bus-proxyd-install-hook:
2283         $(AM_V_at)$(MKDIR_P) $(DESTDIR)$(bindir)
2284         $(AM_V_RM)rm -f $(DESTDIR)$(bindir)/systemd-stdio-bridge
2285         $(AM_V_LN)$(LN_S) --relative -f $(DESTDIR)$(rootlibexecdir)/systemd-bus-proxyd $(DESTDIR)$(bindir)/systemd-stdio-bridge
2286
2287 bus-proxyd-uninstall-hook:
2288         rm -f $(DESTDIR)$(bindir)/systemd-stdio-bridge
2289
2290 INSTALL_EXEC_HOOKS += bus-proxyd-install-hook
2291 UNINSTALL_EXEC_HOOKS += bus-proxyd-uninstall-hook
2292
2293 if ENABLE_KDBUS
2294 nodist_systemunit_DATA += \
2295         units/systemd-bus-proxyd@.service
2296
2297 dist_systemunit_DATA += \
2298         units/systemd-bus-proxyd.socket
2299
2300 dist_userunit_DATA += \
2301         units/user/systemd-bus-proxyd.socket \
2302         units/user/systemd-bus-proxyd@.service
2303 endif
2304
2305 EXTRA_DIST += \
2306         units/systemd-bus-proxyd@.service.in
2307
2308 # ------------------------------------------------------------------------------
2309 systemd_tty_ask_password_agent_SOURCES = \
2310         src/tty-ask-password-agent/tty-ask-password-agent.c
2311
2312 systemd_tty_ask_password_agent_LDADD = \
2313         libsystemd-label.la \
2314         libsystemd-shared.la
2315
2316 # ------------------------------------------------------------------------------
2317 libsystemd_internal_la_SOURCES = \
2318         src/systemd/sd-bus.h \
2319         src/systemd/sd-bus-protocol.h \
2320         src/systemd/sd-bus-vtable.h \
2321         src/systemd/sd-memfd.h \
2322         src/systemd/sd-utf8.h \
2323         src/systemd/sd-event.h \
2324         src/systemd/sd-rtnl.h \
2325         src/systemd/sd-resolve.h \
2326         src/systemd/sd-login.h \
2327         src/systemd/sd-id128.h \
2328         src/systemd/sd-daemon.h \
2329         src/systemd/sd-path.h \
2330         src/libsystemd/sd-bus/sd-bus.c \
2331         src/libsystemd/sd-bus/bus-control.c \
2332         src/libsystemd/sd-bus/bus-control.h \
2333         src/libsystemd/sd-bus/bus-error.c \
2334         src/libsystemd/sd-bus/bus-error.h \
2335         src/libsystemd/sd-bus/bus-internal.c \
2336         src/libsystemd/sd-bus/bus-internal.h \
2337         src/libsystemd/sd-bus/bus-socket.c \
2338         src/libsystemd/sd-bus/bus-socket.h \
2339         src/libsystemd/sd-bus/bus-kernel.c \
2340         src/libsystemd/sd-bus/bus-kernel.h \
2341         src/libsystemd/sd-bus/bus-container.c \
2342         src/libsystemd/sd-bus/bus-container.h \
2343         src/libsystemd/sd-bus/bus-message.c \
2344         src/libsystemd/sd-bus/bus-message.h \
2345         src/libsystemd/sd-bus/bus-creds.c \
2346         src/libsystemd/sd-bus/bus-creds.h \
2347         src/libsystemd/sd-bus/bus-signature.c \
2348         src/libsystemd/sd-bus/bus-signature.h \
2349         src/libsystemd/sd-bus/bus-type.c \
2350         src/libsystemd/sd-bus/bus-type.h \
2351         src/libsystemd/sd-bus/bus-match.c \
2352         src/libsystemd/sd-bus/bus-match.h \
2353         src/libsystemd/sd-bus/bus-bloom.c \
2354         src/libsystemd/sd-bus/bus-bloom.h \
2355         src/libsystemd/sd-bus/bus-introspect.c \
2356         src/libsystemd/sd-bus/bus-introspect.h \
2357         src/libsystemd/sd-bus/bus-objects.c \
2358         src/libsystemd/sd-bus/bus-objects.h \
2359         src/libsystemd/sd-bus/bus-gvariant.c \
2360         src/libsystemd/sd-bus/bus-gvariant.h \
2361         src/libsystemd/sd-bus/bus-convenience.c \
2362         src/libsystemd/sd-bus/bus-track.c \
2363         src/libsystemd/sd-bus/bus-track.h \
2364         src/libsystemd/sd-bus/bus-util.c \
2365         src/libsystemd/sd-bus/bus-util.h \
2366         src/libsystemd/sd-bus/bus-slot.c \
2367         src/libsystemd/sd-bus/bus-slot.h \
2368         src/libsystemd/sd-bus/bus-protocol.h \
2369         src/libsystemd/sd-bus/kdbus.h \
2370         src/libsystemd/sd-bus/sd-memfd.c \
2371         src/libsystemd/sd-utf8/sd-utf8.c \
2372         src/libsystemd/sd-event/sd-event.c \
2373         src/libsystemd/sd-event/event-util.h \
2374         src/libsystemd/sd-rtnl/sd-rtnl.c \
2375         src/libsystemd/sd-rtnl/rtnl-internal.h \
2376         src/libsystemd/sd-rtnl/rtnl-message.c \
2377         src/libsystemd/sd-rtnl/rtnl-types.h \
2378         src/libsystemd/sd-rtnl/rtnl-types.c \
2379         src/libsystemd/sd-rtnl/rtnl-util.h \
2380         src/libsystemd/sd-rtnl/rtnl-util.c \
2381         src/libsystemd/sd-rtnl/local-addresses.h \
2382         src/libsystemd/sd-rtnl/local-addresses.c \
2383         src/libsystemd/sd-id128/sd-id128.c \
2384         src/libsystemd/sd-daemon/sd-daemon.c \
2385         src/libsystemd/sd-login/sd-login.c \
2386         src/libsystemd/sd-path/sd-path.c
2387
2388 nodist_libsystemd_internal_la_SOURCES = \
2389         src/libsystemd/libsystemd.sym \
2390         src/libsystemd/sd-bus/bus-error-mapping.c
2391
2392 libsystemd_internal_la_CFLAGS = \
2393         $(AM_CFLAGS) \
2394         -pthread
2395
2396 libsystemd_internal_la_LIBADD = \
2397         $(RT_LIBS)
2398
2399 libsystemd_resolve_la_SOURCES = \
2400         src/libsystemd/sd-resolve/sd-resolve.c \
2401         src/libsystemd/sd-resolve/resolve-util.h
2402
2403 libsystemd_resolve_la_CFLAGS = \
2404         $(AM_CFLAGS) \
2405         -pthread
2406
2407 libsystemd_resolve_la_LIBADD = \
2408         -lresolv
2409
2410 noinst_LTLIBRARIES += \
2411         libsystemd-internal.la \
2412         libsystemd-resolve.la
2413
2414 libsystemd_dump_la_SOURCES = \
2415         src/libsystemd/sd-bus/bus-dump.c \
2416         src/libsystemd/sd-bus/bus-dump.h
2417
2418 libsystemd_dump_la_CFLAGS = \
2419         $(AM_CFLAGS) \
2420         $(CAP_CFLAGS)
2421
2422 noinst_LTLIBRARIES += \
2423         libsystemd-dump.la
2424
2425 EXTRA_DIST += \
2426         src/libsystemd/libsystemd.sym.m4 \
2427         src/libsystemd/libsystemd.pc.in \
2428         src/libsystemd/sd-bus/bus-error-mapping.gperf \
2429         src/libsystemd/sd-bus/DIFFERENCES \
2430         src/libsystemd/sd-bus/GVARIANT-SERIALIZATION
2431
2432 CLEANFILES += \
2433         src/libsystemd/libsystemd.sym \
2434         src/libsystemd/sd-bus/bus-error-mapping.c
2435
2436 BUILT_SOURCES += \
2437         src/libsystemd/libsystemd.sym
2438
2439 libsystemd_la_SOURCES = \
2440         $(libsystemd_internal_la_SOURCES) \
2441         $(libsystemd_resolve_la_SOURCES) \
2442         $(libsystemd_journal_internal_la_SOURCES)
2443
2444 nodist_libsystemd_la_SOURCES = \
2445         $(nodist_libsystemd_internal_la_SOURCES)
2446
2447 libsystemd_la_CFLAGS = \
2448         $(libsystemd_internal_la_CFLAGS) \
2449         $(libsystemd_resolve_la_CFLAGS) \
2450         $(libsystemd_journal_internal_la_CFLAGS)
2451
2452 libsystemd_la_LDFLAGS = \
2453         $(AM_LDFLAGS) \
2454         -version-info $(LIBSYSTEMD_CURRENT):$(LIBSYSTEMD_REVISION):$(LIBSYSTEMD_AGE) \
2455         -Wl,--version-script=$(top_builddir)/src/libsystemd/libsystemd.sym
2456
2457 libsystemd_la_LIBADD = \
2458         libsystemd-shared.la \
2459         $(libsystemd_internal_la_LIBADD) \
2460         $(libsystemd_journal_internal_la_LIBADD) \
2461         $(libsystemd_resolve_la_LIBADD)
2462
2463 libsystemd-install-hook:
2464         libname=libsystemd.so && $(move-to-rootlibdir)
2465
2466 libsystemd-uninstall-hook:
2467         rm -f $(DESTDIR)$(rootlibdir)/libsystemd.so*
2468
2469 INSTALL_EXEC_HOOKS += libsystemd-install-hook
2470 UNINSTALL_EXEC_HOOKS += libsystemd-uninstall-hook
2471
2472 pkgconfiglib_DATA += \
2473         src/libsystemd/libsystemd.pc
2474
2475 pkginclude_HEADERS += \
2476         src/systemd/sd-login.h \
2477         src/systemd/sd-id128.h \
2478         src/systemd/sd-daemon.h
2479
2480 if ENABLE_KDBUS
2481 pkginclude_HEADERS += \
2482         src/systemd/sd-bus.h \
2483         src/systemd/sd-bus-protocol.h \
2484         src/systemd/sd-bus-vtable.h \
2485         src/systemd/sd-memfd.h \
2486         src/systemd/sd-utf8.h \
2487         src/systemd/sd-event.h \
2488         src/systemd/sd-rtnl.h \
2489         src/systemd/sd-resolve.h \
2490         src/systemd/sd-path.h
2491 endif
2492
2493 lib_LTLIBRARIES += \
2494         libsystemd.la
2495
2496 tests += \
2497         test-bus-marshal \
2498         test-bus-signature \
2499         test-bus-chat \
2500         test-bus-cleanup \
2501         test-bus-server \
2502         test-bus-match \
2503         test-bus-kernel \
2504         test-bus-kernel-bloom \
2505         test-bus-kernel-benchmark \
2506         test-bus-memfd \
2507         test-bus-zero-copy \
2508         test-bus-introspect \
2509         test-bus-objects \
2510         test-bus-error \
2511         test-bus-creds \
2512         test-bus-gvariant \
2513         test-event \
2514         test-rtnl \
2515         test-resolve
2516
2517 bin_PROGRAMS += \
2518         busctl
2519
2520 test_bus_marshal_SOURCES = \
2521         src/libsystemd/sd-bus/test-bus-marshal.c
2522
2523 test_bus_marshal_LDADD = \
2524         libsystemd-internal.la \
2525         libsystemd-shared.la \
2526         libsystemd-dump.la \
2527         libsystemd-capability.la \
2528         $(GLIB_LIBS) \
2529         $(DBUS_LIBS) \
2530         $(CAP_LIBS)
2531
2532 test_bus_marshal_CFLAGS = \
2533         $(AM_CFLAGS) \
2534         $(GLIB_CFLAGS) \
2535         $(DBUS_CFLAGS) \
2536         $(CAP_CFLAGS)
2537
2538 test_bus_signature_SOURCES = \
2539         src/libsystemd/sd-bus/test-bus-signature.c
2540
2541 test_bus_signature_LDADD = \
2542         libsystemd-shared.la \
2543         libsystemd-internal.la
2544
2545 test_bus_chat_SOURCES = \
2546         src/libsystemd/sd-bus/test-bus-chat.c
2547
2548 test_bus_chat_CFLAGS = \
2549         $(AM_CFLAGS) \
2550         -pthread
2551
2552 test_bus_chat_LDADD = \
2553         libsystemd-internal.la \
2554         libsystemd-shared.la
2555
2556 test_bus_cleanup_SOURCES = \
2557         src/libsystemd/sd-bus/test-bus-cleanup.c
2558
2559 test_bus_cleanup_CFLAGS = \
2560         $(AM_CFLAGS) \
2561         $(SECCOMP_CFLAGS)
2562
2563 test_bus_cleanup_LDADD = \
2564         libsystemd-internal.la \
2565         libsystemd-shared.la
2566
2567 test_bus_server_SOURCES = \
2568         src/libsystemd/sd-bus/test-bus-server.c
2569
2570 test_bus_server_CFLAGS = \
2571         $(AM_CFLAGS) \
2572         -pthread
2573
2574 test_bus_server_LDADD = \
2575         libsystemd-internal.la \
2576         libsystemd-shared.la
2577
2578 test_bus_objects_SOURCES = \
2579         src/libsystemd/sd-bus/test-bus-objects.c
2580
2581 test_bus_objects_CFLAGS = \
2582         $(AM_CFLAGS) \
2583         $(CAP_CFLAGS) \
2584         -pthread
2585
2586 test_bus_objects_LDADD = \
2587         libsystemd-internal.la \
2588         libsystemd-shared.la \
2589         libsystemd-dump.la \
2590         libsystemd-capability.la \
2591         $(CAP_LIBS)
2592
2593 test_bus_error_SOURCES = \
2594         src/libsystemd/sd-bus/test-bus-error.c
2595
2596 test_bus_error_LDADD = \
2597         libsystemd-internal.la \
2598         libsystemd-shared.la
2599
2600 test_bus_gvariant_SOURCES = \
2601         src/libsystemd/sd-bus/test-bus-gvariant.c
2602
2603 test_bus_gvariant_LDADD = \
2604         libsystemd-internal.la \
2605         libsystemd-shared.la \
2606         libsystemd-dump.la \
2607         libsystemd-capability.la \
2608         $(GLIB_LIBS) \
2609         $(CAP_LIBS)
2610
2611 test_bus_gvariant_CFLAGS = \
2612         $(AM_CFLAGS) \
2613         $(GLIB_CFLAGS)
2614         $(CAP_CFLAGS)
2615
2616 test_bus_creds_SOURCES = \
2617         src/libsystemd/sd-bus/test-bus-creds.c
2618
2619 test_bus_creds_LDADD = \
2620         libsystemd-internal.la \
2621         libsystemd-shared.la \
2622         libsystemd-dump.la \
2623         libsystemd-capability.la
2624
2625 test_bus_match_SOURCES = \
2626         src/libsystemd/sd-bus/test-bus-match.c
2627
2628 test_bus_match_LDADD = \
2629         libsystemd-internal.la \
2630         libsystemd-shared.la
2631
2632 test_bus_kernel_SOURCES = \
2633         src/libsystemd/sd-bus/test-bus-kernel.c
2634
2635 test_bus_kernel_LDADD = \
2636         libsystemd-internal.la \
2637         libsystemd-shared.la \
2638         libsystemd-dump.la \
2639         libsystemd-capability.la \
2640         $(CAP_LIBS)
2641
2642 test_bus_kernel_CFLAGS = \
2643         $(AM_CFLAGS) \
2644         $(CAP_CFLAGS)
2645
2646 test_bus_kernel_bloom_SOURCES = \
2647         src/libsystemd/sd-bus/test-bus-kernel-bloom.c
2648
2649 test_bus_kernel_bloom_LDADD = \
2650         libsystemd-internal.la \
2651         libsystemd-shared.la
2652
2653 test_bus_kernel_benchmark_SOURCES = \
2654         src/libsystemd/sd-bus/test-bus-kernel-benchmark.c
2655
2656 test_bus_kernel_benchmark_LDADD = \
2657         libsystemd-internal.la \
2658         libsystemd-shared.la
2659
2660 test_bus_memfd_SOURCES = \
2661         src/libsystemd/sd-bus/test-bus-memfd.c
2662
2663 test_bus_memfd_LDADD = \
2664         libsystemd-internal.la \
2665         libsystemd-shared.la
2666
2667 test_bus_zero_copy_SOURCES = \
2668         src/libsystemd/sd-bus/test-bus-zero-copy.c
2669
2670 test_bus_zero_copy_LDADD = \
2671         libsystemd-internal.la \
2672         libsystemd-shared.la \
2673         libsystemd-dump.la \
2674         libsystemd-capability.la \
2675         $(CAP_LIBS)
2676
2677 test_bus_zero_copy_CFLAGS = \
2678         $(AM_CFLAGS) \
2679         $(CAP_CFLAGS)
2680
2681 test_bus_introspect_SOURCES = \
2682         src/libsystemd/sd-bus/test-bus-introspect.c
2683
2684 test_bus_introspect_LDADD = \
2685         libsystemd-internal.la \
2686         libsystemd-shared.la
2687
2688 test_event_SOURCES = \
2689         src/libsystemd/sd-event/test-event.c
2690
2691 test_event_LDADD = \
2692         libsystemd-internal.la \
2693         libsystemd-shared.la
2694
2695 test_rtnl_SOURCES = \
2696         src/libsystemd/sd-rtnl/test-rtnl.c
2697
2698 test_rtnl_LDADD = \
2699         libsystemd-internal.la \
2700         libsystemd-shared.la
2701
2702 test_resolve_SOURCES = \
2703         src/libsystemd/sd-resolve/test-resolve.c
2704
2705 test_resolve_LDADD = \
2706         libsystemd-resolve.la \
2707         libsystemd-internal.la \
2708         libsystemd-shared.la
2709
2710 test_resolve_CFLAGS = \
2711         $(AM_CFLAGS) \
2712         -pthread
2713
2714 busctl_SOURCES = \
2715         src/libsystemd/sd-bus/busctl.c
2716
2717 busctl_LDADD = \
2718         libsystemd-internal.la \
2719         libsystemd-shared.la \
2720         libsystemd-dump.la \
2721         libsystemd-capability.la \
2722         $(CAP_LIBS)
2723
2724 busctl_CFLAGS = \
2725         $(AM_CFLAGS) \
2726         $(CAP_CFLAGS)
2727
2728 # ------------------------------------------------------------------------------
2729 noinst_LTLIBRARIES += \
2730         libsystemd-network.la
2731
2732 libsystemd_network_la_CFLAGS = \
2733         $(AM_CFLAGS) \
2734         $(KMOD_CFLAGS)
2735
2736 libsystemd_network_la_SOURCES = \
2737         src/systemd/sd-network.h \
2738         src/systemd/sd-dhcp-client.h \
2739         src/systemd/sd-dhcp-server.h \
2740         src/systemd/sd-dhcp-lease.h \
2741         src/systemd/sd-ipv4ll.h \
2742         src/network/sd-network.c \
2743         src/network/network-util.h \
2744         src/libsystemd-network/sd-dhcp-client.c \
2745         src/libsystemd-network/sd-dhcp-server.c \
2746         src/libsystemd-network/dhcp-network.c \
2747         src/libsystemd-network/dhcp-option.c \
2748         src/libsystemd-network/dhcp-packet.c \
2749         src/libsystemd-network/dhcp-internal.h \
2750         src/libsystemd-network/dhcp-server-internal.h \
2751         src/libsystemd-network/dhcp-protocol.h \
2752         src/libsystemd-network/dhcp-lease-internal.h \
2753         src/libsystemd-network/sd-dhcp-lease.c \
2754         src/libsystemd-network/sd-ipv4ll.c \
2755         src/libsystemd-network/ipv4ll-network.c \
2756         src/libsystemd-network/ipv4ll-packet.c \
2757         src/libsystemd-network/ipv4ll-internal.h \
2758         src/libsystemd-network/network-internal.c \
2759         src/libsystemd-network/network-internal.h \
2760         src/systemd/sd-icmp6-nd.h \
2761         src/systemd/sd-dhcp6-client.h \
2762         src/systemd/sd-dhcp6-lease.h \
2763         src/libsystemd-network/sd-icmp6-nd.c \
2764         src/libsystemd-network/sd-dhcp6-client.c \
2765         src/libsystemd-network/dhcp6-internal.h \
2766         src/libsystemd-network/dhcp6-protocol.h \
2767         src/libsystemd-network/dhcp6-network.c \
2768         src/libsystemd-network/dhcp6-option.c \
2769         src/libsystemd-network/dhcp6-lease-internal.h \
2770         src/libsystemd-network/sd-dhcp6-lease.c
2771
2772 libsystemd_network_la_LIBADD = \
2773         libudev-internal.la \
2774         libsystemd-label.la \
2775         libsystemd-internal.la \
2776         libsystemd-shared.la \
2777         $(KMOD_LIBS)
2778
2779 test_dhcp_option_SOURCES = \
2780         src/libsystemd-network/dhcp-protocol.h \
2781         src/libsystemd-network/dhcp-internal.h \
2782         src/libsystemd-network/test-dhcp-option.c
2783
2784 test_dhcp_option_LDADD = \
2785         libsystemd-network.la \
2786         libsystemd-internal.la \
2787         libsystemd-shared.la
2788
2789 test_dhcp_client_SOURCES = \
2790         src/systemd/sd-dhcp-client.h \
2791         src/libsystemd-network/dhcp-protocol.h \
2792         src/libsystemd-network/dhcp-internal.h \
2793         src/libsystemd-network/test-dhcp-client.c
2794
2795 test_dhcp_client_LDADD = \
2796         libsystemd-network.la \
2797         libsystemd-label.la \
2798         libsystemd-internal.la \
2799         libsystemd-shared.la
2800
2801 test_dhcp_server_SOURCES = \
2802         src/libsystemd-network/test-dhcp-server.c
2803
2804 test_dhcp_server_LDADD = \
2805         libsystemd-network.la \
2806         libsystemd-internal.la \
2807         libsystemd-shared.la
2808
2809 test_ipv4ll_SOURCES = \
2810         src/systemd/sd-ipv4ll.h \
2811         src/libsystemd-network/ipv4ll-internal.h \
2812         src/libsystemd-network/test-ipv4ll.c
2813
2814 test_ipv4ll_LDADD = \
2815         libsystemd-network.la \
2816         libsystemd-label.la \
2817         libsystemd-internal.la \
2818         libsystemd-shared.la
2819
2820 test_icmp6_rs_SOURCES = \
2821         src/systemd/sd-dhcp6-client.h \
2822         src/systemd/sd-icmp6-nd.h \
2823         src/libsystemd-network/dhcp6-internal.h \
2824         src/libsystemd-network/test-icmp6-rs.c
2825
2826 test_icmp6_rs_LDADD = \
2827         libsystemd-network.la \
2828         libsystemd-internal.la \
2829         libsystemd-shared.la
2830
2831 test_dhcp6_client_SOURCES = \
2832         src/systemd/sd-dhcp6-client.h \
2833         src/libsystemd-network/dhcp6-internal.h \
2834         src/libsystemd-network/test-dhcp6-client.c
2835
2836 test_dhcp6_client_LDADD = \
2837         libsystemd-network.la \
2838         libsystemd-internal.la \
2839         libsystemd-shared.la
2840
2841 tests += \
2842         test-dhcp-option \
2843         test-dhcp-client \
2844         test-dhcp-server \
2845         test-ipv4ll \
2846         test-icmp6-rs \
2847         test-dhcp6-client
2848
2849 # ------------------------------------------------------------------------------
2850 if ENABLE_TERMINAL
2851 noinst_LTLIBRARIES += \
2852         libsystemd-terminal.la
2853
2854 noinst_PROGRAMS += \
2855         systemd-subterm
2856
2857 unifontdatadir=$(datadir)/unifont
2858
2859 dist_unifontdata_DATA = \
2860         src/libsystemd-terminal/unifont-glyph-array.bin
2861
2862 tests += \
2863         test-term-page \
2864         test-term-parser \
2865         test-unifont
2866 endif
2867
2868 libsystemd_terminal_la_CFLAGS = \
2869         $(AM_CFLAGS)
2870
2871 libsystemd_terminal_la_SOURCES = \
2872         src/libsystemd-terminal/term-internal.h \
2873         src/libsystemd-terminal/term-charset.c \
2874         src/libsystemd-terminal/term-page.c \
2875         src/libsystemd-terminal/term-parser.c \
2876         src/libsystemd-terminal/term-screen.c \
2877         src/libsystemd-terminal/term-wcwidth.c \
2878         src/libsystemd-terminal/unifont-internal.h \
2879         src/libsystemd-terminal/unifont.c
2880
2881 libsystemd_terminal_la_LIBADD = \
2882         libsystemd-internal.la \
2883         libsystemd-shared.la
2884
2885 systemd_subterm_SOURCES = \
2886         src/libsystemd-terminal/subterm.c
2887
2888 systemd_subterm_LDADD = \
2889         libsystemd-terminal.la \
2890         libsystemd-internal.la \
2891         libsystemd-shared.la
2892
2893 test_term_page_SOURCES = \
2894         src/libsystemd-terminal/test-term-page.c
2895
2896 test_term_page_LDADD = \
2897         libsystemd-terminal.la \
2898         libsystemd-internal.la \
2899         libsystemd-shared.la
2900
2901 test_term_parser_SOURCES = \
2902         src/libsystemd-terminal/test-term-parser.c
2903
2904 test_term_parser_LDADD = \
2905         libsystemd-terminal.la \
2906         libsystemd-internal.la \
2907         libsystemd-shared.la
2908
2909 test_unifont_SOURCES = \
2910         src/libsystemd-terminal/test-unifont.c
2911
2912 test_unifont_LDADD = \
2913         libsystemd-terminal.la \
2914         libsystemd-internal.la \
2915         libsystemd-shared.la
2916
2917 .PHONY: update-unifont
2918 update-unifont: tools/compile-unifont.py
2919         $(AM_V_GEN)$(PYTHON) $< \
2920                 <$(top_srcdir)/src/libsystemd-terminal/unifont.hex \
2921                 >$(top_srcdir)/src/libsystemd-terminal/unifont-glyph-array.bin
2922         @echo "unifont-glyph-array.bin has been regenerated"
2923
2924 # ------------------------------------------------------------------------------
2925 if ENABLE_GTK_DOC
2926 SUBDIRS += \
2927         docs/libudev
2928
2929 noinst_DATA += \
2930         docs/html/libudev \
2931         docs/html/gudev
2932 endif
2933
2934 include_HEADERS += \
2935         src/libudev/libudev.h
2936
2937 lib_LTLIBRARIES += \
2938         libudev.la
2939
2940 libudev_la_SOURCES =\
2941         src/libudev/libudev.sym \
2942         src/libudev/libudev-private.h \
2943         src/libudev/libudev.c \
2944         src/libudev/libudev-list.c \
2945         src/libudev/libudev-util.c \
2946         src/libudev/libudev-device.c \
2947         src/libudev/libudev-enumerate.c \
2948         src/libudev/libudev-monitor.c \
2949         src/libudev/libudev-queue.c \
2950         src/libudev/libudev-hwdb-def.h \
2951         src/libudev/libudev-hwdb.c
2952
2953 libudev_la_CFLAGS = \
2954         $(AM_CFLAGS) \
2955         -fvisibility=hidden
2956
2957 libudev_la_LDFLAGS = \
2958         $(AM_LDFLAGS) \
2959         -version-info $(LIBUDEV_CURRENT):$(LIBUDEV_REVISION):$(LIBUDEV_AGE) \
2960         -Wl,--version-script=$(top_srcdir)/src/libudev/libudev.sym
2961
2962 libudev_la_LIBADD = \
2963         libsystemd-internal.la \
2964         libsystemd-shared.la
2965
2966 pkgconfiglib_DATA += \
2967         src/libudev/libudev.pc
2968
2969 EXTRA_DIST += \
2970         src/libudev/libudev.pc.in
2971
2972 CLEANFILES += \
2973         src/libudev/libudev.pc \
2974         docs/html/libudev \
2975         docs/html/gudev
2976
2977 docs/html/libudev:
2978         $(AM_V_at)$(MKDIR_P) $(dir $@)
2979         $(AM_V_LN)$(LN_S) -f ../libudev/html $@
2980
2981 docs/html/gudev:
2982         $(AM_V_at)$(MKDIR_P) $(dir $@)
2983         $(AM_V_LN)$(LN_S) -f ../gudev/html $@
2984
2985 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
2986 libudev-install-hook:
2987         libname=libudev.so && $(move-to-rootlibdir)
2988
2989 libudev-uninstall-hook:
2990         rm -f $(DESTDIR)$(rootlibdir)/libudev.so*
2991
2992 INSTALL_EXEC_HOOKS += libudev-install-hook
2993 UNINSTALL_EXEC_HOOKS += libudev-uninstall-hook
2994
2995 # ------------------------------------------------------------------------------
2996 noinst_LTLIBRARIES += \
2997         libudev-internal.la
2998
2999 libudev_internal_la_SOURCES =\
3000         $(libudev_la_SOURCES) \
3001         src/libudev/libudev-device-private.c
3002
3003 libudev_internal_la_CFLAGS = \
3004         $(AM_CFLAGS) \
3005         -fvisibility=default
3006
3007 # ------------------------------------------------------------------------------
3008 INSTALL_DIRS += \
3009         $(sysconfdir)/udev/rules.d \
3010         $(sysconfdir)/udev/hwdb.d
3011
3012 dist_network_DATA = \
3013         network/99-default.link \
3014         network/80-container-host0.network \
3015         network/80-container-ve.network
3016
3017 dist_udevrules_DATA += \
3018         rules/42-usb-hid-pm.rules \
3019         rules/50-udev-default.rules \
3020         rules/60-drm.rules \
3021         rules/60-keyboard.rules \
3022         rules/60-persistent-storage-tape.rules \
3023         rules/60-persistent-serial.rules \
3024         rules/60-persistent-input.rules \
3025         rules/60-persistent-alsa.rules \
3026         rules/60-persistent-storage.rules \
3027         rules/64-btrfs.rules \
3028         rules/75-net-description.rules \
3029         rules/75-tty-description.rules \
3030         rules/78-sound-card.rules \
3031         rules/80-net-setup-link.rules \
3032         rules/95-udev-late.rules
3033
3034 nodist_udevrules_DATA += \
3035         rules/99-systemd.rules
3036
3037 dist_udevhwdb_DATA = \
3038         hwdb/20-pci-vendor-model.hwdb \
3039         hwdb/20-pci-classes.hwdb \
3040         hwdb/20-usb-vendor-model.hwdb \
3041         hwdb/20-usb-classes.hwdb \
3042         hwdb/20-sdio-vendor-model.hwdb \
3043         hwdb/20-sdio-classes.hwdb \
3044         hwdb/20-bluetooth-vendor-product.hwdb \
3045         hwdb/20-acpi-vendor.hwdb \
3046         hwdb/20-OUI.hwdb \
3047         hwdb/20-net-ifname.hwdb \
3048         hwdb/60-keyboard.hwdb
3049
3050 udevconfdir = $(sysconfdir)/udev
3051 dist_udevconf_DATA = \
3052         src/udev/udev.conf
3053
3054 sharepkgconfigdir = $(datadir)/pkgconfig
3055 sharepkgconfig_DATA = \
3056         src/udev/udev.pc
3057
3058 EXTRA_DIST += \
3059         rules/99-systemd.rules.in \
3060         src/udev/udev.pc.in
3061
3062 CLEANFILES += \
3063         rules/99-systemd.rules \
3064         src/udev/udev.pc
3065
3066 EXTRA_DIST += \
3067         units/systemd-udevd.service.in \
3068         units/systemd-udev-trigger.service.in \
3069         units/systemd-udev-settle.service.in \
3070         units/systemd-udev-hwdb-update.service.in
3071
3072 CLEANFILES += \
3073         units/systemd-udevd.service \
3074         units/systemd-udev-trigger.service \
3075         units/systemd-udev-settle.service \
3076         units/systemd-udev-hwdb-update.service
3077
3078 SOCKETS_TARGET_WANTS += \
3079         systemd-udevd-control.socket \
3080         systemd-udevd-kernel.socket
3081
3082 SYSINIT_TARGET_WANTS += \
3083         systemd-udevd.service \
3084         systemd-udev-trigger.service \
3085         systemd-udev-hwdb-update.service
3086
3087 rootbin_PROGRAMS += \
3088         udevadm
3089
3090 rootlibexec_PROGRAMS += \
3091         systemd-udevd
3092
3093 noinst_LTLIBRARIES += \
3094         libudev-core.la
3095
3096 src/udev/keyboard-keys.txt:
3097         $(AM_V_at)$(MKDIR_P) $(dir $@)
3098         $(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM -include linux/input.h - < /dev/null | $(AWK) '/^#define[ \t]+KEY_[^ ]+[ \t]+[0-9]/ { if ($$2 != "KEY_MAX") { print $$2 } }' | sed 's/^KEY_COFFEE$$/KEY_SCREENLOCK/' > $@
3099
3100 src/udev/keyboard-keys-from-name.gperf: src/udev/keyboard-keys.txt
3101         $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct key { const char* name; unsigned short id; };"; print "%null-strings"; print "%%";} { print tolower(substr($$1 ,5)) ", " $$1 }' < $< > $@
3102
3103 src/udev/keyboard-keys-from-name.h: src/udev/keyboard-keys-from-name.gperf
3104         $(AM_V_GPERF)$(GPERF) -L ANSI-C -t -N keyboard_lookup_key -H hash_key_name -p -C < $< > $@
3105
3106 src/udev/keyboard-keys-to-name.h: src/udev/keyboard-keys.txt
3107         $(AM_V_GEN)$(AWK) 'BEGIN{ print "const char* const key_names[KEY_CNT] = { "} { print "[" $$1 "] = \"" $$1 "\"," } END{print "};"}' < $< > $@
3108
3109 libudev_core_la_SOURCES = \
3110         src/udev/udev.h \
3111         src/udev/udev-event.c \
3112         src/udev/udev-watch.c \
3113         src/udev/udev-node.c \
3114         src/udev/udev-rules.c \
3115         src/udev/udev-ctrl.c \
3116         src/udev/udev-builtin.c \
3117         src/udev/udev-builtin-btrfs.c \
3118         src/udev/udev-builtin-hwdb.c \
3119         src/udev/udev-builtin-input_id.c \
3120         src/udev/udev-builtin-keyboard.c \
3121         src/udev/udev-builtin-net_id.c \
3122         src/udev/udev-builtin-net_setup_link.c \
3123         src/udev/udev-builtin-path_id.c \
3124         src/udev/udev-builtin-usb_id.c \
3125         src/udev/net/link-config.h \
3126         src/udev/net/link-config.c \
3127         src/udev/net/ethtool-util.h \
3128         src/udev/net/ethtool-util.c
3129
3130 nodist_libudev_core_la_SOURCES = \
3131         src/udev/keyboard-keys-from-name.h \
3132         src/udev/keyboard-keys-to-name.h \
3133         src/udev/net/link-config-gperf.c
3134
3135 BUILT_SOURCES += \
3136         $(nodist_libudev_core_la_SOURCES)
3137
3138 CLEANFILES += \
3139         src/udev/keyboard-keys-from-name.gperf \
3140         src/udev/keyboard-keys.txt \
3141         src/udev/net/link-config-gperf.c
3142
3143 EXTRA_DIST += \
3144         src/udev/net/link-config-gperf.gperf
3145
3146 libudev_core_la_CFLAGS = \
3147         $(AM_CFLAGS) \
3148         $(BLKID_CFLAGS) \
3149         $(KMOD_CFLAGS)
3150
3151 libudev_core_la_LIBADD = \
3152         libudev-internal.la \
3153         libsystemd-label.la \
3154         libsystemd-internal.la \
3155         libsystemd-network.la \
3156         libsystemd-shared.la \
3157         $(BLKID_LIBS) \
3158         $(KMOD_LIBS)
3159
3160 libudev_core_la_CPPFLAGS = \
3161         $(AM_CPPFLAGS) \
3162         -DFIRMWARE_PATH="$(FIRMWARE_PATH)"
3163
3164 if ENABLE_FIRMWARE
3165 libudev_core_la_SOURCES += \
3166         src/udev/udev-builtin-firmware.c
3167
3168 dist_udevrules_DATA += \
3169         rules/50-firmware.rules
3170 endif
3171
3172 if HAVE_KMOD
3173 libudev_core_la_SOURCES += \
3174         src/udev/udev-builtin-kmod.c
3175
3176 dist_udevrules_DATA += \
3177         rules/80-drivers.rules
3178 endif
3179
3180 if HAVE_BLKID
3181 libudev_core_la_SOURCES += \
3182         src/udev/udev-builtin-blkid.c
3183 endif
3184
3185 if HAVE_ACL
3186 libudev_core_la_SOURCES += \
3187         src/udev/udev-builtin-uaccess.c \
3188         src/login/logind-acl.c \
3189         src/libsystemd/sd-login/sd-login.c \
3190         src/systemd/sd-login.h
3191
3192 libudev_core_la_LIBADD += \
3193         libsystemd-acl.la
3194 endif
3195
3196 systemd_udevd_SOURCES = \
3197         src/udev/udevd.c
3198
3199 systemd_udevd_LDADD = \
3200         libudev-core.la
3201
3202 udevadm_SOURCES = \
3203         src/udev/udevadm.c \
3204         src/udev/udevadm-info.c \
3205         src/udev/udevadm-control.c \
3206         src/udev/udevadm-monitor.c \
3207         src/udev/udevadm-hwdb.c \
3208         src/udev/udevadm-settle.c \
3209         src/udev/udevadm-trigger.c \
3210         src/udev/udevadm-test.c \
3211         src/udev/udevadm-test-builtin.c
3212
3213 udevadm_LDADD = \
3214         libudev-core.la
3215
3216 # Update hwdb on installation. Do not bother if installing
3217 # in DESTDIR, since this is likely for packaging purposes.
3218 hwdb-update-hook:
3219         -test -n "$(DESTDIR)" || $(rootbindir)/udevadm hwdb --update
3220
3221 INSTALL_DATA_HOOKS += \
3222         hwdb-update-hook
3223
3224 hwdb-remove-hook:
3225         -test -n "$(DESTDIR)" || rm -f /etc/udev/hwdb.bin
3226
3227 # ------------------------------------------------------------------------------
3228 TESTS += \
3229         test/udev-test.pl \
3230         test/rules-test.sh
3231
3232 manual_tests += \
3233         test-libudev \
3234         test-udev
3235
3236 test_libudev_SOURCES = \
3237         src/test/test-libudev.c
3238
3239 test_libudev_LDADD = \
3240         libsystemd-label.la \
3241         libudev-internal.la \
3242         libsystemd-shared.la
3243
3244 test_udev_SOURCES = \
3245         src/test/test-udev.c
3246
3247 test_udev_LDADD = \
3248         libudev-core.la \
3249         $(BLKID_LIBS) \
3250         $(KMOD_LIBS) \
3251         $(SELINUX_LIBS)
3252
3253 if HAVE_ACL
3254 test_udev_LDADD += \
3255         libsystemd-acl.la
3256 endif
3257
3258 check_DATA += \
3259         test/sys
3260
3261 # packed sysfs test tree
3262 test/sys:
3263         $(AM_V_at)$(MKDIR_P) $(dir $@)
3264         $(AM_V_GEN)tar -C test/ -xJf $(top_srcdir)/test/sys.tar.xz
3265
3266 test-sys-distclean:
3267         -rm -rf test/sys
3268 DISTCLEAN_LOCAL_HOOKS += test-sys-distclean
3269
3270 EXTRA_DIST += \
3271         test/sys.tar.xz \
3272         test/udev-test.pl \
3273         test/rules-test.sh \
3274         test/rule-syntax-check.py
3275
3276 # ------------------------------------------------------------------------------
3277 ata_id_SOURCES = \
3278         src/udev/ata_id/ata_id.c
3279
3280 ata_id_LDADD = \
3281         libudev-internal.la \
3282         libsystemd-shared.la
3283
3284 udevlibexec_PROGRAMS += \
3285         ata_id
3286
3287 # ------------------------------------------------------------------------------
3288 cdrom_id_SOURCES = \
3289         src/udev/cdrom_id/cdrom_id.c
3290
3291 cdrom_id_LDADD = \
3292         libudev-internal.la \
3293         libsystemd-shared.la
3294
3295 udevlibexec_PROGRAMS += \
3296         cdrom_id
3297
3298 dist_udevrules_DATA += \
3299         rules/60-cdrom_id.rules
3300
3301 # ------------------------------------------------------------------------------
3302 collect_SOURCES = \
3303         src/udev/collect/collect.c
3304
3305 collect_LDADD = \
3306         libudev-internal.la \
3307         libsystemd-shared.la
3308
3309 udevlibexec_PROGRAMS += \
3310         collect
3311
3312 # ------------------------------------------------------------------------------
3313 scsi_id_SOURCES =\
3314         src/udev/scsi_id/scsi_id.c \
3315         src/udev/scsi_id/scsi_serial.c \
3316         src/udev/scsi_id/scsi.h \
3317         src/udev/scsi_id/scsi_id.h
3318
3319 scsi_id_LDADD = \
3320         libudev-internal.la \
3321         libsystemd-shared.la
3322
3323 udevlibexec_PROGRAMS += \
3324         scsi_id
3325
3326 EXTRA_DIST += \
3327         src/udev/scsi_id/README
3328
3329 # ------------------------------------------------------------------------------
3330 v4l_id_SOURCES = \
3331         src/udev/v4l_id/v4l_id.c
3332
3333 v4l_id_LDADD = \
3334         libudev-internal.la
3335
3336 udevlibexec_PROGRAMS += \
3337         v4l_id
3338
3339 dist_udevrules_DATA += \
3340         rules/60-persistent-v4l.rules
3341
3342 # ------------------------------------------------------------------------------
3343 accelerometer_SOURCES = \
3344         src/udev/accelerometer/accelerometer.c
3345
3346 accelerometer_LDADD = \
3347         libudev-internal.la -lm \
3348         libsystemd-shared.la
3349
3350 udevlibexec_PROGRAMS += \
3351         accelerometer
3352
3353 dist_udevrules_DATA += \
3354         rules/61-accelerometer.rules
3355
3356 # ------------------------------------------------------------------------------
3357 if ENABLE_GUDEV
3358 if ENABLE_GTK_DOC
3359 SUBDIRS += \
3360         docs/gudev
3361 endif
3362
3363 libgudev_includedir = \
3364         $(includedir)/gudev-1.0/gudev
3365
3366 libgudev_include_HEADERS = \
3367         src/gudev/gudev.h \
3368         src/gudev/gudevenums.h \
3369         src/gudev/gudevenumtypes.h \
3370         src/gudev/gudevtypes.h \
3371         src/gudev/gudevclient.h \
3372         src/gudev/gudevdevice.h \
3373         src/gudev/gudevenumerator.h
3374
3375 lib_LTLIBRARIES += libgudev-1.0.la
3376
3377 pkgconfiglib_DATA += \
3378         src/gudev/gudev-1.0.pc
3379
3380 CLEANFILES += \
3381         src/gudev/gudev-1.0.pc
3382
3383 libgudev_1_0_la_SOURCES = \
3384         src/gudev/libgudev-1.0.sym \
3385         src/gudev/gudevenums.h \
3386         src/gudev/gudevenumtypes.h \
3387         src/gudev/gudevenumtypes.h\
3388         src/gudev/gudevtypes.h \
3389         src/gudev/gudevclient.h \
3390         src/gudev/gudevclient.c \
3391         src/gudev/gudevdevice.h \
3392         src/gudev/gudevdevice.c \
3393         src/gudev/gudevenumerator.h \
3394         src/gudev/gudevenumerator.c \
3395         src/gudev/gudevprivate.h
3396
3397 nodist_libgudev_1_0_la_SOURCES = \
3398         src/gudev/gudevmarshal.h \
3399         src/gudev/gudevmarshal.c \
3400         src/gudev/gudevenumtypes.h \
3401         src/gudev/gudevenumtypes.c
3402
3403 BUILT_SOURCES += \
3404         $(nodist_libgudev_1_0_la_SOURCES)
3405
3406 libgudev_1_0_la_CPPFLAGS = \
3407         $(AM_CPPFLAGS) \
3408         -I$(top_builddir)/src\
3409         -I$(top_srcdir)/src\
3410         -I$(top_builddir)/src/gudev \
3411         -I$(top_srcdir)/src/gudev \
3412         -D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT \
3413         -D_GUDEV_COMPILATION \
3414         -DG_LOG_DOMAIN=\"GUdev\"
3415
3416 libgudev_1_0_la_CFLAGS = \
3417         $(AM_CFLAGS) \
3418         -fvisibility=default \
3419         $(GLIB_CFLAGS)
3420
3421 libgudev_1_0_la_LIBADD = \
3422         libudev.la \
3423         $(GLIB_LIBS)
3424
3425 libgudev_1_0_la_LDFLAGS = \
3426         $(AM_LDFLAGS) \
3427         -version-info $(LIBGUDEV_CURRENT):$(LIBGUDEV_REVISION):$(LIBGUDEV_AGE) \
3428         -export-dynamic \
3429         -no-undefined \
3430         -Wl,--version-script=$(top_srcdir)/src/gudev/libgudev-1.0.sym
3431
3432 src/gudev/gudevmarshal.h: src/gudev/gudevmarshal.list
3433         $(AM_V_at)$(MKDIR_P) $(dir $@)
3434         $(AM_V_GEN)glib-genmarshal $< --prefix=g_udev_marshal --header > $@
3435
3436 src/gudev/gudevmarshal.c: src/gudev/gudevmarshal.list
3437         $(AM_V_at)$(MKDIR_P) $(dir $@)
3438         $(AM_V_GEN)echo '#include "gudevmarshal.h"' > $@ && \
3439         glib-genmarshal $< --prefix=g_udev_marshal --body >> $@
3440
3441 src/gudev/gudevenumtypes.%: src/gudev/gudevenumtypes.%.template src/gudev/gudevenums.h
3442         $(AM_V_at)$(MKDIR_P) $(dir $@)
3443         $(AM_V_GEN)glib-mkenums --template $^ > $@
3444
3445 if HAVE_INTROSPECTION
3446 -include $(INTROSPECTION_MAKEFILE)
3447
3448 src/gudev/GUdev-1.0.gir: libgudev-1.0.la
3449
3450 src_gudev_GUdev_1_0_gir_INCLUDES = GObject-2.0
3451
3452 src_gudev_GUdev_1_0_gir_CFLAGS = \
3453         $(AM_CFLAGS) \
3454         $(INCLUDES) \
3455         -D_GUDEV_COMPILATION \
3456         -D_GUDEV_WORK_AROUND_DEV_T_BUG \
3457         -I$(top_srcdir)/src \
3458         -I$(top_builddir)/src \
3459         -I$(top_srcdir)/src/gudev \
3460         -I$(top_builddir)/src/gudev
3461
3462 src_gudev_GUdev_1_0_gir_LIBS = libgudev-1.0.la
3463
3464 src_gudev_GUdev_1_0_gir_SCANNERFLAGS = \
3465         --pkg-export=gudev-1.0 \
3466         --warn-all
3467
3468 src_gudev_GUdev_1_0_gir_FILES = \
3469         src/gudev/gudev.h \
3470         src/gudev/gudevtypes.h \
3471         src/gudev/gudevenums.h \
3472         src/gudev/gudevenumtypes.h \
3473         src/gudev/gudevclient.h \
3474         src/gudev/gudevdevice.h \
3475         src/gudev/gudevenumerator.h \
3476         src/gudev/gudevclient.c \
3477         src/gudev/gudevdevice.c \
3478         src/gudev/gudevenumerator.c
3479
3480 INTROSPECTION_GIRS = src/gudev/GUdev-1.0.gir
3481 INTROSPECTION_SCANNER_ARGS = --c-include=gudev/gudev.h
3482
3483 girdir = $(datadir)/gir-1.0
3484 gir_DATA = \
3485         src/gudev/GUdev-1.0.gir
3486
3487 typelibsdir = $(libdir)/girepository-1.0
3488 typelibs_DATA = \
3489         src/gudev/GUdev-1.0.typelib
3490
3491 CLEANFILES += $(gir_DATA) $(typelibs_DATA)
3492 endif # HAVE_INTROSPECTION
3493 endif
3494
3495 EXTRA_DIST += \
3496         src/gudev/gudev-1.0.pc.in \
3497         src/gudev/gudevmarshal.list \
3498         src/gudev/gudevenumtypes.h.template \
3499         src/gudev/gudevenumtypes.c.template \
3500         src/gudev/gjs-example.js \
3501         src/gudev/seed-example-enum.js \
3502         src/gudev/seed-example.js
3503
3504 # ------------------------------------------------------------------------------
3505 mtd_probe_SOURCES =  \
3506         src/udev/mtd_probe/mtd_probe.c \
3507         src/udev/mtd_probe/mtd_probe.h \
3508         src/udev/mtd_probe/probe_smartmedia.c
3509
3510 dist_udevrules_DATA += \
3511         rules/75-probe_mtd.rules
3512
3513 udevlibexec_PROGRAMS += \
3514         mtd_probe
3515
3516 # ------------------------------------------------------------------------------
3517 test_id128_SOURCES = \
3518         src/test/test-id128.c
3519
3520 test_id128_LDADD = \
3521         libsystemd-internal.la \
3522         libsystemd-shared.la
3523
3524 tests += \
3525         test-id128
3526
3527 # ------------------------------------------------------------------------------
3528
3529 rootlibexec_PROGRAMS += \
3530         systemd-activate
3531
3532 systemd_activate_SOURCES = \
3533         src/activate/activate.c
3534
3535 systemd_activate_LDADD = \
3536         libsystemd-label.la \
3537         libsystemd-internal.la \
3538         libsystemd-shared.la
3539
3540 # ------------------------------------------------------------------------------
3541 systemd_journald_SOURCES = \
3542         src/journal/journald.c \
3543         src/journal/journald-server.h
3544
3545 systemd_journald_LDADD = \
3546         libsystemd-journal-core.la \
3547         libsystemd-internal.la \
3548         libsystemd-shared.la
3549
3550 systemd_cat_SOURCES = \
3551         src/journal/cat.c
3552
3553 systemd_cat_LDADD = \
3554         libsystemd-journal-core.la
3555
3556 if HAVE_MICROHTTPD
3557 rootlibexec_PROGRAMS += \
3558         systemd-journal-remote
3559
3560 systemd_journal_remote_SOURCES = \
3561         src/journal-remote/journal-remote-parse.h \
3562         src/journal-remote/journal-remote-parse.c \
3563         src/journal-remote/journal-remote-write.h \
3564         src/journal-remote/journal-remote-write.c \
3565         src/journal-remote/journal-remote.h \
3566         src/journal-remote/journal-remote.c
3567
3568 systemd_journal_remote_LDADD = \
3569         libsystemd-internal.la \
3570         libsystemd-journal-core.la
3571
3572 systemd_journal_remote_SOURCES += \
3573         src/journal-remote/microhttpd-util.h \
3574         src/journal-remote/microhttpd-util.c
3575
3576 systemd_journal_remote_CFLAGS = \
3577         $(AM_CFLAGS) \
3578         $(MICROHTTPD_CFLAGS)
3579
3580 systemd_journal_remote_LDADD += \
3581         $(MICROHTTPD_LIBS)
3582
3583 if HAVE_GNUTLS
3584 systemd_journal_remote_LDADD += \
3585         $(GNUTLS_LIBS)
3586
3587 # systemd-journal-remote make sense mostly with full crypto stack
3588 dist_systemunit_DATA += \
3589         units/systemd-journal-remote.socket
3590
3591 nodist_systemunit_DATA += \
3592         units/systemd-journal-remote.service
3593
3594 EXTRA_DIST += \
3595         units/systemd-journal-remote.service.in
3596
3597 journal-remote-install-hook: journal-install-hook
3598         -$(MKDIR_P) $(DESTDIR)/var/log/journal/remote
3599         -chown 0:0 $(DESTDIR)/var/log/journal/remote
3600         -chmod 755 $(DESTDIR)/var/log/journal/remote
3601
3602 INSTALL_EXEC_HOOKS += journal-remote-install-hook
3603
3604 endif
3605
3606 nodist_pkgsysconf_DATA += \
3607         src/journal-remote/journal-remote.conf
3608
3609 EXTRA_DIST += \
3610         src/journal-remote/journal-remote.conf.in
3611
3612 CLEANFILES += \
3613         src/journal-remote/journal-remote.conf
3614 endif
3615
3616 if HAVE_LIBCURL
3617 rootlibexec_PROGRAMS += \
3618         systemd-journal-upload
3619
3620 systemd_journal_upload_SOURCES = \
3621         src/journal-remote/journal-upload.h \
3622         src/journal-remote/journal-upload.c \
3623         src/journal-remote/journal-upload-journal.c
3624
3625 systemd_journal_upload_CFLAGS = \
3626         $(AM_CFLAGS) \
3627         $(LIBCURL_CFLAGS)
3628
3629 systemd_journal_upload_LDADD = \
3630         libsystemd-core.la \
3631         libsystemd-internal.la \
3632         libsystemd-journal-internal.la \
3633         libsystemd-shared.la \
3634         $(LIBCURL_LIBS)
3635
3636 nodist_systemunit_DATA += \
3637         units/systemd-journal-upload.service
3638
3639 EXTRA_DIST += \
3640         units/systemd-journal-upload.service.in
3641
3642 nodist_pkgsysconf_DATA += \
3643         src/journal-remote/journal-upload.conf
3644
3645 EXTRA_DIST += \
3646         src/journal-remote/journal-upload.conf.in
3647
3648 CLEANFILES += \
3649         src/journal-remote/journal-upload.conf
3650 endif
3651
3652 # using _CFLAGS = in the conditional below would suppress AM_CFLAGS
3653 journalctl_CFLAGS = \
3654         $(AM_CFLAGS)
3655
3656 journalctl_SOURCES = \
3657         src/journal/journalctl.c
3658
3659 journalctl_LDADD = \
3660         libsystemd-journal-internal.la \
3661         libsystemd-internal.la \
3662         libsystemd-logs.la \
3663         libsystemd-shared.la
3664
3665 if HAVE_ACL
3666 journalctl_LDADD += \
3667         libsystemd-acl.la
3668 endif
3669
3670 if HAVE_QRENCODE
3671 journalctl_SOURCES += \
3672         src/journal/journal-qrcode.c \
3673         src/journal/journal-qrcode.h
3674
3675 journalctl_CFLAGS += \
3676         $(QRENCODE_CFLAGS)
3677
3678 journalctl_LDADD += \
3679         $(QRENCODE_LIBS)
3680 endif
3681
3682 test_journal_SOURCES = \
3683         src/journal/test-journal.c
3684
3685 test_journal_LDADD = \
3686         libsystemd-journal-core.la
3687
3688 test_journal_send_SOURCES = \
3689         src/journal/test-journal-send.c
3690
3691 test_journal_send_LDADD = \
3692         libsystemd-journal-core.la
3693
3694 test_journal_syslog_SOURCES = \
3695         src/journal/test-journal-syslog.c
3696
3697 test_journal_syslog_LDADD = \
3698         libsystemd-journal-core.la
3699
3700 test_journal_match_SOURCES = \
3701         src/journal/test-journal-match.c
3702
3703 test_journal_match_LDADD = \
3704         libsystemd-journal-core.la
3705
3706 test_journal_enum_SOURCES = \
3707         src/journal/test-journal-enum.c
3708
3709 test_journal_enum_LDADD = \
3710         libsystemd-journal-core.la
3711
3712 test_journal_stream_SOURCES = \
3713         src/journal/test-journal-stream.c
3714
3715 test_journal_stream_LDADD = \
3716         libsystemd-journal-core.la
3717
3718 test_journal_flush_SOURCES = \
3719         src/journal/test-journal-flush.c
3720
3721 test_journal_flush_LDADD = \
3722         libsystemd-journal-core.la
3723
3724 test_journal_init_SOURCES = \
3725         src/journal/test-journal-init.c
3726
3727 test_journal_init_LDADD = \
3728         libsystemd-journal-core.la
3729
3730 test_journal_verify_SOURCES = \
3731         src/journal/test-journal-verify.c
3732
3733 test_journal_verify_LDADD = \
3734         libsystemd-journal-core.la
3735
3736 test_journal_interleaving_SOURCES = \
3737         src/journal/test-journal-interleaving.c
3738
3739 test_journal_interleaving_LDADD = \
3740         libsystemd-journal-core.la
3741
3742 test_mmap_cache_SOURCES = \
3743         src/journal/test-mmap-cache.c
3744
3745 test_mmap_cache_LDADD = \
3746         libsystemd-journal-core.la
3747
3748 test_catalog_SOURCES = \
3749         src/journal/test-catalog.c
3750
3751 test_catalog_CPPFLAGS = \
3752         $(AM_CPPFLAGS) \
3753         -DCATALOG_DIR=\"$(abs_top_srcdir)/catalog\"
3754
3755 test_catalog_LDADD = \
3756         libsystemd-journal-core.la
3757
3758 test_compress_SOURCES = \
3759         src/journal/test-compress.c
3760
3761 test_compress_LDADD = \
3762         libsystemd-journal-internal.la \
3763         libsystemd-shared.la
3764
3765 test_compress_benchmark_SOURCES = \
3766         src/journal/test-compress-benchmark.c
3767
3768 test_compress_benchmark_LDADD = \
3769         libsystemd-journal-internal.la \
3770         libsystemd-shared.la
3771
3772 libsystemd_journal_core_la_SOURCES = \
3773         src/journal/journald-kmsg.c \
3774         src/journal/journald-kmsg.h \
3775         src/journal/journald-syslog.c \
3776         src/journal/journald-syslog.h \
3777         src/journal/journald-stream.c \
3778         src/journal/journald-stream.h \
3779         src/journal/journald-server.c \
3780         src/journal/journald-server.h \
3781         src/journal/journald-console.c \
3782         src/journal/journald-console.h \
3783         src/journal/journald-wall.c \
3784         src/journal/journald-wall.h \
3785         src/journal/journald-native.c \
3786         src/journal/journald-native.h \
3787         src/journal/journald-rate-limit.c \
3788         src/journal/journald-rate-limit.h \
3789         src/journal/journal-internal.h
3790
3791 nodist_libsystemd_journal_core_la_SOURCES = \
3792         src/journal/journald-gperf.c
3793
3794 libsystemd_journal_core_la_LIBADD = \
3795         libsystemd-journal-internal.la \
3796         libudev-internal.la \
3797         libsystemd-capability.la \
3798         libsystemd-label.la \
3799         libsystemd-internal.la \
3800         libsystemd-shared.la
3801
3802 if HAVE_ACL
3803 libsystemd_journal_core_la_LIBADD += \
3804         libsystemd-acl.la
3805 endif
3806
3807 noinst_LTLIBRARIES += \
3808         libsystemd-journal-core.la
3809
3810 journal-install-hook:
3811         -$(MKDIR_P) $(DESTDIR)/var/log/journal
3812         -chown 0:0 $(DESTDIR)/var/log/journal
3813         -chmod 755 $(DESTDIR)/var/log/journal
3814         -setfacl -nm g:adm:rx,d:g:adm:rx $(DESTDIR)/var/log/journal/
3815         -setfacl -nm g:wheel:rx,d:g:wheel:rx $(DESTDIR)/var/log/journal/
3816
3817 journal-uninstall-hook:
3818         -rmdir $(DESTDIR)/var/log/journal/remote
3819         -rmdir $(DESTDIR)/var/log/journal/
3820
3821 INSTALL_EXEC_HOOKS += journal-install-hook
3822 UNINSTALL_EXEC_HOOKS += journal-uninstall-hook
3823
3824 # ------------------------------------------------------------------------------
3825 # Update catalog on installation. Do not bother if installing
3826 # in DESTDIR, since this is likely for packaging purposes.
3827 catalog-update-hook:
3828         -test -n "$(DESTDIR)" || $(rootbindir)/journalctl --update-catalog
3829
3830 INSTALL_DATA_HOOKS += \
3831         catalog-update-hook
3832
3833 catalog-remove-hook:
3834         -test -n "$(DESTDIR)" || rm -f $(catalogstatedir)/database
3835
3836 UNINSTALL_DATA_HOOKS += \
3837         catalog-remove-hook
3838
3839 manual_tests += \
3840         test-journal-enum
3841
3842 tests += \
3843         test-journal \
3844         test-journal-send \
3845         test-journal-syslog \
3846         test-journal-match \
3847         test-journal-stream \
3848         test-journal-init \
3849         test-journal-verify \
3850         test-journal-interleaving \
3851         test-journal-flush \
3852         test-mmap-cache \
3853         test-catalog
3854
3855 if HAVE_COMPRESSION
3856 tests += \
3857         test-compress \
3858         test-compress-benchmark
3859 endif
3860
3861 pkginclude_HEADERS += \
3862         src/systemd/sd-journal.h \
3863         src/systemd/sd-messages.h \
3864         src/systemd/_sd-common.h
3865
3866 libsystemd_journal_internal_la_SOURCES = \
3867         src/journal/sd-journal.c \
3868         src/systemd/sd-journal.h \
3869         src/systemd/_sd-common.h \
3870         src/journal/journal-file.c \
3871         src/journal/journal-file.h \
3872         src/journal/journal-vacuum.c \
3873         src/journal/journal-vacuum.h \
3874         src/journal/journal-verify.c \
3875         src/journal/journal-verify.h \
3876         src/journal/lookup3.c \
3877         src/journal/lookup3.h \
3878         src/journal/journal-send.c \
3879         src/journal/journal-def.h \
3880         src/journal/compress.h \
3881         src/journal/catalog.c \
3882         src/journal/catalog.h \
3883         src/journal/mmap-cache.c \
3884         src/journal/mmap-cache.h
3885
3886 # using _CFLAGS = in the conditional below would suppress AM_CFLAGS
3887 libsystemd_journal_internal_la_CFLAGS = \
3888         $(AM_CFLAGS)
3889
3890 libsystemd_journal_internal_la_LIBADD =
3891
3892 libsystemd_journal_internal_la_SOURCES += \
3893         src/journal/compress.c
3894
3895 if HAVE_XZ
3896 libsystemd_journal_internal_la_CFLAGS += \
3897         $(XZ_CFLAGS)
3898
3899 libsystemd_journal_internal_la_LIBADD += \
3900         $(XZ_LIBS)
3901 endif
3902
3903 if HAVE_LZ4
3904 libsystemd_journal_internal_la_LIBADD += \
3905         -llz4
3906 endif
3907
3908 if HAVE_GCRYPT
3909 libsystemd_journal_internal_la_SOURCES += \
3910         src/journal/journal-authenticate.c \
3911         src/journal/journal-authenticate.h \
3912         src/journal/fsprg.c \
3913         src/journal/fsprg.h
3914
3915 libsystemd_journal_internal_la_LIBADD += \
3916         $(GCRYPT_LIBS)
3917
3918 # fsprg.c is a drop-in file using void pointer arithmetic
3919 libsystemd_journal_internal_la_CFLAGS += \
3920         $(GCRYPT_CFLAGS) \
3921         -Wno-pointer-arith
3922 endif
3923
3924 noinst_LTLIBRARIES += \
3925         libsystemd-journal-internal.la
3926
3927 rootlibexec_PROGRAMS += \
3928         systemd-journald
3929
3930 rootbin_PROGRAMS += \
3931         journalctl
3932
3933 bin_PROGRAMS += \
3934         systemd-cat
3935
3936 dist_systemunit_DATA += \
3937         units/systemd-journald.socket \
3938         units/systemd-journald-dev-log.socket
3939
3940 nodist_systemunit_DATA += \
3941         units/systemd-journald.service \
3942         units/systemd-journal-flush.service \
3943         units/systemd-journal-catalog-update.service
3944
3945 dist_pkgsysconf_DATA += \
3946         src/journal/journald.conf
3947
3948 dist_catalog_DATA = \
3949         catalog/systemd.fr.catalog \
3950         catalog/systemd.ru.catalog \
3951         catalog/systemd.it.catalog \
3952         catalog/systemd.catalog
3953
3954 SOCKETS_TARGET_WANTS += \
3955         systemd-journald.socket \
3956         systemd-journald-dev-log.socket
3957
3958 SYSINIT_TARGET_WANTS += \
3959         systemd-journald.service \
3960         systemd-journal-flush.service \
3961         systemd-journal-catalog-update.service
3962
3963 EXTRA_DIST += \
3964         units/systemd-journald.service.in \
3965         units/systemd-journal-flush.service.in \
3966         units/systemd-journal-catalog-update.service.in \
3967         src/journal/journald-gperf.gperf
3968
3969 CLEANFILES += \
3970         src/journal/journald-gperf.c
3971
3972 # ------------------------------------------------------------------------------
3973 if HAVE_MICROHTTPD
3974 gatewayddocumentrootdir=$(pkgdatadir)/gatewayd
3975
3976 rootlibexec_PROGRAMS += \
3977         systemd-journal-gatewayd
3978
3979 systemd_journal_gatewayd_SOURCES = \
3980         src/journal-remote/journal-gatewayd.c \
3981         src/journal-remote/microhttpd-util.h \
3982         src/journal-remote/microhttpd-util.c
3983
3984 systemd_journal_gatewayd_LDADD = \
3985         libsystemd-logs.la \
3986         libsystemd-journal-internal.la \
3987         libsystemd-internal.la \
3988         libsystemd-shared.la \
3989         $(MICROHTTPD_LIBS)
3990
3991 if HAVE_GNUTLS
3992 systemd_journal_gatewayd_LDADD += \
3993         $(GNUTLS_LIBS)
3994 endif
3995
3996 systemd_journal_gatewayd_CFLAGS = \
3997         $(AM_CFLAGS) \
3998         $(MICROHTTPD_CFLAGS)
3999
4000 systemd_journal_gatewayd_CPPFLAGS = \
4001         $(AM_CPPFLAGS) \
4002         -DDOCUMENT_ROOT=\"$(gatewayddocumentrootdir)\"
4003
4004 dist_systemunit_DATA += \
4005         units/systemd-journal-gatewayd.socket
4006
4007 nodist_systemunit_DATA += \
4008         units/systemd-journal-gatewayd.service
4009
4010 dist_gatewayddocumentroot_DATA = \
4011         src/journal-remote/browse.html
4012
4013 endif
4014
4015 EXTRA_DIST += \
4016         units/systemd-journal-gatewayd.service.in
4017
4018 # ------------------------------------------------------------------------------
4019
4020 systemd_socket_proxyd_SOURCES = \
4021         src/socket-proxy/socket-proxyd.c
4022
4023 systemd_socket_proxyd_LDADD = \
4024         libsystemd-logs.la \
4025         libsystemd-internal.la \
4026         libsystemd-journal-internal.la \
4027         libsystemd-shared.la \
4028         libsystemd-resolve.la
4029
4030 # ------------------------------------------------------------------------------
4031 if ENABLE_COREDUMP
4032 systemd_coredump_SOURCES = \
4033         src/journal/coredump.c \
4034         src/journal/coredump-vacuum.c \
4035         src/journal/coredump-vacuum.h
4036
4037 systemd_coredump_LDADD = \
4038         libsystemd-journal-internal.la \
4039         libsystemd-label.la \
4040         libsystemd-internal.la \
4041         libsystemd-shared.la
4042
4043 if HAVE_ELFUTILS
4044 systemd_coredump_SOURCES += \
4045         src/journal/stacktrace.c \
4046         src/journal/stacktrace.h
4047
4048 systemd_coredump_LDADD += \
4049         $(ELFUTILS_LIBS)
4050 endif
4051
4052 rootlibexec_PROGRAMS += \
4053         systemd-coredump
4054
4055 dist_pkgsysconf_DATA += \
4056         src/journal/coredump.conf
4057
4058 if HAVE_ACL
4059 systemd_coredump_LDADD += \
4060         libsystemd-acl.la
4061 endif
4062
4063 coredumpctl_SOURCES = \
4064         src/journal/coredumpctl.c
4065
4066 coredumpctl_LDADD = \
4067         libsystemd-journal-internal.la \
4068         libsystemd-internal.la \
4069         libsystemd-shared.la
4070
4071 bin_PROGRAMS += \
4072         coredumpctl
4073
4074 manual_tests += \
4075         test-coredump-vacuum
4076
4077 test_coredump_vacuum_SOURCES = \
4078         src/journal/test-coredump-vacuum.c  \
4079         src/journal/coredump-vacuum.c \
4080         src/journal/coredump-vacuum.h
4081
4082 test_coredump_vacuum_LDADD = \
4083         libsystemd-internal.la \
4084         libsystemd-shared.la
4085
4086 dist_bashcompletion_DATA += \
4087         shell-completion/bash/coredumpctl
4088
4089 dist_zshcompletion_DATA += \
4090         shell-completion/zsh/_coredumpctl
4091
4092 GENERAL_ALIASES += \
4093         $(bindir)/coredumpctl $(bindir)/systemd-coredumpctl
4094
4095 sysctl_DATA = \
4096         sysctl.d/50-coredump.conf
4097
4098 CLEANFILES += \
4099         sysctl.d/50-coredump.conf
4100 endif
4101
4102 EXTRA_DIST += \
4103         sysctl.d/50-coredump.conf.in
4104
4105 # ------------------------------------------------------------------------------
4106 if ENABLE_BINFMT
4107 systemd_binfmt_SOURCES = \
4108         src/binfmt/binfmt.c
4109
4110 systemd_binfmt_LDADD = \
4111         libsystemd-shared.la
4112
4113 rootlibexec_PROGRAMS += \
4114         systemd-binfmt
4115
4116 dist_systemunit_DATA += \
4117         units/proc-sys-fs-binfmt_misc.automount \
4118         units/proc-sys-fs-binfmt_misc.mount
4119
4120 nodist_systemunit_DATA += \
4121         units/systemd-binfmt.service
4122
4123 INSTALL_DIRS += \
4124         $(prefix)/lib/binfmt.d \
4125         $(sysconfdir)/binfmt.d
4126
4127 SYSINIT_TARGET_WANTS += \
4128         systemd-binfmt.service \
4129         proc-sys-fs-binfmt_misc.automount
4130
4131 endif
4132
4133 EXTRA_DIST += \
4134         units/systemd-binfmt.service.in
4135
4136 # ------------------------------------------------------------------------------
4137 if ENABLE_VCONSOLE
4138 systemd_vconsole_setup_SOURCES = \
4139         src/vconsole/vconsole-setup.c
4140
4141 systemd_vconsole_setup_LDADD = \
4142         libsystemd-shared.la
4143
4144 rootlibexec_PROGRAMS += \
4145         systemd-vconsole-setup
4146
4147 nodist_systemunit_DATA += \
4148         units/systemd-vconsole-setup.service
4149
4150 SYSINIT_TARGET_WANTS += \
4151         systemd-vconsole-setup.service
4152 endif
4153
4154 EXTRA_DIST += \
4155         units/systemd-vconsole-setup.service.in
4156
4157 # ------------------------------------------------------------------------------
4158 if ENABLE_READAHEAD
4159 systemd_readahead_SOURCES = \
4160         src/readahead/readahead.c \
4161         src/readahead/readahead-collect.c \
4162         src/readahead/readahead-replay.c \
4163         src/readahead/readahead-analyze.c \
4164         src/readahead/readahead-common.c \
4165         src/readahead/readahead-common.h
4166
4167 systemd_readahead_LDADD = \
4168         libsystemd-internal.la \
4169         libudev-internal.la \
4170         libsystemd-shared.la
4171
4172 dist_doc_DATA += \
4173         src/readahead/sd-readahead.c \
4174         src/systemd/sd-readahead.h
4175
4176 rootlibexec_PROGRAMS += \
4177         systemd-readahead
4178
4179 dist_systemunit_DATA += \
4180         units/systemd-readahead-drop.service \
4181         units/systemd-readahead-done.timer
4182
4183 nodist_systemunit_DATA += \
4184         units/systemd-readahead-collect.service \
4185         units/systemd-readahead-replay.service \
4186         units/systemd-readahead-done.service
4187
4188 manual_tests += \
4189         test-ssd
4190
4191 test_ssd_SOURCES = \
4192         src/readahead/test-ssd.c \
4193         src/readahead/readahead-common.c \
4194         src/readahead/readahead-common.h
4195
4196 test_ssd_LDADD = \
4197         libsystemd-internal.la \
4198         libudev-internal.la \
4199         libsystemd-shared.la
4200
4201 endif
4202
4203 EXTRA_DIST += \
4204         units/systemd-readahead-collect.service.in \
4205         units/systemd-readahead-replay.service.in \
4206         units/systemd-readahead-done.service.in
4207
4208 # ------------------------------------------------------------------------------
4209 if ENABLE_BOOTCHART
4210 systemd_bootchart_SOURCES = \
4211         src/bootchart/bootchart.c \
4212         src/bootchart/bootchart.h \
4213         src/bootchart/store.c \
4214         src/bootchart/store.h \
4215         src/bootchart/svg.c \
4216         src/bootchart/svg.h
4217
4218 systemd_bootchart_LDADD = \
4219         libsystemd-journal-internal.la \
4220         libsystemd-shared.la
4221
4222 rootlibexec_PROGRAMS += \
4223         systemd-bootchart
4224
4225 dist_pkgsysconf_DATA += \
4226         src/bootchart/bootchart.conf
4227 endif
4228
4229 # ------------------------------------------------------------------------------
4230 if ENABLE_QUOTACHECK
4231 rootlibexec_PROGRAMS += \
4232         systemd-quotacheck
4233
4234 nodist_systemunit_DATA += \
4235         units/systemd-quotacheck.service
4236
4237 systemd_quotacheck_SOURCES = \
4238         src/quotacheck/quotacheck.c
4239
4240 systemd_quotacheck_LDADD = \
4241         libsystemd-shared.la
4242 endif
4243
4244 EXTRA_DIST += \
4245         units/systemd-quotacheck.service.in
4246
4247 nodist_systemunit_DATA += \
4248         units/quotaon.service
4249
4250 # ------------------------------------------------------------------------------
4251 if ENABLE_RANDOMSEED
4252 rootlibexec_PROGRAMS += \
4253         systemd-random-seed
4254
4255 nodist_systemunit_DATA += \
4256         units/systemd-random-seed.service
4257
4258 systemd_random_seed_SOURCES = \
4259         src/random-seed/random-seed.c
4260
4261 systemd_random_seed_LDADD = \
4262         libsystemd-label.la \
4263         libsystemd-shared.la
4264
4265 SYSINIT_TARGET_WANTS += \
4266         systemd-random-seed.service
4267
4268 endif
4269
4270 EXTRA_DIST += \
4271         units/systemd-random-seed.service.in
4272
4273 # ------------------------------------------------------------------------------
4274 if ENABLE_BACKLIGHT
4275 rootlibexec_PROGRAMS += \
4276         systemd-backlight
4277
4278 nodist_systemunit_DATA += \
4279         units/systemd-backlight@.service
4280
4281 systemd_backlight_SOURCES = \
4282         src/backlight/backlight.c
4283
4284 systemd_backlight_LDADD = \
4285         libsystemd-label.la \
4286         libudev-internal.la \
4287         libsystemd-shared.la
4288 endif
4289
4290 EXTRA_DIST += \
4291         units/systemd-backlight@.service.in
4292
4293 # ------------------------------------------------------------------------------
4294 if ENABLE_RFKILL
4295 rootlibexec_PROGRAMS += \
4296         systemd-rfkill
4297
4298 nodist_systemunit_DATA += \
4299         units/systemd-rfkill@.service
4300
4301 systemd_rfkill_SOURCES = \
4302         src/rfkill/rfkill.c
4303
4304 systemd_rfkill_LDADD = \
4305         libsystemd-label.la \
4306         libudev-internal.la \
4307         libsystemd-shared.la
4308 endif
4309
4310 EXTRA_DIST += \
4311         units/systemd-rfkill@.service.in
4312
4313 # ------------------------------------------------------------------------------
4314 if HAVE_LIBCRYPTSETUP
4315 rootlibexec_PROGRAMS += \
4316         systemd-cryptsetup
4317
4318 systemgenerator_PROGRAMS += \
4319         systemd-cryptsetup-generator
4320
4321 dist_systemunit_DATA += \
4322         units/cryptsetup.target \
4323         units/cryptsetup-pre.target
4324
4325 systemd_cryptsetup_SOURCES = \
4326         src/cryptsetup/cryptsetup.c
4327
4328 systemd_cryptsetup_CFLAGS = \
4329         $(AM_CFLAGS) \
4330         $(LIBCRYPTSETUP_CFLAGS)
4331
4332 systemd_cryptsetup_LDADD = \
4333         libsystemd-label.la \
4334         libudev-internal.la \
4335         libsystemd-shared.la \
4336         $(LIBCRYPTSETUP_LIBS)
4337
4338 systemd_cryptsetup_generator_SOURCES = \
4339         src/cryptsetup/cryptsetup-generator.c
4340
4341 systemd_cryptsetup_generator_LDADD = \
4342         libsystemd-label.la \
4343         libsystemd-shared.la
4344
4345 SYSINIT_TARGET_WANTS += \
4346         cryptsetup.target
4347
4348 endif
4349
4350 # ------------------------------------------------------------------------------
4351 if ENABLE_HOSTNAMED
4352 systemd_hostnamed_SOURCES = \
4353         src/hostname/hostnamed.c
4354
4355 systemd_hostnamed_LDADD = \
4356         libsystemd-label.la \
4357         libsystemd-internal.la \
4358         libsystemd-shared.la
4359
4360 rootlibexec_PROGRAMS += \
4361         systemd-hostnamed
4362
4363 nodist_systemunit_DATA += \
4364         units/systemd-hostnamed.service
4365
4366 dist_systemunit_DATA += \
4367         units/org.freedesktop.hostname1.busname
4368
4369 dist_dbuspolicy_DATA += \
4370         src/hostname/org.freedesktop.hostname1.conf
4371
4372 dist_dbussystemservice_DATA += \
4373         src/hostname/org.freedesktop.hostname1.service
4374
4375 polkitpolicy_files += \
4376         src/hostname/org.freedesktop.hostname1.policy
4377
4378 SYSTEM_UNIT_ALIASES += \
4379         systemd-hostnamed.service dbus-org.freedesktop.hostname1.service
4380
4381 BUSNAMES_TARGET_WANTS += \
4382         org.freedesktop.hostname1.busname
4383
4384 hostnamectl_SOURCES = \
4385         src/hostname/hostnamectl.c
4386
4387 hostnamectl_LDADD = \
4388         libsystemd-internal.la \
4389         libsystemd-shared.la
4390
4391 bin_PROGRAMS += \
4392         hostnamectl
4393
4394 dist_bashcompletion_DATA += \
4395         shell-completion/bash/hostnamectl
4396
4397 dist_zshcompletion_DATA += \
4398         shell-completion/zsh/_hostnamectl
4399
4400 endif
4401
4402 polkitpolicy_in_files += \
4403         src/hostname/org.freedesktop.hostname1.policy.in
4404
4405 EXTRA_DIST += \
4406         units/systemd-hostnamed.service.in
4407
4408 # ------------------------------------------------------------------------------
4409 if ENABLE_KDBUS
4410 dist_systemunit_DATA += \
4411         units/org.freedesktop.systemd1.busname
4412
4413 BUSNAMES_TARGET_WANTS += \
4414         org.freedesktop.systemd1.busname
4415 endif
4416
4417 # ------------------------------------------------------------------------------
4418 if ENABLE_LOCALED
4419 systemd_localed_SOURCES = \
4420         src/locale/localed.c
4421
4422 systemd_localed_LDADD = \
4423         libsystemd-label.la \
4424         libsystemd-internal.la \
4425         libsystemd-shared.la
4426
4427 nodist_systemunit_DATA += \
4428         units/systemd-localed.service
4429
4430 dist_systemunit_DATA += \
4431         units/org.freedesktop.locale1.busname
4432
4433 rootlibexec_PROGRAMS += \
4434         systemd-localed
4435
4436 dist_dbuspolicy_DATA += \
4437         src/locale/org.freedesktop.locale1.conf
4438
4439 dist_dbussystemservice_DATA += \
4440         src/locale/org.freedesktop.locale1.service
4441
4442 polkitpolicy_files += \
4443         src/locale/org.freedesktop.locale1.policy
4444
4445 SYSTEM_UNIT_ALIASES += \
4446         systemd-localed.service dbus-org.freedesktop.locale1.service
4447
4448 BUSNAMES_TARGET_WANTS += \
4449         org.freedesktop.locale1.busname
4450
4451 dist_pkgdata_DATA += \
4452         src/locale/kbd-model-map
4453
4454 dist_noinst_SCRIPT = \
4455         src/locale/generate-kbd-model-map
4456
4457 localectl_SOURCES = \
4458         src/locale/localectl.c
4459
4460 localectl_LDADD = \
4461         libsystemd-internal.la \
4462         libsystemd-shared.la
4463
4464 bin_PROGRAMS += \
4465         localectl
4466
4467 dist_bashcompletion_DATA += \
4468         shell-completion/bash/localectl
4469
4470 dist_zshcompletion_DATA += \
4471         shell-completion/zsh/_localectl
4472
4473 endif
4474
4475 .PHONY: update-kbd-model-map
4476
4477 polkitpolicy_in_files += \
4478         src/locale/org.freedesktop.locale1.policy.in
4479
4480 EXTRA_DIST += \
4481         units/systemd-localed.service.in
4482
4483 # ------------------------------------------------------------------------------
4484 if ENABLE_TIMEDATED
4485 systemd_timedated_SOURCES = \
4486         src/timedate/timedated.c
4487
4488 systemd_timedated_LDADD = \
4489         libsystemd-label.la \
4490         libsystemd-internal.la \
4491         libsystemd-shared.la
4492
4493 rootlibexec_PROGRAMS += \
4494         systemd-timedated
4495
4496 dist_dbussystemservice_DATA += \
4497         src/timedate/org.freedesktop.timedate1.service
4498
4499 dist_dbuspolicy_DATA += \
4500         src/timedate/org.freedesktop.timedate1.conf
4501
4502 nodist_systemunit_DATA += \
4503         units/systemd-timedated.service
4504
4505 dist_systemunit_DATA += \
4506         units/org.freedesktop.timedate1.busname
4507
4508 polkitpolicy_files += \
4509         src/timedate/org.freedesktop.timedate1.policy
4510
4511 SYSTEM_UNIT_ALIASES += \
4512         systemd-timedated.service dbus-org.freedesktop.timedate1.service
4513
4514 BUSNAMES_TARGET_WANTS += \
4515         org.freedesktop.timedate1.busname
4516
4517 timedatectl_SOURCES = \
4518         src/timedate/timedatectl.c
4519
4520 timedatectl_LDADD = \
4521         libsystemd-internal.la \
4522         libsystemd-shared.la
4523
4524 bin_PROGRAMS += \
4525         timedatectl
4526
4527 dist_bashcompletion_DATA += \
4528         shell-completion/bash/timedatectl
4529
4530 dist_zshcompletion_DATA += \
4531         shell-completion/zsh/_timedatectl
4532 endif
4533
4534 polkitpolicy_in_files += \
4535         src/timedate/org.freedesktop.timedate1.policy.in
4536
4537 EXTRA_DIST += \
4538         units/systemd-timedated.service.in
4539
4540 # ------------------------------------------------------------------------------
4541 if ENABLE_TIMESYNCD
4542 systemd_timesyncd_SOURCES = \
4543         src/timesync/timesyncd.c \
4544         src/timesync/timesyncd.h
4545
4546 nodist_systemd_timesyncd_SOURCES = \
4547         src/timesync/timesyncd-gperf.c
4548
4549 EXTRA_DIST += \
4550         src/timesync/timesyncd-gperf.gperf
4551
4552 CLEANFILES += \
4553         src/timesync/timesyncd-gperf.c
4554
4555 systemd_timesyncd_LDADD = \
4556         libsystemd-resolve.la \
4557         libsystemd-network.la \
4558         libsystemd-label.la \
4559         libsystemd-capability.la \
4560         libsystemd-internal.la \
4561         libsystemd-shared.la \
4562         -lm
4563
4564 rootlibexec_PROGRAMS += \
4565         systemd-timesyncd
4566
4567 nodist_systemunit_DATA += \
4568         units/systemd-timesyncd.service
4569
4570 GENERAL_ALIASES += \
4571         $(systemunitdir)/systemd-timesyncd.service $(pkgsysconfdir)/system/sysinit.target.wants/systemd-timesyncd.service
4572
4573 EXTRA_DIST += \
4574         units/systemd-timesyncd.service.in
4575
4576 nodist_pkgsysconf_DATA += \
4577         src/timesync/timesyncd.conf
4578
4579 EXTRA_DIST += \
4580         src/timesync/timesyncd.conf.in
4581
4582 CLEANFILES += \
4583         src/timesync/timesyncd.conf
4584 endif
4585
4586 # ------------------------------------------------------------------------------
4587 if HAVE_MYHOSTNAME
4588 libnss_myhostname_la_SOURCES = \
4589         src/nss-myhostname/nss-myhostname.sym \
4590         src/nss-myhostname/nss-myhostname.c
4591
4592 libnss_myhostname_la_LDFLAGS = \
4593         $(AM_LDFLAGS) \
4594         -module \
4595         -export-dynamic \
4596         -avoid-version \
4597         -shared \
4598         -shrext .so.2 \
4599         -Wl,--version-script=$(top_srcdir)/src/nss-myhostname/nss-myhostname.sym
4600
4601 libnss_myhostname_la_LIBADD = \
4602         libsystemd-shared.la \
4603         libsystemd-internal.la
4604
4605 lib_LTLIBRARIES += \
4606         libnss_myhostname.la
4607 endif
4608
4609 # ------------------------------------------------------------------------------
4610 if ENABLE_MACHINED
4611 systemd_machined_SOURCES = \
4612         src/machine/machined.c \
4613         src/machine/machined.h
4614