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