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