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