chiark / gitweb /
directive-index: journal directives
[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 #
8 #  systemd is free software; you can redistribute it and/or modify it
9 #  under the terms of the GNU Lesser General Public License as published by
10 #  the Free Software Foundation; either version 2.1 of the License, or
11 #  (at your option) any later version.
12 #
13 #  systemd is distributed in the hope that it will be useful, but
14 #  WITHOUT ANY WARRANTY; without even the implied warranty of
15 #  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 #  Lesser General Public License for more details.
17 #
18 #  You should have received a copy of the GNU Lesser General Public License
19 #  along with systemd; If not, see <http://www.gnu.org/licenses/>.
20
21 ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
22 AM_MAKEFLAGS = --no-print-directory
23
24 SUBDIRS = . po
25
26 # remove targets if the command fails
27 .DELETE_ON_ERROR:
28
29 LIBUDEV_CURRENT=2
30 LIBUDEV_REVISION=0
31 LIBUDEV_AGE=1
32
33 LIBGUDEV_CURRENT=1
34 LIBGUDEV_REVISION=2
35 LIBGUDEV_AGE=1
36
37 LIBSYSTEMD_LOGIN_CURRENT=3
38 LIBSYSTEMD_LOGIN_REVISION=3
39 LIBSYSTEMD_LOGIN_AGE=3
40
41 LIBSYSTEMD_DAEMON_CURRENT=0
42 LIBSYSTEMD_DAEMON_REVISION=4
43 LIBSYSTEMD_DAEMON_AGE=0
44
45 LIBSYSTEMD_ID128_CURRENT=0
46 LIBSYSTEMD_ID128_REVISION=9
47 LIBSYSTEMD_ID128_AGE=0
48
49 LIBSYSTEMD_JOURNAL_CURRENT=4
50 LIBSYSTEMD_JOURNAL_REVISION=1
51 LIBSYSTEMD_JOURNAL_AGE=4
52
53 # Dirs of external packages
54 dbuspolicydir=@dbuspolicydir@
55 dbussessionservicedir=@dbussessionservicedir@
56 dbussystemservicedir=@dbussystemservicedir@
57 dbusinterfacedir=@dbusinterfacedir@
58 pamlibdir=@pamlibdir@
59 pkgconfigdatadir=$(datadir)/pkgconfig
60 pkgconfiglibdir=$(libdir)/pkgconfig
61 polkitpolicydir=$(datadir)/polkit-1/actions
62 bashcompletiondir=$(sysconfdir)/bash_completion.d
63 rpmmacrosdir=$(sysconfdir)/rpm
64
65 # Our own, non-special dirs
66 pkgsysconfdir=$(sysconfdir)/systemd
67 userunitdir=$(prefix)/lib/systemd/user
68 userpresetdir=$(prefix)/lib/systemd/user-preset
69 tmpfilesdir=$(prefix)/lib/tmpfiles.d
70 sysctldir=$(prefix)/lib/sysctl.d
71 usergeneratordir=$(prefix)/lib/systemd/user-generators
72 pkgincludedir=$(includedir)/systemd
73 systemgeneratordir=$(rootlibexecdir)/system-generators
74 systemshutdowndir=$(rootlibexecdir)/system-shutdown
75 systemsleepdir=$(rootlibexecdir)/system-sleep
76 systemunitdir=$(rootprefix)/lib/systemd/system
77 systempresetdir=$(rootprefix)/lib/systemd/system-preset
78 udevlibexecdir=$(rootprefix)/lib/udev
79 udevhomedir = $(udevlibexecdir)
80 udevrulesdir = $(udevlibexecdir)/rules.d
81
82 # And these are the special ones for /
83 rootprefix=@rootprefix@
84 rootbindir=$(rootprefix)/bin
85 rootlibexecdir=$(rootprefix)/lib/systemd
86
87 CLEANFILES = $(BUILT_SOURCES)
88 EXTRA_DIST =
89 BUILT_SOURCES =
90 INSTALL_EXEC_HOOKS =
91 UNINSTALL_EXEC_HOOKS =
92 INSTALL_DATA_HOOKS =
93 DISTCLEAN_LOCAL_HOOKS =
94 pkginclude_HEADERS =
95 noinst_LTLIBRARIES =
96 lib_LTLIBRARIES =
97 include_HEADERS =
98 pkgconfiglib_DATA =
99 polkitpolicy_in_files =
100 polkitpolicy_files =
101 dist_udevrules_DATA =
102 nodist_udevrules_DATA =
103 dist_man_MANS =
104 dist_pkgsysconf_DATA =
105 dist_pkgdata_DATA =
106 dist_dbuspolicy_DATA =
107 dbusinterface_DATA =
108 dist_dbussystemservice_DATA =
109 check_PROGRAMS =
110 check_DATA =
111 noinst_PROGRAMS =
112 TESTS =
113 udevlibexec_PROGRAMS =
114
115 AM_CPPFLAGS = \
116         -include $(top_builddir)/config.h \
117         -DSYSCONFDIR=\""$(sysconfdir)"\" \
118         -DSYSTEM_CONFIG_FILE=\"$(pkgsysconfdir)/system.conf\" \
119         -DSYSTEM_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/system\" \
120         -DSYSTEM_DATA_UNIT_PATH=\"$(systemunitdir)\" \
121         -DSYSTEM_SYSVINIT_PATH=\"$(SYSTEM_SYSVINIT_PATH)\" \
122         -DSYSTEM_SYSVRCND_PATH=\"$(SYSTEM_SYSVRCND_PATH)\" \
123         -DUSER_CONFIG_FILE=\"$(pkgsysconfdir)/user.conf\" \
124         -DUSER_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/user\" \
125         -DUSER_DATA_UNIT_PATH=\"$(userunitdir)\" \
126         -DSYSTEMD_CGROUP_AGENT_PATH=\"$(rootlibexecdir)/systemd-cgroups-agent\" \
127         -DSYSTEMD_BINARY_PATH=\"$(rootlibexecdir)/systemd\" \
128         -DSYSTEMD_SHUTDOWN_BINARY_PATH=\"$(rootlibexecdir)/systemd-shutdown\" \
129         -DSYSTEMD_SLEEP_BINARY_PATH=\"$(rootlibexecdir)/systemd-sleep\" \
130         -DSYSTEMCTL_BINARY_PATH=\"$(rootbindir)/systemctl\" \
131         -DSYSTEMD_TTY_ASK_PASSWORD_AGENT_BINARY_PATH=\"$(rootbindir)/systemd-tty-ask-password-agent\" \
132         -DSYSTEMD_STDIO_BRIDGE_BINARY_PATH=\"$(bindir)/systemd-stdio-bridge\" \
133         -DROOTPREFIX=\"$(rootprefix)\" \
134         -DRUNTIME_DIR=\"/run\" \
135         -DRANDOM_SEED=\"$(localstatedir)/lib/random-seed\" \
136         -DSYSTEMD_CRYPTSETUP_PATH=\"$(rootlibexecdir)/systemd-cryptsetup\" \
137         -DSYSTEM_GENERATOR_PATH=\"$(systemgeneratordir)\" \
138         -DUSER_GENERATOR_PATH=\"$(usergeneratordir)\" \
139         -DSYSTEM_SHUTDOWN_PATH=\"$(systemshutdowndir)\" \
140         -DSYSTEM_SLEEP_PATH=\"$(systemsleepdir)\" \
141         -DSYSTEMD_KBD_MODEL_MAP=\"$(pkgdatadir)/kbd-model-map\" \
142         -DX_SERVER=\"$(bindir)/X\" \
143         -DUDEVLIBEXECDIR=\"$(udevlibexecdir)\" \
144         -DPOLKIT_AGENT_BINARY_PATH=\"$(bindir)/pkttyagent\" \
145         -I $(top_srcdir)/src \
146         -I $(top_srcdir)/src/shared \
147         -I $(top_srcdir)/src/login \
148         -I $(top_srcdir)/src/journal \
149         -I $(top_srcdir)/src/systemd \
150         -I $(top_builddir)/src/core \
151         -I $(top_srcdir)/src/core \
152         -I $(top_srcdir)/src/libudev \
153         -I $(top_srcdir)/src/udev \
154         $(OUR_CPPFLAGS)
155
156 AM_CFLAGS = $(OUR_CFLAGS)
157 AM_LDFLAGS = $(OUR_LDFLAGS)
158
159 # ------------------------------------------------------------------------------
160 if TARGET_GENTOO
161 AM_CPPFLAGS += \
162         -DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
163         -DKBD_SETFONT=\"/usr/bin/setfont\" \
164         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
165 else
166 if TARGET_ARCH
167 AM_CPPFLAGS += \
168         -DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
169         -DKBD_SETFONT=\"/usr/bin/setfont\" \
170         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
171 else
172 if TARGET_FRUGALWARE
173 AM_CPPFLAGS += \
174         -DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
175         -DKBD_SETFONT=\"/usr/bin/setfont\" \
176         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
177 else
178 if TARGET_MANDRIVA
179 AM_CPPFLAGS += \
180         -DKBD_LOADKEYS=\"/bin/loadkeys\" \
181         -DKBD_SETFONT=\"/bin/setfont\" \
182         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
183 else
184 if TARGET_ANGSTROM
185 AM_CPPFLAGS += \
186         -DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
187         -DKBD_SETFONT=\"/usr/bin/setfont\" \
188         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
189 else
190 if TARGET_MAGEIA
191 AM_CPPFLAGS += \
192         -DKBD_LOADKEYS=\"/bin/loadkeys\" \
193         -DKBD_SETFONT=\"/bin/setfont\" \
194         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
195 else
196 AM_CPPFLAGS += \
197         -DKBD_LOADKEYS=\"/bin/loadkeys\" \
198         -DKBD_SETFONT=\"/bin/setfont\" \
199         -DDEFAULT_FONT=\"latarcyrheb-sun16\"
200 endif
201 endif
202 endif
203 endif
204 endif
205 endif
206
207 # ------------------------------------------------------------------------------
208 rootbin_PROGRAMS = \
209         systemctl \
210         systemd-notify \
211         systemd-ask-password \
212         systemd-tty-ask-password-agent \
213         systemd-tmpfiles \
214         systemd-machine-id-setup
215
216 bin_PROGRAMS = \
217         systemd-cgls \
218         systemd-cgtop \
219         systemd-stdio-bridge \
220         systemd-nspawn \
221         systemd-detect-virt \
222         systemd-delta
223
224 dist_bin_SCRIPTS = \
225         src/analyze/systemd-analyze
226
227 rootlibexec_PROGRAMS = \
228         systemd \
229         systemd-cgroups-agent \
230         systemd-initctl \
231         systemd-update-utmp \
232         systemd-shutdownd \
233         systemd-shutdown \
234         systemd-modules-load \
235         systemd-remount-fs \
236         systemd-reply-password \
237         systemd-fsck \
238         systemd-timestamp \
239         systemd-ac-power \
240         systemd-sysctl \
241         systemd-sleep
242
243 systemgenerator_PROGRAMS = \
244         systemd-getty-generator \
245         systemd-fstab-generator \
246         systemd-system-update-generator
247
248 dist_bashcompletion_DATA = \
249         bash-completion/systemd-bash-completion.sh
250
251 dist_tmpfiles_DATA = \
252         tmpfiles.d/systemd.conf \
253         tmpfiles.d/tmp.conf \
254         tmpfiles.d/x11.conf
255
256 if HAVE_SYSV_COMPAT
257 dist_tmpfiles_DATA += \
258         tmpfiles.d/legacy.conf
259 endif
260
261 dist_systemunit_DATA = \
262         units/graphical.target \
263         units/multi-user.target \
264         units/emergency.service \
265         units/emergency.target \
266         units/sysinit.target \
267         units/basic.target \
268         units/getty.target \
269         units/halt.target \
270         units/kexec.target \
271         units/local-fs.target \
272         units/local-fs-pre.target \
273         units/remote-fs.target \
274         units/remote-fs-pre.target \
275         units/network.target \
276         units/nss-lookup.target \
277         units/nss-user-lookup.target \
278         units/mail-transfer-agent.target \
279         units/hibernate.target \
280         units/http-daemon.target \
281         units/poweroff.target \
282         units/reboot.target \
283         units/rescue.target \
284         units/rpcbind.target \
285         units/time-sync.target \
286         units/shutdown.target \
287         units/final.target \
288         units/umount.target \
289         units/sigpwr.target \
290         units/sleep.target \
291         units/sockets.target \
292         units/suspend.target \
293         units/swap.target \
294         units/systemd-initctl.socket \
295         units/systemd-shutdownd.socket \
296         units/syslog.socket \
297         units/dev-hugepages.mount \
298         units/dev-mqueue.mount \
299         units/sys-kernel-config.mount \
300         units/sys-kernel-debug.mount \
301         units/sys-fs-fuse-connections.mount \
302         units/tmp.mount \
303         units/printer.target \
304         units/sound.target \
305         units/bluetooth.target \
306         units/smartcard.target \
307         units/systemd-tmpfiles-clean.timer \
308         units/quotaon.service \
309         units/systemd-ask-password-wall.path \
310         units/systemd-ask-password-console.path \
311         units/syslog.target \
312         units/systemd-udevd-control.socket \
313         units/systemd-udevd-kernel.socket \
314         units/system-update.target
315
316 nodist_systemunit_DATA = \
317         units/getty@.service \
318         units/serial-getty@.service \
319         units/console-shell.service \
320         units/console-getty.service \
321         units/systemd-initctl.service \
322         units/systemd-shutdownd.service \
323         units/systemd-modules-load.service \
324         units/systemd-remount-fs.service \
325         units/systemd-update-utmp-runlevel.service \
326         units/systemd-update-utmp-shutdown.service \
327         units/systemd-tmpfiles-setup.service \
328         units/systemd-tmpfiles-clean.service \
329         units/systemd-ask-password-wall.service \
330         units/systemd-ask-password-console.service \
331         units/systemd-sysctl.service \
332         units/emergency.service \
333         units/rescue.service \
334         units/user@.service \
335         units/systemd-hibernate.service \
336         units/systemd-suspend.service \
337         units/systemd-halt.service \
338         units/systemd-poweroff.service \
339         units/systemd-reboot.service \
340         units/systemd-kexec.service \
341         units/systemd-fsck@.service \
342         units/systemd-fsck-root.service \
343         units/systemd-udevd.service \
344         units/systemd-udev-trigger.service \
345         units/systemd-udev-settle.service \
346         units/debug-shell.service
347
348 dist_userunit_DATA = \
349         units/user/default.target \
350         units/user/exit.target
351
352 nodist_userunit_DATA = \
353         units/user/systemd-exit.service
354
355 EXTRA_DIST += \
356         units/getty@.service.m4 \
357         units/serial-getty@.service.m4 \
358         units/console-shell.service.m4.in \
359         units/console-getty.service.m4.in \
360         units/rescue.service.m4.in \
361         units/systemd-initctl.service.in \
362         units/systemd-shutdownd.service.in \
363         units/systemd-modules-load.service.in \
364         units/systemd-remount-fs.service.in \
365         units/systemd-update-utmp-runlevel.service.in \
366         units/systemd-update-utmp-shutdown.service.in \
367         units/systemd-tmpfiles-setup.service.in \
368         units/systemd-tmpfiles-clean.service.in \
369         units/systemd-ask-password-wall.service.in \
370         units/systemd-ask-password-console.service.in \
371         units/systemd-sysctl.service.in \
372         units/emergency.service.in \
373         units/systemd-halt.service.in \
374         units/systemd-poweroff.service.in \
375         units/systemd-reboot.service.in \
376         units/systemd-kexec.service.in \
377         units/user/systemd-exit.service.in \
378         units/systemd-fsck@.service.in \
379         units/systemd-fsck-root.service.in \
380         units/user@.service.in \
381         units/systemd-udevd.service \
382         units/systemd-udev-trigger.service \
383         units/systemd-udev-settle.service \
384         units/debug-shell.service.in \
385         units/systemd-hibernate.service.in \
386         units/systemd-suspend.service.in \
387         units/quotaon.service.in \
388         introspect.awk \
389         man/custom-html.xsl
390
391 if TARGET_FEDORA
392 dist_systemunit_DATA += \
393         units/fedora/rc-local.service \
394         units/fedora/halt-local.service
395 systemgenerator_PROGRAMS += \
396         systemd-rc-local-generator
397 endif
398
399 if TARGET_MANDRIVA
400 dist_systemunit_DATA += \
401         units/fedora/rc-local.service \
402         units/fedora/halt-local.service
403 systemgenerator_PROGRAMS += \
404         systemd-rc-local-generator
405 endif
406
407 if TARGET_FRUGALWARE
408 dist_systemunit_DATA += \
409         units/frugalware/display-manager.service
410 endif
411
412 if TARGET_SUSE
413 dist_systemunit_DATA += \
414         units/suse/rc-local.service \
415         units/suse/halt-local.service
416 systemgenerator_PROGRAMS += \
417         systemd-rc-local-generator
418 endif
419
420 if TARGET_MAGEIA
421 dist_systemunit_DATA += \
422         units/fedora/rc-local.service \
423         units/fedora/halt-local.service
424 systemgenerator_PROGRAMS += \
425         systemd-rc-local-generator
426 endif
427
428 dist_doc_DATA = \
429         README \
430         NEWS \
431         LICENSE.LGPL2.1 \
432         LICENSE.GPL2 \
433         LICENSE.MIT \
434         DISTRO_PORTING
435
436 @INTLTOOL_POLICY_RULE@
437
438 # ------------------------------------------------------------------------------
439 MANPAGES = \
440         man/systemd.1 \
441         man/systemctl.1 \
442         man/systemd-cgls.1 \
443         man/systemd-delta.1 \
444         man/systemd-cgtop.1 \
445         man/systemd-nspawn.1 \
446         man/systemd-tmpfiles.8 \
447         man/systemd-notify.1 \
448         man/systemd.unit.5 \
449         man/systemd.service.5 \
450         man/systemd.socket.5 \
451         man/systemd.mount.5 \
452         man/systemd.automount.5 \
453         man/systemd.swap.5 \
454         man/systemd.timer.5 \
455         man/systemd.path.5 \
456         man/systemd.target.5 \
457         man/systemd.device.5 \
458         man/systemd.snapshot.5 \
459         man/systemd.exec.5 \
460         man/systemd.kill.5 \
461         man/systemd.special.7 \
462         man/systemd.journal-fields.7 \
463         man/kernel-command-line.7 \
464         man/daemon.7 \
465         man/bootup.7 \
466         man/runlevel.8 \
467         man/telinit.8 \
468         man/halt.8 \
469         man/shutdown.8 \
470         man/pam_systemd.8 \
471         man/systemd.conf.5 \
472         man/tmpfiles.d.5 \
473         man/hostname.5 \
474         man/localtime.5 \
475         man/machine-id.5 \
476         man/locale.conf.5 \
477         man/os-release.5 \
478         man/machine-info.5 \
479         man/modules-load.d.5 \
480         man/systemd-modules-load.service.8 \
481         man/sysctl.d.5 \
482         man/systemd-sysctl.service.8 \
483         man/systemd-ask-password.1 \
484         man/systemd-cat.1 \
485         man/systemd-machine-id-setup.1 \
486         man/systemd-detect-virt.1 \
487         man/journald.conf.5 \
488         man/systemd-journald.service.8 \
489         man/journalctl.1 \
490         man/systemd-inhibit.1 \
491         man/systemd-remount-fs.service.8 \
492         man/systemd-update-utmp-runlevel.service.8 \
493         man/systemd-initctl.service.8 \
494         man/systemd-shutdownd.service.8 \
495         man/systemd-suspend.service.8 \
496         man/systemd-halt.service.8 \
497         man/systemd-fsck@.service.8 \
498         man/systemd-ask-password-console.service.8 \
499         man/systemd-analyze.1 \
500         man/systemd-tty-ask-password-agent.1 \
501         man/systemd-getty-generator.8 \
502         man/systemd-system-update-generator.8 \
503         man/systemd-fstab-generator.8 \
504         man/systemd.preset.5 \
505         man/sd-id128.3 \
506         man/sd_id128_to_string.3 \
507         man/sd_id128_randomize.3 \
508         man/sd_id128_get_machine.3 \
509         man/sd-journal.3 \
510         man/sd_journal_print.3 \
511         man/sd_journal_stream_fd.3 \
512         man/sd_journal_open.3 \
513         man/sd_journal_next.3 \
514         man/sd_journal_get_data.3 \
515         man/sd_journal_get_realtime_usec.3 \
516         man/sd_journal_get_cutoff_realtime_usec.3 \
517         man/sd_journal_get_cursor.3 \
518         man/sd_journal_get_fd.3 \
519         man/sd_journal_get_usage.3 \
520         man/sd_journal_add_match.3 \
521         man/sd_journal_seek_head.3
522
523 MANPAGES_ALIAS = \
524         man/reboot.8 \
525         man/poweroff.8 \
526         man/init.1 \
527         man/systemd-modules-load.8 \
528         man/systemd-sysctl.8 \
529         man/systemd-journald.socket.8 \
530         man/systemd-journald.8 \
531         man/systemd-remount-fs.8 \
532         man/systemd-update-utmp-shutdown.service.8 \
533         man/systemd-update-utmp.8 \
534         man/systemd-initctl.socket.8 \
535         man/systemd-initctl.8 \
536         man/systemd-shutdownd.socket.8 \
537         man/systemd-shutdownd.8 \
538         man/systemd-hibernate.service.8 \
539         man/systemd-sleep.8 \
540         man/systemd-shutdown.8 \
541         man/systemd-poweroff.service.8 \
542         man/systemd-reboot.service.8 \
543         man/systemd-kexec.service.8 \
544         man/systemd-fsck.8 \
545         man/systemd-fsck-root.service.8 \
546         man/systemd-ask-password-console.path.8 \
547         man/systemd-ask-password-wall.service.8 \
548         man/systemd-ask-password-wall.path.8 \
549         man/systemd-tmpfiles-setup.service.8 \
550         man/systemd-tmpfiles-clean.service.8 \
551         man/systemd-tmpfiles-clean.timer.8 \
552         man/sd_id128_t.3 \
553         man/SD_ID128_MAKE.3 \
554         man/SD_ID128_FORMAT_STR.3 \
555         man/SD_ID128_FORMAT_VAL.3 \
556         man/sd_id128_equal.3 \
557         man/sd_id128_from_string.3 \
558         man/sd_id128_get_boot.3 \
559         man/sd_journal_printv.3 \
560         man/sd_journal_send.3 \
561         man/sd_journal_sendv.3 \
562         man/sd_journal_perror.3 \
563         man/SD_JOURNAL_SUPPRESS_LOCATION.3 \
564         man/sd_journal_open_directory.3 \
565         man/sd_journal_close.3 \
566         man/sd_journal.3 \
567         man/SD_JOURNAL_RUNTIME_ONLY.3 \
568         man/SD_JOURNAL_SYSTEM_ONLY.3 \
569         man/SD_JOURNAL_LOCAL_ONLY.3 \
570         man/sd_journal_previous.3 \
571         man/sd_journal_next_skip.3 \
572         man/sd_journal_previous_skip.3 \
573         man/SD_JOURNAL_FOREACH.3 \
574         man/SD_JOURNAL_FOREACH_BACKWARDS.3 \
575         man/sd_journal_enumerate_data.3 \
576         man/sd_journal_restart_data.3 \
577         man/SD_JOURNAL_FOREACH_DATA.3 \
578         man/sd_journal_get_monotonic_usec.3 \
579         man/sd_journal_get_cutoff_monotonic_usec.3 \
580         man/sd_journal_process.3 \
581         man/sd_journal_wait.3 \
582         man/SD_JOURNAL_NOP.3 \
583         man/SD_JOURNAL_APPEND.3 \
584         man/SD_JOURNAL_INVALIDATE.3 \
585         man/sd_journal_add_disjunction.3 \
586         man/sd_journal_flush_matches.3 \
587         man/sd_journal_seek_tail.3 \
588         man/sd_journal_seek_monotonic_usec.3 \
589         man/sd_journal_seek_realtime_usec.3 \
590         man/sd_journal_seek_cursor.3
591
592 man/reboot.8: man/halt.8
593 man/poweroff.8: man/halt.8
594 man/init.1: man/systemd.1
595 man/systemd-modules-load.8: man/systemd-modules-load.service.8
596 man/systemd-sysctl.8: man/systemd-sysctl.service.8
597 man/systemd-journald.socket.8: man/systemd-journald.service.8
598 man/systemd-journald.8: man/systemd-journald.service.8
599 man/systemd-remount-fs.8: man/systemd-remount-fs.service.8
600 man/systemd-update-utmp-shutdown.service.8: man/systemd-update-utmp-runlevel.service.8
601 man/systemd-update-utmp.8: man/systemd-update-utmp-runlevel.service.8
602 man/systemd-initctl.socket.8: man/systemd-initctl.service.8
603 man/systemd-initctl.8: man/systemd-initctl.service.8
604 man/systemd-shutdownd.socket.8: man/systemd-shutdownd.service.8
605 man/systemd-shutdownd.8: man/systemd-shutdownd.service.8
606 man/systemd-hibernate.service.8: man/systemd-suspend.service.8
607 man/systemd-sleep.8: man/systemd-suspend.service.8
608 man/systemd-shutdown.8: man/systemd-halt.service.8
609 man/systemd-poweroff.service.8: man/systemd-halt.service.8
610 man/systemd-reboot.service.8: man/systemd-halt.service.8
611 man/systemd-kexec.service.8: man/systemd-halt.service.8
612 man/systemd-fsck.8: man/systemd-fsck@.service.8
613 man/systemd-fsck-root.service.8: man/systemd-fsck@.service.8
614 man/systemd-ask-password-console.path.8: man/systemd-ask-password-console.service.8
615 man/systemd-ask-password-wall.service.8: man/systemd-ask-password-console.service.8
616 man/systemd-ask-password-wall.path.8: man/systemd-ask-password-console.service.8
617 man/systemd-tmpfiles-setup.service.8: man/systemd-tmpfiles.8
618 man/systemd-tmpfiles-clean.service.8: man/systemd-tmpfiles.8
619 man/systemd-tmpfiles-clean.timer.8: man/systemd-tmpfiles.8
620 man/sd_id128_t.3: man/sd-id128.3
621 man/SD_ID128_MAKE.3: man/sd-id128.3
622 man/SD_ID128_FORMAT_STR.3: man/sd-id128.3
623 man/SD_ID128_FORMAT_VAL.3: man/sd-id128.3
624 man/sd_id128_equal.3: man/sd-id128.3
625 man/sd_id128_from_string.3: man/sd_id128_to_string.3
626 man/sd_id128_get_boot.3: man/sd_id128_get_machine.3
627 man/sd_journal_printv.3: man/sd_journal_print.3
628 man/sd_journal_send.3: man/sd_journal_print.3
629 man/sd_journal_sendv.3: man/sd_journal_print.3
630 man/sd_journal_perror.3: man/sd_journal_print.3
631 man/SD_JOURNAL_SUPPRESS_LOCATION.3: man/sd_journal_print.3
632 man/sd_journal_open_directory.3: man/sd_journal_open.3
633 man/sd_journal_close.3: man/sd_journal_open.3
634 man/sd_journal.3: man/sd_journal_open.3
635 man/SD_JOURNAL_RUNTIME_ONLY.3: man/sd_journal_open.3
636 man/SD_JOURNAL_SYSTEM_ONLY.3: man/sd_journal_open.3
637 man/SD_JOURNAL_LOCAL_ONLY.3: man/sd_journal_open.3
638 man/sd_journal_previous.3: man/sd_journal_next.3
639 man/sd_journal_next_skip.3: man/sd_journal_next.3
640 man/sd_journal_previous_skip.3: man/sd_journal_next.3
641 man/SD_JOURNAL_FOREACH.3: man/sd_journal_next.3
642 man/SD_JOURNAL_FOREACH_BACKWARDS.3: man/sd_journal_next.3
643 man/sd_journal_enumerate_data.3: man/sd_journal_get_data.3
644 man/sd_journal_restart_data.3: man/sd_journal_get_data.3
645 man/SD_JOURNAL_FOREACH_DATA.3: man/sd_journal_get_data.3
646 man/sd_journal_get_monotonic_usec.3: man/sd_journal_get_realtime_usec.3
647 man/sd_journal_get_cutoff_monotonic_usec.3: man/sd_journal_get_cutoff_realtime_usec.3
648 man/sd_journal_process.3: man/sd_journal_get_fd.3
649 man/sd_journal_wait.3: man/sd_journal_get_fd.3
650 man/SD_JOURNAL_NOP.3: man/sd_journal_get_fd.3
651 man/SD_JOURNAL_APPEND.3: man/sd_journal_get_fd.3
652 man/SD_JOURNAL_INVALIDATE.3: man/sd_journal_get_fd.3
653 man/sd_journal_add_disjunction.3: man/sd_journal_add_match.3
654 man/sd_journal_flush_matches.3: man/sd_journal_add_match.3
655 man/sd_journal_seek_tail.3: man/sd_journal_seek_head.3
656 man/sd_journal_seek_monotonic_usec.3: man/sd_journal_seek_head.3
657 man/sd_journal_seek_realtime_usec.3: man/sd_journal_seek_head.3
658 man/sd_journal_seek_cursor.3: man/sd_journal_seek_head.3
659
660 XML_FILES = \
661         ${patsubst %.1,%.xml,${patsubst %.3,%.xml,${patsubst %.5,%.xml,${patsubst %.7,%.xml,${patsubst %.8,%.xml,$(MANPAGES)}}}}}
662
663 if ENABLE_MANPAGES
664 man_MANS = \
665         $(MANPAGES) \
666         $(MANPAGES_ALIAS)
667
668 noinst_DATA = \
669         ${XML_FILES:.xml=.html}
670
671 CLEANFILES += \
672         $(MANPAGES) \
673         $(MANPAGES_ALIAS) \
674         ${XML_FILES:.xml=.html}
675
676 if HAVE_PYTHON
677 noinst_DATA += \
678         man/index.html
679
680 CLEANFILES += \
681         man/index.html
682
683 man/index.html: make-man-index.py $(XML_FILES)
684         $(AM_V_at)$(MKDIR_P) $(dir $@)
685         $(AM_V_GEN)$(PYTHON) $^ > $@
686
687 MANPAGES += \
688         man/systemd.directives.5
689
690 EXTRA_DIST += \
691         man/index.html
692
693 XML_DIRECTIVE_FILES = \
694         man/systemd.unit.xml \
695         man/systemd.service.xml \
696         man/systemd.socket.xml \
697         man/systemd.mount.xml \
698         man/systemd.automount.xml \
699         man/systemd.swap.xml \
700         man/systemd.target.xml \
701         man/systemd.path.xml \
702         man/systemd.timer.xml \
703         man/systemd.snapshot.xml \
704         man/systemd.exec.xml \
705         man/systemd.kill.xml \
706         man/systemd.device.xml \
707         man/systemd.conf.xml \
708         man/systemd.journal-fields.xml
709
710 man/systemd.directives.xml: make-directive-index.py $(XML_DIRECTIVE_FILES)
711         $(AM_V_at)$(MKDIR_P) $(dir $@)
712         $(AM_V_GEN)$(PYTHON) $^ > $@
713
714 EXTRA_DIST += \
715         man/systemd.directives.xml
716
717 endif
718
719 endif
720
721 EXTRA_DIST += \
722         $(XML_FILES) \
723         ${XML_FILES:.xml=.html} \
724         $(MANPAGES) \
725         $(MANPAGES_ALIAS) \
726         make-man-index.py \
727         make-directive-index.py
728
729 # ------------------------------------------------------------------------------
730 noinst_LTLIBRARIES += \
731         libsystemd-shared.la
732
733 libsystemd_shared_la_SOURCES = \
734         src/shared/linux/auto_dev-ioctl.h \
735         src/shared/linux/fanotify.h \
736         src/shared/linux/seccomp.h \
737         src/shared/linux/seccomp-bpf.h \
738         src/shared/missing.h \
739         src/shared/list.h \
740         src/shared/macro.h \
741         src/shared/def.h \
742         src/shared/util.c \
743         src/shared/util.h \
744         src/shared/virt.c \
745         src/shared/virt.h \
746         src/shared/path-util.c \
747         src/shared/path-util.h \
748         src/shared/hashmap.c \
749         src/shared/hashmap.h \
750         src/shared/set.c \
751         src/shared/set.h \
752         src/shared/strv.c \
753         src/shared/strv.h \
754         src/shared/conf-parser.c \
755         src/shared/conf-parser.h \
756         src/shared/log.c \
757         src/shared/log.h \
758         src/shared/ratelimit.h \
759         src/shared/ratelimit.c \
760         src/shared/exit-status.c \
761         src/shared/exit-status.h \
762         src/shared/utf8.c \
763         src/shared/utf8.h \
764         src/shared/pager.c \
765         src/shared/pager.h \
766         src/shared/ioprio.h \
767         src/shared/socket-util.c \
768         src/shared/socket-util.h \
769         src/shared/conf-files.c \
770         src/shared/conf-files.h \
771         src/shared/cgroup-util.c \
772         src/shared/cgroup-util.h \
773         src/shared/cgroup-show.c \
774         src/shared/cgroup-show.h \
775         src/shared/unit-name.c \
776         src/shared/unit-name.h \
777         src/shared/utmp-wtmp.c \
778         src/shared/utmp-wtmp.h \
779         src/shared/watchdog.c \
780         src/shared/watchdog.h \
781         src/shared/spawn-ask-password-agent.c \
782         src/shared/spawn-ask-password-agent.h \
783         src/shared/specifier.c \
784         src/shared/specifier.h \
785         src/shared/spawn-polkit-agent.c \
786         src/shared/spawn-polkit-agent.h \
787         src/shared/hwclock.c \
788         src/shared/hwclock.h
789
790 #-------------------------------------------------------------------------------
791 noinst_LTLIBRARIES += \
792         libsystemd-dbus.la
793
794 libsystemd_dbus_la_SOURCES = \
795         src/shared/dbus-common.c \
796         src/shared/dbus-common.h \
797         src/shared/dbus-loop.c \
798         src/shared/dbus-loop.h \
799         src/shared/polkit.c \
800         src/shared/polkit.h
801
802 libsystemd_dbus_la_CFLAGS = \
803         $(AM_CFLAGS) \
804         $(DBUS_CFLAGS)
805
806 libsystemd_dbus_la_LIBADD = \
807         $(DBUS_LIBS)
808
809 # ------------------------------------------------------------------------------
810 noinst_LTLIBRARIES += \
811         libsystemd-units.la
812
813 libsystemd_units_la_SOURCES = \
814         src/shared/install.c \
815         src/shared/install.h \
816         src/shared/path-lookup.c \
817         src/shared/path-lookup.h
818
819 libsystemd_units_la_CFLAGS = \
820         $(AM_CFLAGS) \
821         $(DBUS_CFLAGS)
822
823 # ------------------------------------------------------------------------------
824 noinst_LTLIBRARIES += \
825         libsystemd-label.la
826
827 libsystemd_label_la_SOURCES = \
828         src/shared/cgroup-label.c \
829         src/shared/socket-label.c \
830         src/shared/label.c \
831         src/shared/label.h \
832         src/shared/mkdir.c \
833         src/shared/mkdir.h \
834         src/shared/ask-password-api.c \
835         src/shared/ask-password-api.h \
836         src/shared/dev-setup.c \
837         src/shared/dev-setup.h
838
839 libsystemd_label_la_CFLAGS = \
840         $(AM_CFLAGS) \
841         $(SELINUX_CFLAGS)
842
843 libsystemd_label_la_LIBADD = \
844         $(SELINUX_LIBS)
845
846 # ------------------------------------------------------------------------------
847 noinst_LTLIBRARIES += \
848         libsystemd-logs.la
849
850 libsystemd_logs_la_SOURCES = \
851         src/shared/logs-show.c \
852         src/shared/logs-show.h
853
854 libsystemd_logs_la_CFLAGS = \
855         $(AM_CFLAGS)
856
857 libsystemd_logs_la_LIBADD = \
858         libsystemd-journal-internal.la \
859         libsystemd-id128-internal.la \
860         libsystemd-shared.la
861
862 # ------------------------------------------------------------------------------
863 noinst_LTLIBRARIES += \
864         libsystemd-capability.la
865
866 libsystemd_capability_la_SOURCES = \
867         src/shared/capability.c \
868         src/shared/capability.h
869
870 libsystemd_capability_la_CFLAGS = \
871         $(AM_CFLAGS) \
872         $(CAP_CFLAGS)
873
874 libsystemd_capability_la_LIBADD = \
875         $(CAP_LIBS)
876
877 # ------------------------------------------------------------------------------
878 noinst_LTLIBRARIES += \
879         libsystemd-audit.la
880
881 libsystemd_audit_la_SOURCES = \
882         src/shared/audit.c \
883         src/shared/audit.h
884
885 libsystemd_audit_la_LIBADD = \
886         libsystemd-capability.la
887
888 # ------------------------------------------------------------------------------
889 if HAVE_ACL
890 noinst_LTLIBRARIES += \
891         libsystemd-acl.la
892
893 libsystemd_acl_la_SOURCES = \
894         src/shared/acl-util.c \
895         src/shared/acl-util.h
896
897 libsystemd_acl_la_CFLAGS = \
898         $(AM_CFLAGS) \
899         $(ACL_CFLAGS)
900
901 libsystemd_acl_la_LIBADD = \
902         $(ACL_LIBS)
903 endif
904
905 # ------------------------------------------------------------------------------
906 noinst_LTLIBRARIES += \
907         libsystemd-core.la
908
909 libsystemd_core_la_SOURCES = \
910         src/core/unit.c \
911         src/core/unit.h \
912         src/core/job.c \
913         src/core/job.h \
914         src/core/manager.c \
915         src/core/manager.h \
916         src/core/transaction.c \
917         src/core/transaction.h \
918         src/core/load-fragment.c \
919         src/core/load-fragment.h \
920         src/core/service.c \
921         src/core/service.h \
922         src/core/automount.c \
923         src/core/automount.h \
924         src/core/mount.c \
925         src/core/mount.h \
926         src/core/swap.c \
927         src/core/swap.h \
928         src/core/device.c \
929         src/core/device.h \
930         src/core/target.c \
931         src/core/target.h \
932         src/core/snapshot.c \
933         src/core/snapshot.h \
934         src/core/socket.c \
935         src/core/socket.h \
936         src/core/timer.c \
937         src/core/timer.h \
938         src/core/path.c \
939         src/core/path.h \
940         src/core/load-dropin.c \
941         src/core/load-dropin.h \
942         src/core/execute.c \
943         src/core/execute.h \
944         src/core/kill.c \
945         src/core/kill.h \
946         src/core/dbus.c \
947         src/core/dbus.h \
948         src/core/dbus-manager.c \
949         src/core/dbus-manager.h \
950         src/core/dbus-unit.c \
951         src/core/dbus-unit.h \
952         src/core/dbus-job.c \
953         src/core/dbus-job.h \
954         src/core/dbus-service.c \
955         src/core/dbus-service.h \
956         src/core/dbus-socket.c \
957         src/core/dbus-socket.h \
958         src/core/dbus-timer.c \
959         src/core/dbus-timer.h \
960         src/core/dbus-target.c \
961         src/core/dbus-target.h \
962         src/core/dbus-mount.c \
963         src/core/dbus-mount.h \
964         src/core/dbus-automount.c \
965         src/core/dbus-automount.h \
966         src/core/dbus-swap.c \
967         src/core/dbus-swap.h \
968         src/core/dbus-snapshot.c \
969         src/core/dbus-snapshot.h \
970         src/core/dbus-device.c \
971         src/core/dbus-device.h \
972         src/core/dbus-execute.c \
973         src/core/dbus-execute.h \
974         src/core/dbus-kill.c \
975         src/core/dbus-kill.h \
976         src/core/dbus-path.c \
977         src/core/dbus-path.h \
978         src/core/cgroup.c \
979         src/core/cgroup.h \
980         src/core/selinux-setup.c \
981         src/core/selinux-setup.h \
982         src/core/ima-setup.c \
983         src/core/ima-setup.h \
984         src/core/kmod-setup.c \
985         src/core/kmod-setup.h \
986         src/core/locale-setup.h \
987         src/core/locale-setup.c \
988         src/core/hostname-setup.c \
989         src/core/hostname-setup.h \
990         src/core/machine-id-setup.c \
991         src/core/machine-id-setup.h \
992         src/core/mount-setup.c \
993         src/core/mount-setup.h \
994         src/core/loopback-setup.h \
995         src/core/loopback-setup.c \
996         src/core/fdset.c \
997         src/core/fdset.h \
998         src/core/condition.c \
999         src/core/condition.h \
1000         src/core/namespace.c \
1001         src/core/namespace.h \
1002         src/core/tcpwrap.c \
1003         src/core/tcpwrap.h \
1004         src/core/cgroup-attr.c \
1005         src/core/cgroup-attr.h \
1006         src/core/securebits.h \
1007         src/core/initreq.h \
1008         src/core/special.h \
1009         src/core/bus-errors.h \
1010         src/core/build.h \
1011         src/core/sysfs-show.h \
1012         src/core/switch-root.h \
1013         src/core/switch-root.c \
1014         src/core/killall.h \
1015         src/core/killall.c \
1016         src/core/syscall-list.c \
1017         src/core/syscall-list.h
1018
1019 nodist_libsystemd_core_la_SOURCES = \
1020         src/core/load-fragment-gperf.c \
1021         src/core/load-fragment-gperf-nulstr.c \
1022         src/core/syscall-from-name.h \
1023         src/core/syscall-to-name.h
1024
1025 libsystemd_core_la_CFLAGS = \
1026         $(AM_CFLAGS) \
1027         $(DBUS_CFLAGS) \
1028         $(LIBWRAP_CFLAGS) \
1029         $(PAM_CFLAGS) \
1030         $(AUDIT_CFLAGS) \
1031         $(KMOD_CFLAGS)
1032
1033 libsystemd_core_la_LIBADD = \
1034         libsystemd-capability.la \
1035         libsystemd-units.la \
1036         libsystemd-label.la \
1037         libsystemd-shared.la \
1038         libsystemd-dbus.la \
1039         libsystemd-id128-internal.la \
1040         libudev.la \
1041         $(LIBWRAP_LIBS) \
1042         $(PAM_LIBS) \
1043         $(AUDIT_LIBS) \
1044         $(CAP_LIBS) \
1045         $(KMOD_LIBS)
1046
1047 src/core/load-fragment-gperf-nulstr.c: src/core/load-fragment-gperf.gperf
1048         $(AM_V_at)$(MKDIR_P) $(dir $@)
1049         $(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 ";" }' < $< > $@
1050
1051 EXTRA_DIST += \
1052         src/core/load-fragment-gperf.gperf.m4
1053
1054 CLEANFILES += \
1055         src/core/load-fragment-gperf.gperf \
1056         src/core/load-fragment-gperf.c \
1057         src/core/load-fragment-gperf-nulstr.c \
1058         src/core/syscall-list.txt \
1059         src/core/syscall-from-name.gperf
1060
1061 BUILT_SOURCES += \
1062         src/core/syscall-from-name.h \
1063         src/core/syscall-to-name.h
1064
1065 src/core/syscall-list.txt: Makefile
1066         $(AM_V_at)$(MKDIR_P) $(dir $@)
1067         $(AM_V_GEN)$(CPP) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) -dM -include sys/syscall.h - < /dev/null | $(AWK) '/^#define[ \t]+__NR_[^ ]+[ \t]+\(?.*[0-9]+.*\)?/ { sub(/__NR_/, "", $$2); print $$2; }' > $@
1068
1069 src/core/syscall-from-name.gperf: src/core/syscall-list.txt Makefile
1070         $(AM_V_at)$(MKDIR_P) $(dir $@)
1071         $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct syscall_name { const char* name; int id; };"; print "%null-strings"; print "%%";} { printf "%s, __NR_%s\n", $$1, $$1 }' < $< > $@
1072
1073 src/core/syscall-from-name.h: src/core/syscall-from-name.gperf Makefile
1074         $(AM_V_at)$(MKDIR_P) $(dir $@)
1075         $(AM_V_GEN)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_syscall -H hash_syscall_name -p -C < $< > $@
1076
1077 src/core/syscall-to-name.h: src/core/syscall-list.txt Makefile
1078         $(AM_V_at)$(MKDIR_P) $(dir $@)
1079         $(AM_V_GEN)$(AWK) 'BEGIN{ print "const char* const syscall_names[] = { "} { printf "[__NR_%s] = \"%s\",\n", $$1, $$1 } END{print "};"}' < $< > $@
1080
1081 # ------------------------------------------------------------------------------
1082 systemd_SOURCES = \
1083         src/core/main.c
1084
1085 systemd_CFLAGS = \
1086         $(AM_CFLAGS) \
1087         $(DBUS_CFLAGS)
1088
1089 systemd_LDADD = \
1090         libsystemd-core.la \
1091         libsystemd-daemon.la \
1092         libsystemd-id128-internal.la \
1093         libsystemd-dbus.la
1094
1095 dist_pkgsysconf_DATA += \
1096         src/core/system.conf \
1097         src/core/user.conf
1098
1099 dist_dbuspolicy_DATA += \
1100         src/core/org.freedesktop.systemd1.conf
1101
1102 dist_dbussystemservice_DATA += \
1103         src/core/org.freedesktop.systemd1.service
1104
1105 dbusinterface_DATA += \
1106         org.freedesktop.systemd1.Manager.xml \
1107         org.freedesktop.systemd1.Job.xml \
1108         org.freedesktop.systemd1.Unit.xml \
1109         org.freedesktop.systemd1.Service.xml \
1110         org.freedesktop.systemd1.Socket.xml \
1111         org.freedesktop.systemd1.Timer.xml \
1112         org.freedesktop.systemd1.Target.xml \
1113         org.freedesktop.systemd1.Device.xml \
1114         org.freedesktop.systemd1.Mount.xml \
1115         org.freedesktop.systemd1.Automount.xml \
1116         org.freedesktop.systemd1.Snapshot.xml \
1117         org.freedesktop.systemd1.Swap.xml \
1118         org.freedesktop.systemd1.Path.xml
1119
1120 polkitpolicy_in_in_files = \
1121         src/core/org.freedesktop.systemd1.policy.in.in
1122
1123 org.freedesktop.systemd1.%.xml: systemd
1124         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.$* $< $@.tmp && \
1125                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
1126                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
1127
1128 pkgconfigdata_DATA = \
1129         src/core/systemd.pc
1130
1131 nodist_rpmmacros_DATA = \
1132         src/core/macros.systemd
1133
1134 EXTRA_DIST += \
1135         src/core/systemd.pc.in \
1136         src/core/macros.systemd.in
1137
1138 CLEANFILES += \
1139         src/core/macros.systemd
1140
1141 # ------------------------------------------------------------------------------
1142 noinst_PROGRAMS += \
1143         test-engine \
1144         test-job-type \
1145         test-ns \
1146         test-loopback \
1147         test-hostname \
1148         test-daemon \
1149         test-cgroup \
1150         test-env-replace \
1151         test-strv \
1152         test-install \
1153         test-watchdog \
1154         test-unit-name \
1155         test-log \
1156         test-unit-file
1157
1158 TESTS += \
1159         test-job-type \
1160         test-env-replace \
1161         test-strv \
1162         test-unit-name \
1163         test-unit-file
1164
1165 test_engine_SOURCES = \
1166         src/test/test-engine.c
1167
1168 test_engine_CFLAGS = \
1169         $(AM_CFLAGS) \
1170         $(DBUS_CFLAGS)
1171
1172 test_engine_LDADD = \
1173         libsystemd-core.la \
1174         libsystemd-daemon.la \
1175         libsystemd-dbus.la
1176
1177 test_job_type_SOURCES = \
1178         src/test/test-job-type.c
1179
1180 test_job_type_CFLAGS = \
1181         $(AM_CFLAGS) \
1182         $(DBUS_CFLAGS)
1183
1184 test_job_type_LDADD = \
1185         libsystemd-core.la \
1186         libsystemd-daemon.la
1187
1188 test_ns_SOURCES = \
1189         src/test/test-ns.c
1190
1191 test_ns_LDADD = \
1192         libsystemd-core.la
1193
1194 test_loopback_SOURCES = \
1195         src/test/test-loopback.c
1196
1197 test_loopback_LDADD = \
1198         libsystemd-shared.la \
1199         libsystemd-core.la
1200
1201 test_hostname_SOURCES = \
1202         src/test/test-hostname.c
1203
1204 test_hostname_LDADD = \
1205         libsystemd-core.la
1206
1207 test_unit_name_SOURCES = \
1208         src/test/test-unit-name.c
1209
1210 test_unit_name_LDADD = \
1211         libsystemd-core.la
1212
1213 test_unit_file_SOURCES = \
1214         src/test/test-unit-file.c
1215
1216 test_unit_file_LDADD = \
1217         libsystemd-core.la
1218
1219 test_log_SOURCES = \
1220         src/test/test-log.c
1221
1222 test_log_LDADD = \
1223         libsystemd-core.la
1224
1225 test_daemon_SOURCES = \
1226         src/test/test-daemon.c
1227
1228 test_daemon_LDADD = \
1229         libsystemd-shared.la \
1230         libsystemd-daemon.la
1231
1232 test_cgroup_SOURCES = \
1233         src/test/test-cgroup.c
1234
1235 test_cgroup_LDADD = \
1236         libsystemd-label.la \
1237         libsystemd-shared.la
1238
1239 test_env_replace_SOURCES = \
1240         src/test/test-env-replace.c
1241
1242 test_env_replace_LDADD = \
1243         libsystemd-shared.la
1244
1245 test_strv_SOURCES = \
1246         src/test/test-strv.c
1247
1248 test_strv_LDADD = \
1249         libsystemd-shared.la
1250
1251 test_install_SOURCES = \
1252         src/test/test-install.c
1253
1254 test_install_CFLAGS = \
1255         $(AM_CFLAGS) \
1256         $(DBUS_CFLAGS)
1257
1258 test_install_LDADD = \
1259         libsystemd-units.la \
1260         libsystemd-label.la \
1261         libsystemd-shared.la
1262
1263 test_watchdog_SOURCES = \
1264         src/test/test-watchdog.c
1265
1266 test_watchdog_LDADD = \
1267         libsystemd-shared.la
1268
1269 # ------------------------------------------------------------------------------
1270 systemd_initctl_SOURCES = \
1271         src/initctl/initctl.c
1272
1273 systemd_initctl_CFLAGS = \
1274         $(AM_CFLAGS) \
1275         $(DBUS_CFLAGS)
1276
1277 systemd_initctl_LDADD = \
1278         libsystemd-shared.la \
1279         libsystemd-daemon.la \
1280         libsystemd-dbus.la
1281
1282 # ------------------------------------------------------------------------------
1283 systemd_update_utmp_SOURCES = \
1284         src/update-utmp/update-utmp.c
1285
1286 systemd_update_utmp_CFLAGS = \
1287         $(AM_CFLAGS) \
1288         $(DBUS_CFLAGS) \
1289         $(AUDIT_CFLAGS)
1290
1291 systemd_update_utmp_LDADD = \
1292         libsystemd-shared.la \
1293         libsystemd-dbus.la \
1294         $(AUDIT_LIBS)
1295
1296 # ------------------------------------------------------------------------------
1297 systemd_shutdownd_SOURCES = \
1298         src/shutdownd/shutdownd.c
1299
1300 systemd_shutdownd_LDADD = \
1301         libsystemd-label.la \
1302         libsystemd-shared.la \
1303         libsystemd-daemon.la
1304
1305 pkginclude_HEADERS += \
1306         src/systemd/sd-shutdown.h
1307
1308 # ------------------------------------------------------------------------------
1309 systemd_shutdown_SOURCES = \
1310         src/core/umount.c \
1311         src/core/umount.h \
1312         src/core/shutdown.c \
1313         src/core/mount-setup.c \
1314         src/core/mount-setup.h \
1315         src/core/killall.h \
1316         src/core/killall.c
1317
1318 systemd_shutdown_LDADD = \
1319         libsystemd-label.la \
1320         libsystemd-shared.la \
1321         libudev.la
1322
1323 # ------------------------------------------------------------------------------
1324 systemd_modules_load_SOURCES = \
1325         src/modules-load/modules-load.c
1326
1327 systemd_modules_load_CFLAGS = \
1328         $(AM_CFLAGS) \
1329         $(KMOD_CFLAGS)
1330
1331 systemd_modules_load_LDADD = \
1332         libsystemd-shared.la \
1333         $(KMOD_LIBS)
1334
1335 # ------------------------------------------------------------------------------
1336 systemd_tmpfiles_SOURCES = \
1337         src/tmpfiles/tmpfiles.c
1338
1339 systemd_tmpfiles_LDADD = \
1340         libsystemd-label.la \
1341         libsystemd-shared.la \
1342         libsystemd-capability.la
1343
1344 # ------------------------------------------------------------------------------
1345 systemd_machine_id_setup_SOURCES = \
1346         src/machine-id-setup/machine-id-setup-main.c \
1347         src/core/machine-id-setup.c \
1348         src/core/machine-id-setup.h
1349
1350 systemd_machine_id_setup_LDADD = \
1351         libsystemd-label.la \
1352         libsystemd-shared.la \
1353         libsystemd-id128-internal.la
1354
1355 # ------------------------------------------------------------------------------
1356 systemd_sysctl_SOURCES = \
1357         src/sysctl/sysctl.c
1358
1359 systemd_sysctl_LDADD = \
1360         libsystemd-shared.la
1361
1362 # ------------------------------------------------------------------------------
1363 systemd_sleep_SOURCES = \
1364         src/sleep/sleep.c
1365
1366 systemd_sleep_LDADD = \
1367         libsystemd-shared.la
1368
1369 # ------------------------------------------------------------------------------
1370 systemd_fsck_SOURCES = \
1371         src/fsck/fsck.c
1372
1373 systemd_fsck_CFLAGS = \
1374         $(AM_CFLAGS) \
1375         $(DBUS_CFLAGS)
1376
1377 systemd_fsck_LDADD = \
1378         libsystemd-shared.la \
1379         libsystemd-dbus.la \
1380         libudev.la
1381
1382 # ------------------------------------------------------------------------------
1383 systemd_timestamp_SOURCES = \
1384         src/timestamp/timestamp.c
1385
1386 systemd_timestamp_LDADD = \
1387         libsystemd-shared.la
1388
1389 # ------------------------------------------------------------------------------
1390 systemd_ac_power_SOURCES = \
1391         src/ac-power/ac-power.c
1392
1393 systemd_ac_power_LDADD = \
1394         libsystemd-shared.la \
1395         libudev.la
1396
1397 # ------------------------------------------------------------------------------
1398 systemd_detect_virt_SOURCES = \
1399         src/detect-virt/detect-virt.c
1400
1401 systemd_detect_virt_LDADD = \
1402         libsystemd-shared.la
1403
1404 # ------------------------------------------------------------------------------
1405 systemd_delta_SOURCES = \
1406         src/delta/delta.c
1407
1408 systemd_delta_LDADD = \
1409         libsystemd-shared.la
1410
1411 # ------------------------------------------------------------------------------
1412 systemd_getty_generator_SOURCES = \
1413         src/getty-generator/getty-generator.c
1414
1415 systemd_getty_generator_LDADD = \
1416         libsystemd-label.la \
1417         libsystemd-shared.la
1418
1419 # ------------------------------------------------------------------------------
1420 systemd_fstab_generator_SOURCES = \
1421         src/fstab-generator/fstab-generator.c \
1422         src/core/mount-setup.c
1423
1424 systemd_fstab_generator_LDADD = \
1425         libsystemd-label.la \
1426         libsystemd-shared.la
1427
1428 # ------------------------------------------------------------------------------
1429 systemd_system_update_generator_SOURCES = \
1430         src/system-update-generator/system-update-generator.c
1431
1432 systemd_system_update_generator_LDADD = \
1433         libsystemd-label.la \
1434         libsystemd-shared.la
1435
1436 # ------------------------------------------------------------------------------
1437 systemd_rc_local_generator_SOURCES = \
1438         src/rc-local-generator/rc-local-generator.c
1439
1440 systemd_rc_local_generator_LDADD = \
1441         libsystemd-label.la \
1442         libsystemd-shared.la
1443
1444 # ------------------------------------------------------------------------------
1445 systemd_remount_fs_SOURCES = \
1446         src/remount-fs/remount-fs.c \
1447         src/core/mount-setup.c \
1448         src/core/mount-setup.h
1449
1450 systemd_remount_fs_LDADD = \
1451         libsystemd-label.la \
1452         libsystemd-shared.la
1453
1454 # ------------------------------------------------------------------------------
1455 systemd_cgroups_agent_SOURCES = \
1456         src/cgroups-agent/cgroups-agent.c
1457
1458 systemd_cgroups_agent_CFLAGS = \
1459         $(AM_CFLAGS) \
1460         $(DBUS_CFLAGS)
1461
1462 systemd_cgroups_agent_LDADD = \
1463         libsystemd-shared.la \
1464         libsystemd-dbus.la
1465
1466 # ------------------------------------------------------------------------------
1467 systemctl_SOURCES = \
1468         src/systemctl/systemctl.c
1469
1470 systemctl_CFLAGS = \
1471         $(AM_CFLAGS) \
1472         $(DBUS_CFLAGS)
1473
1474 systemctl_LDADD = \
1475         libsystemd-units.la \
1476         libsystemd-label.la \
1477         libsystemd-shared.la \
1478         libsystemd-daemon.la \
1479         libsystemd-dbus.la \
1480         libsystemd-logs.la
1481
1482 # ------------------------------------------------------------------------------
1483 systemd_notify_SOURCES = \
1484         src/notify/notify.c \
1485         src/readahead/sd-readahead.c
1486
1487 systemd_notify_LDADD = \
1488         libsystemd-shared.la \
1489         libsystemd-daemon.la
1490
1491 # ------------------------------------------------------------------------------
1492 systemd_ask_password_SOURCES = \
1493         src/ask-password/ask-password.c
1494
1495 systemd_ask_password_LDADD = \
1496         libsystemd-label.la \
1497         libsystemd-shared.la
1498
1499 # ------------------------------------------------------------------------------
1500 systemd_reply_password_SOURCES = \
1501         src/reply-password/reply-password.c
1502
1503 systemd_reply_password_LDADD = \
1504         libsystemd-shared.la
1505
1506 # ------------------------------------------------------------------------------
1507 systemd_cgls_SOURCES = \
1508         src/cgls/cgls.c
1509
1510 systemd_cgls_LDADD = \
1511         libsystemd-shared.la
1512
1513 # ------------------------------------------------------------------------------
1514 systemd_cgtop_SOURCES = \
1515         src/cgtop/cgtop.c
1516
1517 systemd_cgtop_LDADD = \
1518         libsystemd-shared.la
1519
1520 # ------------------------------------------------------------------------------
1521 systemd_nspawn_SOURCES = \
1522         src/nspawn/nspawn.c \
1523         src/core/mount-setup.c \
1524         src/core/mount-setup.h \
1525         src/core/loopback-setup.c \
1526         src/core/loopback-setup.h
1527
1528 systemd_nspawn_LDADD = \
1529         libsystemd-label.la \
1530         libsystemd-capability.la \
1531         libsystemd-shared.la \
1532         libsystemd-daemon.la \
1533         libsystemd-id128-internal.la
1534
1535 # ------------------------------------------------------------------------------
1536 systemd_stdio_bridge_SOURCES = \
1537         src/stdio-bridge/stdio-bridge.c
1538
1539 systemd_stdio_bridge_LDADD = \
1540         libsystemd-shared.la
1541
1542 # ------------------------------------------------------------------------------
1543 systemd_tty_ask_password_agent_SOURCES = \
1544         src/tty-ask-password-agent/tty-ask-password-agent.c
1545
1546 systemd_tty_ask_password_agent_LDADD = \
1547         libsystemd-label.la \
1548         libsystemd-shared.la
1549
1550 # ------------------------------------------------------------------------------
1551 libsystemd_daemon_la_SOURCES = \
1552         src/libsystemd-daemon/sd-daemon.c
1553
1554 libsystemd_daemon_la_CFLAGS = \
1555         $(AM_CFLAGS) \
1556         -fvisibility=hidden \
1557         -DSD_EXPORT_SYMBOLS
1558
1559 libsystemd_daemon_la_LDFLAGS = \
1560         $(AM_LDFLAGS) \
1561         -shared \
1562         -version-info $(LIBSYSTEMD_DAEMON_CURRENT):$(LIBSYSTEMD_DAEMON_REVISION):$(LIBSYSTEMD_DAEMON_AGE) \
1563         -Wl,--version-script=$(top_srcdir)/src/libsystemd-daemon/libsystemd-daemon.sym
1564
1565 pkginclude_HEADERS += \
1566         src/systemd/sd-daemon.h
1567
1568 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
1569 libsystemd-daemon-install-hook:
1570         if test "$(libdir)" != "$(rootlibdir)"; then \
1571                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
1572                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-daemon.so) && \
1573                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
1574                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-daemon.so && \
1575                 mv $(DESTDIR)$(libdir)/libsystemd-daemon.so.* $(DESTDIR)$(rootlibdir); \
1576         fi
1577
1578 INSTALL_EXEC_HOOKS += \
1579         libsystemd-daemon-install-hook
1580
1581 libsystemd-daemon-uninstall-hook:
1582         rm -f $(DESTDIR)$(rootlibdir)/libsystemd-daemon.so*
1583
1584 UNINSTALL_EXEC_HOOKS += \
1585         libsystemd-daemon-uninstall-hook
1586
1587 lib_LTLIBRARIES += \
1588         libsystemd-daemon.la
1589
1590 pkgconfiglib_DATA += \
1591         src/libsystemd-daemon/libsystemd-daemon.pc
1592
1593 MANPAGES += \
1594         man/sd-daemon.3 \
1595         man/sd_notify.3 \
1596         man/sd_listen_fds.3 \
1597         man/sd_is_fifo.3 \
1598         man/sd_booted.3
1599
1600 MANPAGES_ALIAS += \
1601         man/sd_is_socket.3 \
1602         man/sd_is_socket_unix.3 \
1603         man/sd_is_socket_inet.3 \
1604         man/sd_is_mq.3 \
1605         man/sd_notifyf.3 \
1606         man/SD_LISTEN_FDS_START.3 \
1607         man/SD_EMERG.3 \
1608         man/SD_ALERT.3 \
1609         man/SD_CRIT.3 \
1610         man/SD_ERR.3 \
1611         man/SD_WARNING.3 \
1612         man/SD_NOTICE.3 \
1613         man/SD_INFO.3 \
1614         man/SD_DEBUG.3
1615
1616 man/sd_is_socket.3: man/sd_is_fifo.3
1617 man/sd_is_socket_unix.3: man/sd_is_fifo.3
1618 man/sd_is_socket_inet.3: man/sd_is_fifo.3
1619 man/sd_is_mq.3: man/sd_is_fifo.3
1620 man/sd_notifyf.3: man/sd_notify.3
1621 man/SD_LISTEN_FDS_START.3: man/sd_listen_fds.3
1622 man/SD_EMERG.3: man/sd-daemon.3
1623 man/SD_ALERT.3: man/sd-daemon.3
1624 man/SD_CRIT.3: man/sd-daemon.3
1625 man/SD_ERR.3: man/sd-daemon.3
1626 man/SD_WARNING.3: man/sd-daemon.3
1627 man/SD_NOTICE.3: man/sd-daemon.3
1628 man/SD_INFO.3: man/sd-daemon.3
1629 man/SD_DEBUG.3: man/sd-daemon.3
1630
1631 EXTRA_DIST += \
1632         src/libsystemd-daemon/libsystemd-daemon.pc.in \
1633         src/libsystemd-daemon/libsystemd-daemon.sym
1634
1635 # ------------------------------------------------------------------------------
1636 if ENABLE_GTK_DOC
1637 SUBDIRS += \
1638         docs/libudev
1639 endif
1640
1641 include_HEADERS += \
1642         src/libudev/libudev.h
1643
1644 lib_LTLIBRARIES += \
1645         libudev.la
1646
1647 libudev_la_SOURCES =\
1648         src/libudev/libudev-private.h \
1649         src/libudev/libudev.c \
1650         src/libudev/libudev-list.c \
1651         src/libudev/libudev-util.c \
1652         src/libudev/libudev-device.c \
1653         src/libudev/libudev-enumerate.c \
1654         src/libudev/libudev-monitor.c \
1655         src/libudev/libudev-queue.c
1656
1657 libudev_la_CFLAGS = \
1658         $(AM_CFLAGS) \
1659         -fvisibility=hidden
1660
1661 libudev_la_LDFLAGS = \
1662         $(AM_LDFLAGS) \
1663         -version-info $(LIBUDEV_CURRENT):$(LIBUDEV_REVISION):$(LIBUDEV_AGE) \
1664         -Wl,--version-script=$(top_srcdir)/src/libudev/libudev.sym
1665
1666 libudev_la_LIBADD = \
1667         libsystemd-shared.la
1668
1669 pkgconfiglib_DATA += \
1670         src/libudev/libudev.pc
1671
1672 EXTRA_DIST += \
1673         src/libudev/libudev.pc.in \
1674         src/libudev/libudev.sym
1675
1676 CLEANFILES += \
1677         src/libudev/libudev.pc
1678
1679 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
1680 libudev-install-move-hook:
1681         if test "$(libdir)" != "$(rootlibdir)"; then \
1682                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
1683                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libudev.so) && \
1684                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
1685                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libudev.so && \
1686                 mv $(DESTDIR)$(libdir)/libudev.so.* $(DESTDIR)$(rootlibdir); \
1687         fi
1688
1689 libudev-uninstall-move-hook:
1690         rm -f $(DESTDIR)$(rootlibdir)/libudev.so*
1691
1692 INSTALL_EXEC_HOOKS += libudev-install-move-hook
1693 UNINSTALL_EXEC_HOOKS += libudev-uninstall-move-hook
1694
1695 # ------------------------------------------------------------------------------
1696 noinst_LTLIBRARIES += \
1697         libudev-private.la
1698
1699 libudev_private_la_SOURCES =\
1700         $(libudev_la_SOURCES) \
1701         src/libudev/libudev-device-private.c \
1702         src/libudev/libudev-queue-private.c
1703
1704 libudev_private_la_CFLAGS = \
1705         $(AM_CFLAGS) \
1706         -fvisibility=default
1707
1708 libudev_private_la_LIBADD = \
1709         libsystemd-shared.la
1710
1711 # ------------------------------------------------------------------------------
1712 MANPAGES += \
1713         man/udev.7 \
1714         man/udevadm.8 \
1715         man/systemd-udevd.service.8
1716
1717 MANPAGES_ALIAS += \
1718         man/systemd-udevd.8 \
1719         man/systemd-udevd-control.socket.8 \
1720         man/systemd-udevd-kernel.socket.8
1721
1722 man/systemd-udevd.8: man/systemd-udevd.service.8
1723 man/systemd-udevd-control.socket.8: man/systemd-udevd.service.8
1724 man/systemd-udevd-kernel.socket.8: man/systemd-udevd.service.8
1725
1726 udev-confdirs:
1727         -$(MKDIR_P) $(DESTDIR)$(sysconfdir)/udev/rules.d
1728
1729 INSTALL_DATA_HOOKS += udev-confdirs
1730
1731 dist_udevrules_DATA += \
1732         rules/99-systemd.rules \
1733         rules/42-usb-hid-pm.rules \
1734         rules/50-udev-default.rules \
1735         rules/60-persistent-storage-tape.rules \
1736         rules/60-persistent-serial.rules \
1737         rules/60-persistent-input.rules \
1738         rules/60-persistent-alsa.rules \
1739         rules/60-persistent-storage.rules \
1740         rules/75-net-description.rules \
1741         rules/75-tty-description.rules \
1742         rules/78-sound-card.rules \
1743         rules/80-drivers.rules \
1744         rules/95-udev-late.rules
1745
1746 udevconfdir = $(sysconfdir)/udev
1747 dist_udevconf_DATA = \
1748         src/udev/udev.conf
1749
1750 sharepkgconfigdir = $(datadir)/pkgconfig
1751 sharepkgconfig_DATA = \
1752         src/udev/udev.pc
1753
1754 EXTRA_DIST += \
1755         rules/99-systemd.rules.in \
1756         src/udev/udev.pc.in
1757
1758 CLEANFILES += \
1759         rules/99-systemd.rules \
1760         src/udev/udev.pc
1761
1762 EXTRA_DIST += \
1763         units/systemd-udevd.service.in \
1764         units/systemd-udev-trigger.service.in \
1765         units/systemd-udev-settle.service.in
1766
1767 CLEANFILES += \
1768         units/systemd-udevd.service \
1769         units/systemd-udev-trigger.service \
1770         units/systemd-udev-settle.service
1771
1772 systemd-install-hook:
1773         $(MKDIR_P) $(DESTDIR)$(systemunitdir)/sockets.target.wants
1774         ln -sf ../systemd-udevd-control.socket $(DESTDIR)$(systemunitdir)/sockets.target.wants/systemd-udevd-control.socket
1775         ln -sf ../systemd-udevd-kernel.socket $(DESTDIR)$(systemunitdir)/sockets.target.wants/systemd-udevd-kernel.socket
1776         $(MKDIR_P) $(DESTDIR)$(systemunitdir)/sysinit.target.wants
1777         ln -sf ../systemd-udevd.service $(DESTDIR)$(systemunitdir)/sysinit.target.wants/systemd-udevd.service
1778         ln -sf ../systemd-udev-trigger.service $(DESTDIR)$(systemunitdir)/sysinit.target.wants/systemd-udev-trigger.service
1779
1780 INSTALL_DATA_HOOKS += systemd-install-hook
1781
1782 bin_PROGRAMS += \
1783         udevadm
1784
1785 rootlibexec_PROGRAMS += \
1786         systemd-udevd
1787
1788 noinst_LTLIBRARIES += \
1789         libudev-core.la
1790
1791 libudev_core_la_SOURCES = \
1792         src/udev/udev.h \
1793         src/udev/udev-event.c \
1794         src/udev/udev-watch.c \
1795         src/udev/udev-node.c \
1796         src/udev/udev-rules.c \
1797         src/udev/udev-ctrl.c \
1798         src/udev/udev-builtin.c \
1799         src/udev/udev-builtin-blkid.c \
1800         src/udev/udev-builtin-firmware.c \
1801         src/udev/udev-builtin-hwdb.c \
1802         src/udev/udev-builtin-input_id.c \
1803         src/udev/udev-builtin-kmod.c \
1804         src/udev/udev-builtin-path_id.c \
1805         src/udev/udev-builtin-usb_id.c \
1806         src/libsystemd-daemon/sd-daemon.c
1807
1808 libudev_core_la_CFLAGS = \
1809         $(AM_CFLAGS) \
1810         $(BLKID_CFLAGS) \
1811         $(KMOD_CFLAGS)
1812
1813 libudev_core_la_LIBADD = \
1814         libudev-private.la \
1815         libsystemd-label.la \
1816         libsystemd-shared.la \
1817         $(BLKID_LIBS) \
1818         $(KMOD_LIBS)
1819
1820 libudev_core_la_CPPFLAGS = \
1821         $(AM_CPPFLAGS) \
1822         -DFIRMWARE_PATH="$(FIRMWARE_PATH)" \
1823         -DUSB_DATABASE=\"$(USB_DATABASE)\" -DPCI_DATABASE=\"$(PCI_DATABASE)\"
1824
1825 if HAVE_ACL
1826 libudev_core_la_SOURCES += \
1827         src/udev/udev-builtin-uaccess.c \
1828         src/login/logind-acl.c \
1829         src/login/sd-login.c
1830
1831 libudev_core_la_LIBADD += \
1832         libsystemd-acl.la
1833 endif
1834
1835 systemd_udevd_SOURCES = \
1836         src/udev/udevd.c
1837
1838 systemd_udevd_LDADD = \
1839         libudev-core.la
1840
1841 udevadm_SOURCES = \
1842         src/udev/udevadm.c \
1843         src/udev/udevadm-info.c \
1844         src/udev/udevadm-control.c \
1845         src/udev/udevadm-monitor.c \
1846         src/udev/udevadm-settle.c \
1847         src/udev/udevadm-trigger.c \
1848         src/udev/udevadm-test.c \
1849         src/udev/udevadm-test-builtin.c
1850
1851 udevadm_LDADD = \
1852         libudev-core.la \
1853         libsystemd-shared.la
1854
1855 # ------------------------------------------------------------------------------
1856 TESTS += \
1857         test/udev-test.pl \
1858         test/rules-test.sh
1859
1860 noinst_PROGRAMS += \
1861         test-libudev \
1862         test-udev
1863
1864 test_libudev_SOURCES = \
1865         src/test/test-libudev.c
1866
1867 test_libudev_LDADD = \
1868         libsystemd-label.la \
1869         libsystemd-shared.la \
1870         libudev.la
1871
1872 test_udev_SOURCES = \
1873         src/test/test-udev.c
1874
1875 test_udev_LDADD = \
1876         libudev-core.la \
1877         libsystemd-shared.la \
1878         $(BLKID_LIBS) \
1879         $(KMOD_LIBS) \
1880         $(SELINUX_LIBS)
1881
1882 if HAVE_ACL
1883 test_udev_LDADD += \
1884         libsystemd-acl.la
1885 endif
1886
1887 check_DATA += \
1888         test/sys
1889
1890 # packed sysfs test tree
1891 test/sys:
1892         $(AM_V_at)$(MKDIR_P) $(dir $@)
1893         $(AM_V_GEN)tar -C test/ -xJf $(top_srcdir)/test/sys.tar.xz
1894
1895 test-sys-distclean:
1896         -rm -rf test/sys
1897 DISTCLEAN_LOCAL_HOOKS += test-sys-distclean
1898
1899 EXTRA_DIST += \
1900         test/sys.tar.xz \
1901         test/udev-test.pl \
1902         test/rules-test.sh \
1903         test/rule-syntax-check.py
1904
1905 # ------------------------------------------------------------------------------
1906 ata_id_SOURCES = \
1907         src/udev/ata_id/ata_id.c
1908
1909 ata_id_LDADD = \
1910         libudev-private.la \
1911         libsystemd-shared.la
1912
1913 udevlibexec_PROGRAMS += \
1914         ata_id
1915
1916 # ------------------------------------------------------------------------------
1917 cdrom_id_SOURCES = \
1918         src/udev/cdrom_id/cdrom_id.c
1919
1920 cdrom_id_LDADD = \
1921         libudev.la \
1922         libsystemd-shared.la
1923
1924 udevlibexec_PROGRAMS += \
1925         cdrom_id
1926
1927 dist_udevrules_DATA += \
1928         rules/60-cdrom_id.rules
1929
1930 # ------------------------------------------------------------------------------
1931 collect_SOURCES = \
1932         src/udev/collect/collect.c
1933
1934 collect_LDADD = \
1935         libudev-private.la
1936
1937 udevlibexec_PROGRAMS += \
1938         collect
1939
1940 # ------------------------------------------------------------------------------
1941 scsi_id_SOURCES =\
1942         src/udev/scsi_id/scsi_id.c \
1943         src/udev/scsi_id/scsi_serial.c \
1944         src/udev/scsi_id/scsi.h \
1945         src/udev/scsi_id/scsi_id.h
1946
1947 scsi_id_LDADD = \
1948         libudev-private.la \
1949         libsystemd-shared.la
1950
1951 udevlibexec_PROGRAMS += \
1952         scsi_id
1953
1954 EXTRA_DIST += \
1955         src/udev/scsi_id/README
1956
1957 # ------------------------------------------------------------------------------
1958 v4l_id_SOURCES = \
1959         src/udev/v4l_id/v4l_id.c
1960
1961 v4l_id_LDADD = \
1962         libudev.la
1963
1964 udevlibexec_PROGRAMS += \
1965         v4l_id
1966
1967 dist_udevrules_DATA += \
1968         rules/60-persistent-v4l.rules
1969
1970 # ------------------------------------------------------------------------------
1971 accelerometer_SOURCES = \
1972         src/udev/accelerometer/accelerometer.c
1973
1974 accelerometer_LDADD = \
1975         libudev.la -lm \
1976         libsystemd-shared.la
1977
1978 udevlibexec_PROGRAMS += \
1979         accelerometer
1980
1981 dist_udevrules_DATA += \
1982         rules/61-accelerometer.rules
1983
1984 # ------------------------------------------------------------------------------
1985 if ENABLE_GUDEV
1986 if ENABLE_GTK_DOC
1987 SUBDIRS += \
1988         docs/gudev
1989 endif
1990
1991 libgudev_includedir = \
1992         $(includedir)/gudev-1.0/gudev
1993
1994 libgudev_include_HEADERS = \
1995         src/gudev/gudev.h \
1996         src/gudev/gudevenums.h \
1997         src/gudev/gudevenumtypes.h \
1998         src/gudev/gudevtypes.h \
1999         src/gudev/gudevclient.h \
2000         src/gudev/gudevdevice.h \
2001         src/gudev/gudevenumerator.h
2002
2003 lib_LTLIBRARIES += libgudev-1.0.la
2004
2005 pkgconfiglib_DATA += \
2006         src/gudev/gudev-1.0.pc
2007
2008 CLEANFILES += \
2009         src/gudev/gudev-1.0.pc
2010
2011 libgudev_1_0_la_SOURCES = \
2012         src/gudev/gudevenums.h \
2013         src/gudev/gudevenumtypes.h \
2014         src/gudev/gudevenumtypes.h\
2015         src/gudev/gudevtypes.h \
2016         src/gudev/gudevclient.h \
2017         src/gudev/gudevclient.c \
2018         src/gudev/gudevdevice.h \
2019         src/gudev/gudevdevice.c \
2020         src/gudev/gudevenumerator.h \
2021         src/gudev/gudevenumerator.c \
2022         src/gudev/gudevprivate.h
2023
2024 nodist_libgudev_1_0_la_SOURCES = \
2025         src/gudev/gudevmarshal.h \
2026         src/gudev/gudevmarshal.c \
2027         src/gudev/gudevenumtypes.h \
2028         src/gudev/gudevenumtypes.c
2029
2030 BUILT_SOURCES += \
2031         $(nodist_libgudev_1_0_la_SOURCES)
2032
2033 libgudev_1_0_la_CPPFLAGS = \
2034         $(AM_CPPFLAGS) \
2035         -I$(top_builddir)/src\
2036         -I$(top_srcdir)/src\
2037         -I$(top_builddir)/src/gudev \
2038         -I$(top_srcdir)/src/gudev \
2039         -D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT \
2040         -D_GUDEV_COMPILATION \
2041         -DG_LOG_DOMAIN=\"GUdev\"
2042
2043 libgudev_1_0_la_CFLAGS = \
2044         $(AM_CFLAGS) \
2045         -fvisibility=default \
2046         $(GLIB_CFLAGS)
2047
2048 libgudev_1_0_la_LIBADD = \
2049         libudev.la \
2050         $(GLIB_LIBS)
2051
2052 libgudev_1_0_la_LDFLAGS = \
2053         $(AM_LDFLAGS) \
2054         -version-info $(LIBGUDEV_CURRENT):$(LIBGUDEV_REVISION):$(LIBGUDEV_AGE) \
2055         -export-dynamic -no-undefined \
2056         -export-symbols-regex '^g_udev_.*'
2057
2058 src/gudev/gudevmarshal.h: src/gudev/gudevmarshal.list
2059         $(AM_V_at)$(MKDIR_P) $(dir $@)
2060         $(AM_V_GEN)glib-genmarshal $< --prefix=g_udev_marshal --header > $@
2061
2062 src/gudev/gudevmarshal.c: src/gudev/gudevmarshal.list
2063         $(AM_V_at)$(MKDIR_P) $(dir $@)
2064         $(AM_V_GEN)echo '#include "gudevmarshal.h"' > $@ && \
2065         glib-genmarshal $< --prefix=g_udev_marshal --body >> $@
2066
2067 src/gudev/gudevenumtypes.%: src/gudev/gudevenumtypes.%.template src/gudev/gudevenums.h
2068         $(AM_V_at)$(MKDIR_P) $(dir $@)
2069         $(AM_V_GEN)glib-mkenums --template $^ > $@
2070
2071 if HAVE_INTROSPECTION
2072 -include $(INTROSPECTION_MAKEFILE)
2073
2074 src/gudev/GUdev-1.0.gir: libgudev-1.0.la
2075
2076 src_gudev_GUdev_1_0_gir_INCLUDES = GObject-2.0
2077
2078 src_gudev_GUdev_1_0_gir_CFLAGS = \
2079         $(INCLUDES) \
2080         -D_GUDEV_COMPILATION \
2081         -D_GUDEV_WORK_AROUND_DEV_T_BUG \
2082         -I$(top_srcdir)/src \
2083         -I$(top_builddir)/src \
2084         -I$(top_srcdir)/src/gdev \
2085         -I$(top_builddir)/src/gdev
2086
2087 src_gudev_GUdev_1_0_gir_LIBS = libgudev-1.0.la
2088
2089 src_gudev_GUdev_1_0_gir_SCANNERFLAGS = \
2090         --pkg-export=gudev-1.0 \
2091         --warn-all
2092
2093 src_gudev_GUdev_1_0_gir_FILES = \
2094         src/gudev/gudev.h \
2095         src/gudev/gudevtypes.h \
2096         src/gudev/gudevenums.h \
2097         src/gudev/gudevenumtypes.h \
2098         src/gudev/gudevclient.h \
2099         src/gudev/gudevdevice.h \
2100         src/gudev/gudevenumerator.h \
2101         src/gudev/gudevclient.c \
2102         src/gudev/gudevdevice.c \
2103         src/gudev/gudevenumerator.c
2104
2105 INTROSPECTION_GIRS = src/gudev/GUdev-1.0.gir
2106 INTROSPECTION_SCANNER_ARGS = --c-include=gudev/gudev.h
2107
2108 girdir = $(datadir)/gir-1.0
2109 gir_DATA = \
2110         src/gudev/GUdev-1.0.gir
2111
2112 typelibsdir = $(libdir)/girepository-1.0
2113 typelibs_DATA = \
2114         src/gudev/GUdev-1.0.typelib
2115
2116 CLEANFILES += $(gir_DATA) $(typelibs_DATA)
2117 endif # HAVE_INTROSPECTION
2118
2119 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
2120 libgudev-install-move-hook:
2121         if test "$(libdir)" != "$(rootlibdir)"; then \
2122                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
2123                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libgudev-1.0.so) && \
2124                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
2125                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libgudev-1.0.so && \
2126                 mv $(DESTDIR)$(libdir)/libgudev-1.0.so.* $(DESTDIR)$(rootlibdir); \
2127         fi
2128
2129 libgudev-uninstall-move-hook:
2130         rm -f $(DESTDIR)$(rootlibdir)/libgudev-1.0.so*
2131
2132 INSTALL_EXEC_HOOKS += libgudev-install-move-hook
2133 UNINSTALL_EXEC_HOOKS += libgudev-uninstall-move-hook
2134 endif
2135
2136 EXTRA_DIST += \
2137         src/gudev/gudev-1.0.pc.in \
2138         src/gudev/gudevmarshal.list \
2139         src/gudev/gudevenumtypes.h.template \
2140         src/gudev/gudevenumtypes.c.template \
2141         src/gudev/gjs-example.js \
2142         src/gudev/seed-example-enum.js \
2143         src/gudev/seed-example.js
2144
2145
2146 # ------------------------------------------------------------------------------
2147 if ENABLE_KEYMAP
2148 keymap_SOURCES = \
2149         src/udev/keymap/keymap.c
2150
2151 keymap_CPPFLAGS = \
2152         $(AM_CPPFLAGS) -I src/udev/keymap
2153
2154 keymap_LDADD = \
2155         libsystemd-shared.la
2156
2157 nodist_keymap_SOURCES = \
2158         src/udev/keymap/keys-from-name.h \
2159         src/udev/keymap/keys-to-name.h
2160
2161 BUILT_SOURCES += \
2162         $(nodist_keymap_SOURCES)
2163
2164 udevlibexec_PROGRAMS += \
2165         keymap
2166
2167 dist_doc_DATA += \
2168         src/udev/keymap/README.keymap.txt
2169
2170 dist_udevrules_DATA += \
2171         src/udev/keymap/95-keymap.rules \
2172         src/udev/keymap/95-keyboard-force-release.rules
2173
2174 dist_udevhome_SCRIPTS = \
2175         src/udev/keymap/findkeyboards \
2176         src/udev/keymap/keyboard-force-release.sh
2177
2178 TESTS += \
2179         src/udev/keymap/check-keymaps.sh
2180
2181 CLEANFILES += \
2182         src/udev/keymap/keys.txt \
2183         src/udev/keymap/keys-from-name.gperf \
2184         src/udev/keymap/keyboard-force-release.sh
2185
2186 udevkeymapdir = $(udevlibexecdir)/keymaps
2187 dist_udevkeymap_DATA = \
2188         keymaps/acer \
2189         keymaps/acer-aspire_5720 \
2190         keymaps/acer-aspire_8930 \
2191         keymaps/acer-aspire_5920g \
2192         keymaps/acer-aspire_6920 \
2193         keymaps/acer-travelmate_c300 \
2194         keymaps/asus \
2195         keymaps/compaq-e_evo \
2196         keymaps/dell \
2197         keymaps/dell-latitude-xt2 \
2198         keymaps/everex-xt5000 \
2199         keymaps/fujitsu-amilo_li_2732 \
2200         keymaps/fujitsu-amilo_pa_2548 \
2201         keymaps/fujitsu-amilo_pro_edition_v3505 \
2202         keymaps/fujitsu-amilo_pro_v3205 \
2203         keymaps/fujitsu-amilo_si_1520 \
2204         keymaps/fujitsu-esprimo_mobile_v5 \
2205         keymaps/fujitsu-esprimo_mobile_v6 \
2206         keymaps/genius-slimstar-320 \
2207         keymaps/hewlett-packard \
2208         keymaps/hewlett-packard-2510p_2530p \
2209         keymaps/hewlett-packard-compaq_elitebook \
2210         keymaps/hewlett-packard-pavilion \
2211         keymaps/hewlett-packard-presario-2100 \
2212         keymaps/hewlett-packard-tablet \
2213         keymaps/hewlett-packard-tx2 \
2214         keymaps/ibm-thinkpad-usb-keyboard-trackpoint \
2215         keymaps/inventec-symphony_6.0_7.0 \
2216         keymaps/lenovo-3000 \
2217         keymaps/lenovo-ideapad \
2218         keymaps/lenovo-thinkpad-usb-keyboard-trackpoint \
2219         keymaps/lenovo-thinkpad_x6_tablet \
2220         keymaps/lenovo-thinkpad_x200_tablet \
2221         keymaps/lg-x110 \
2222         keymaps/logitech-wave \
2223         keymaps/logitech-wave-cordless \
2224         keymaps/logitech-wave-pro-cordless \
2225         keymaps/maxdata-pro_7000 \
2226         keymaps/medion-fid2060 \
2227         keymaps/medionnb-a555 \
2228         keymaps/micro-star \
2229         keymaps/module-asus-w3j \
2230         keymaps/module-ibm \
2231         keymaps/module-lenovo \
2232         keymaps/module-sony \
2233         keymaps/module-sony-old \
2234         keymaps/module-sony-vgn \
2235         keymaps/module-sony-vpc \
2236         keymaps/olpc-xo \
2237         keymaps/onkyo \
2238         keymaps/oqo-model2 \
2239         keymaps/samsung-other \
2240         keymaps/samsung-90x3a \
2241         keymaps/samsung-sq1us \
2242         keymaps/samsung-sx20s \
2243         keymaps/toshiba-satellite_a100 \
2244         keymaps/toshiba-satellite_a110 \
2245         keymaps/toshiba-satellite_m30x \
2246         keymaps/zepto-znote
2247
2248 udevkeymapforcereldir = $(udevlibexecdir)/keymaps/force-release
2249 dist_udevkeymapforcerel_DATA = \
2250         keymaps-force-release/dell-touchpad \
2251         keymaps-force-release/dell-xps \
2252         keymaps-force-release/hp-other \
2253         keymaps-force-release/samsung-other \
2254         keymaps-force-release/samsung-90x3a \
2255         keymaps-force-release/common-volume-keys
2256
2257 src/udev/keymap/keys.txt: Makefile
2258         $(AM_V_at)$(MKDIR_P) $(dir $@)
2259         $(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/' > $@
2260
2261 src/udev/keymap/keys-from-name.gperf: src/udev/keymap/keys.txt Makefile
2262         $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct key { const char* name; unsigned short id; };"; print "%null-strings"; print "%%";} { print $$1 ", " $$1 }' < $< > $@
2263
2264 src/udev/keymap/keys-from-name.h: src/udev/keymap/keys-from-name.gperf Makefile
2265         $(AM_V_GEN)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_key -H hash_key_name -p -C < $< > $@
2266
2267 src/udev/keymap/keys-to-name.h: src/udev/keymap/keys.txt Makefile
2268         $(AM_V_GEN)$(AWK) 'BEGIN{ print "const char* const key_names[KEY_CNT] = { "} { print "[" $$1 "] = \"" $$1 "\"," } END{print "};"}' < $< > $@
2269 endif
2270
2271 EXTRA_DIST += \
2272         src/udev/keymap/check-keymaps.sh \
2273         src/udev/keymap/keyboard-force-release.sh.in
2274
2275 # ------------------------------------------------------------------------------
2276 mtd_probe_SOURCES =  \
2277         src/udev/mtd_probe/mtd_probe.c \
2278         src/udev/mtd_probe/mtd_probe.h \
2279         src/udev/mtd_probe/probe_smartmedia.c
2280
2281 mtd_probe_CPPFLAGS = \
2282         $(AM_CPPFLAGS)
2283
2284 dist_udevrules_DATA += \
2285         rules/75-probe_mtd.rules
2286
2287 udevlibexec_PROGRAMS += \
2288         mtd_probe
2289
2290 # ------------------------------------------------------------------------------
2291 libsystemd_id128_la_SOURCES = \
2292         src/libsystemd-id128/sd-id128.c
2293
2294 libsystemd_id128_la_CFLAGS = \
2295         $(AM_CFLAGS) \
2296         -fvisibility=hidden
2297
2298 libsystemd_id128_la_LDFLAGS = \
2299         $(AM_LDFLAGS) \
2300         -shared \
2301         -version-info $(LIBSYSTEMD_ID128_CURRENT):$(LIBSYSTEMD_ID128_REVISION):$(LIBSYSTEMD_ID128_AGE) \
2302         -Wl,--version-script=$(top_srcdir)/src/libsystemd-id128/libsystemd-id128.sym
2303
2304 libsystemd_id128_la_LIBADD = \
2305         libsystemd-shared.la
2306
2307 libsystemd_id128_internal_la_SOURCES = \
2308         $(libsystemd_id128_la_SOURCES)
2309
2310 test_id128_SOURCES = \
2311         src/test/test-id128.c
2312
2313 test_id128_LDADD = \
2314         libsystemd-shared.la \
2315         libsystemd-id128-internal.la
2316
2317 noinst_PROGRAMS += \
2318         test-id128
2319
2320 TESTS += \
2321         test-id128
2322
2323 pkginclude_HEADERS += \
2324         src/systemd/sd-id128.h
2325
2326 lib_LTLIBRARIES += \
2327         libsystemd-id128.la
2328
2329 noinst_LTLIBRARIES += \
2330         libsystemd-id128-internal.la
2331
2332 pkgconfiglib_DATA += \
2333         src/libsystemd-id128/libsystemd-id128.pc
2334
2335 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
2336 libsystemd-id128-install-hook:
2337         if test "$(libdir)" != "$(rootlibdir)"; then \
2338                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
2339                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-id128.so) && \
2340                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
2341                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-id128.so && \
2342                 mv $(DESTDIR)$(libdir)/libsystemd-id128.so.* $(DESTDIR)$(rootlibdir); \
2343         fi
2344
2345 INSTALL_EXEC_HOOKS += \
2346         libsystemd-id128-install-hook
2347
2348 libsystemd-id128-uninstall-hook:
2349         rm -f $(DESTDIR)$(rootlibdir)/libsystemd-id128.so*
2350
2351 UNINSTALL_EXEC_HOOKS += \
2352         libsystemd-id128-uninstall-hook
2353
2354 EXTRA_DIST += \
2355         src/libsystemd-id128/libsystemd-id128.pc.in \
2356         src/libsystemd-id128/libsystemd-id128.sym
2357
2358 # ------------------------------------------------------------------------------
2359 systemd_journald_SOURCES = \
2360         src/journal/journald.c \
2361         src/journal/journald.h \
2362         src/journal/journald-kmsg.c \
2363         src/journal/journald-kmsg.h \
2364         src/journal/journald-syslog.c \
2365         src/journal/journald-syslog.h \
2366         src/journal/journald-stream.c \
2367         src/journal/journald-stream.h \
2368         src/journal/journald-console.c \
2369         src/journal/journald-console.h \
2370         src/journal/journald-native.c \
2371         src/journal/journald-native.h \
2372         src/journal/journald-rate-limit.c \
2373         src/journal/journald-rate-limit.h \
2374         src/journal/journal-internal.h
2375
2376 nodist_systemd_journald_SOURCES = \
2377         src/journal/journald-gperf.c
2378
2379 systemd_journald_LDADD = \
2380         libsystemd-label.la \
2381         libsystemd-shared.la \
2382         libsystemd-audit.la \
2383         libsystemd-daemon.la \
2384         libsystemd-id128-internal.la \
2385         libsystemd-journal-internal.la \
2386         libudev.la
2387
2388 if ENABLE_LOGIND
2389 systemd_journald_LDADD += \
2390         libsystemd-login-internal.la
2391 endif
2392
2393 if HAVE_ACL
2394 systemd_journald_LDADD += \
2395         libsystemd-acl.la
2396 endif
2397
2398 systemd_cat_SOURCES = \
2399         src/journal/cat.c
2400
2401 systemd_cat_LDADD = \
2402         libsystemd-shared.la \
2403         libsystemd-journal-internal.la
2404
2405 journalctl_SOURCES = \
2406         src/journal/journalctl.c
2407
2408 journalctl_CFLAGS = \
2409         $(AM_CFLAGS)
2410
2411 journalctl_LDADD = \
2412         libsystemd-shared.la \
2413         libsystemd-journal-internal.la \
2414         libsystemd-id128-internal.la \
2415         libsystemd-logs.la
2416
2417 if HAVE_QRENCODE
2418 journalctl_SOURCES += \
2419         src/journal/journal-qrcode.c \
2420         src/journal/journal-qrcode.h
2421
2422 journalctl_CFLAGS += \
2423         $(QRENCODE_CFLAGS)
2424
2425 journalctl_LDADD += \
2426         $(QRENCODE_LIBS)
2427 endif
2428
2429 test_journal_SOURCES = \
2430         src/journal/test-journal.c
2431
2432 test_journal_LDADD = \
2433         libsystemd-shared.la \
2434         libsystemd-journal-internal.la \
2435         libsystemd-id128-internal.la
2436
2437 test_journal_send_SOURCES = \
2438         src/journal/test-journal-send.c
2439
2440 test_journal_send_LDADD = \
2441         libsystemd-shared.la \
2442         libsystemd-journal-internal.la \
2443         libsystemd-id128-internal.la
2444
2445 test_journal_match_SOURCES = \
2446         src/journal/test-journal-match.c
2447
2448 test_journal_match_LDADD = \
2449         libsystemd-shared.la \
2450         libsystemd-journal-internal.la \
2451         libsystemd-id128-internal.la
2452
2453 test_journal_stream_SOURCES = \
2454         src/journal/test-journal-stream.c
2455
2456 test_journal_stream_LDADD = \
2457         libsystemd-shared.la \
2458         libsystemd-journal-internal.la \
2459         libsystemd-id128-internal.la
2460
2461 test_journal_verify_SOURCES = \
2462         src/journal/test-journal-verify.c
2463
2464 test_journal_verify_LDADD = \
2465         libsystemd-shared.la \
2466         libsystemd-journal-internal.la \
2467         libsystemd-id128-internal.la
2468
2469 libsystemd_journal_la_SOURCES = \
2470         src/journal/sd-journal.c \
2471         src/systemd/sd-journal.h \
2472         src/journal/journal-file.c \
2473         src/journal/journal-file.h \
2474         src/journal/journal-vacuum.c \
2475         src/journal/journal-vacuum.h \
2476         src/journal/journal-verify.c \
2477         src/journal/journal-verify.h \
2478         src/journal/lookup3.c \
2479         src/journal/lookup3.h \
2480         src/journal/journal-send.c \
2481         src/journal/sparse-endian.h \
2482         src/journal/journal-def.h \
2483         src/journal/compress.h \
2484         src/journal/mmap-cache.c \
2485         src/journal/mmap-cache.h
2486
2487 libsystemd_journal_la_CFLAGS = \
2488         $(AM_CFLAGS) \
2489         -fvisibility=hidden
2490
2491 libsystemd_journal_la_LDFLAGS = \
2492         $(AM_LDFLAGS) \
2493         -shared \
2494         -version-info $(LIBSYSTEMD_JOURNAL_CURRENT):$(LIBSYSTEMD_JOURNAL_REVISION):$(LIBSYSTEMD_JOURNAL_AGE) \
2495         -Wl,--version-script=$(top_srcdir)/src/journal/libsystemd-journal.sym
2496
2497 libsystemd_journal_la_LIBADD = \
2498         libsystemd-shared.la \
2499         libsystemd-id128-internal.la
2500
2501 libsystemd_journal_internal_la_SOURCES = \
2502         $(libsystemd_journal_la_SOURCES)
2503
2504 libsystemd_journal_internal_la_CFLAGS = \
2505         $(AM_CFLAGS)
2506
2507 libsystemd_journal_internal_la_LIBADD =
2508
2509 if HAVE_XZ
2510 libsystemd_journal_la_SOURCES += \
2511         src/journal/compress.c
2512
2513 libsystemd_journal_la_CFLAGS += \
2514         $(XZ_CFLAGS)
2515
2516 libsystemd_journal_la_LIBADD += \
2517         $(XZ_LIBS)
2518
2519 libsystemd_journal_internal_la_CFLAGS += \
2520         $(XZ_CFLAGS)
2521
2522 libsystemd_journal_internal_la_LIBADD += \
2523         $(XZ_LIBS)
2524
2525 endif
2526
2527 if HAVE_GCRYPT
2528 libsystemd_journal_la_SOURCES += \
2529         src/journal/journal-authenticate.c \
2530         src/journal/journal-authenticate.h \
2531         src/journal/fsprg.c \
2532         src/journal/fsprg.h
2533
2534 libsystemd_journal_la_CFLAGS += \
2535         $(GCRYPT_CFLAGS) \
2536         -Wno-pointer-arith
2537
2538 libsystemd_journal_la_LIBADD += \
2539         $(GCRYPT_LIBS)
2540
2541 libsystemd_journal_internal_la_CFLAGS += \
2542         $(GCRYPT_CFLAGS) \
2543         -Wno-pointer-arith
2544
2545 libsystemd_journal_internal_la_LIBADD += \
2546         $(GCRYPT_LIBS)
2547 endif
2548
2549 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
2550 libsystemd-journal-install-hook:
2551         if test "$(libdir)" != "$(rootlibdir)"; then \
2552                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
2553                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-journal.so) && \
2554                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
2555                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-journal.so && \
2556                 mv $(DESTDIR)$(libdir)/libsystemd-journal.so.* $(DESTDIR)$(rootlibdir); \
2557         fi
2558
2559 INSTALL_EXEC_HOOKS += \
2560         libsystemd-journal-install-hook
2561
2562 libsystemd-journal-uninstall-hook:
2563         rm -f $(DESTDIR)$(rootlibdir)/libsystemd-journal.so*
2564
2565 UNINSTALL_EXEC_HOOKS += \
2566         libsystemd-journal-uninstall-hook
2567
2568 noinst_PROGRAMS += \
2569         test-journal \
2570         test-journal-send \
2571         test-journal-match \
2572         test-journal-stream \
2573         test-journal-verify
2574
2575 TESTS += \
2576         test-journal \
2577         test-journal-match \
2578         test-journal-stream \
2579         test-journal-verify
2580
2581 pkginclude_HEADERS += \
2582         src/systemd/sd-journal.h \
2583         src/systemd/sd-messages.h
2584
2585 lib_LTLIBRARIES += \
2586         libsystemd-journal.la
2587
2588 noinst_LTLIBRARIES += \
2589         libsystemd-journal-internal.la
2590
2591 rootlibexec_PROGRAMS += \
2592         systemd-journald
2593
2594 rootbin_PROGRAMS += \
2595         journalctl
2596
2597 bin_PROGRAMS += \
2598         systemd-cat
2599
2600 dist_systemunit_DATA += \
2601         units/systemd-journald.socket
2602
2603 nodist_systemunit_DATA += \
2604         units/systemd-journald.service \
2605         units/systemd-journal-flush.service
2606
2607 dist_pkgsysconf_DATA += \
2608         src/journal/journald.conf
2609
2610 pkgconfiglib_DATA += \
2611         src/journal/libsystemd-journal.pc
2612
2613 journal-install-data-hook:
2614         $(MKDIR_P) -m 0755 \
2615                 $(DESTDIR)$(systemunitdir)/sockets.target.wants \
2616                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants
2617         ( cd $(DESTDIR)$(systemunitdir)/sockets.target.wants && \
2618                 rm -f systemd-journald.socket && \
2619                 $(LN_S) ../systemd-journald.socket )
2620         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
2621                 rm -f systemd-journald.service systemd-journal-flush.service && \
2622                 $(LN_S) ../systemd-journald.service && \
2623                 $(LN_S) ../systemd-journal-flush.service )
2624
2625 INSTALL_DATA_HOOKS += \
2626         journal-install-data-hook
2627
2628 EXTRA_DIST += \
2629         src/journal/libsystemd-journal.pc.in \
2630         src/journal/libsystemd-journal.sym \
2631         units/systemd-journald.service.in \
2632         units/systemd-journal-flush.service.in \
2633         src/journal/journald-gperf.gperf
2634
2635 CLEANFILES += \
2636         src/journal/journald-gperf.c
2637
2638 # ------------------------------------------------------------------------------
2639 if ENABLE_COREDUMP
2640 systemd_coredump_SOURCES = \
2641         src/journal/coredump.c
2642
2643 systemd_coredump_LDADD = \
2644         libsystemd-journal-internal.la \
2645         libsystemd-label.la \
2646         libsystemd-shared.la
2647
2648 if ENABLE_LOGIND
2649 systemd_coredump_LDADD += \
2650         libsystemd-login-internal.la
2651 endif
2652
2653 rootlibexec_PROGRAMS += \
2654         systemd-coredump
2655
2656 sysctl_DATA = \
2657         sysctl.d/coredump.conf
2658
2659 CLEANFILES += \
2660         sysctl.d/coredump.conf
2661 endif
2662
2663 EXTRA_DIST += \
2664         sysctl.d/coredump.conf.in
2665
2666 # ------------------------------------------------------------------------------
2667 if ENABLE_BINFMT
2668 systemd_binfmt_SOURCES = \
2669         src/binfmt/binfmt.c
2670
2671 systemd_binfmt_LDADD = \
2672         libsystemd-shared.la
2673
2674 rootlibexec_PROGRAMS += \
2675         systemd-binfmt
2676
2677 dist_systemunit_DATA += \
2678         units/proc-sys-fs-binfmt_misc.automount \
2679         units/proc-sys-fs-binfmt_misc.mount
2680
2681 nodist_systemunit_DATA += \
2682         units/systemd-binfmt.service
2683
2684 binfmt-install-data-hook:
2685         $(MKDIR_P) -m 0755 \
2686                 $(DESTDIR)$(prefix)/lib/binfmt.d \
2687                 $(DESTDIR)$(sysconfdir)/binfmt.d \
2688                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants
2689         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
2690                 rm -f systemd-binfmt.service \
2691                         proc-sys-fs-binfmt_misc.automount && \
2692                 $(LN_S) ../systemd-binfmt.service systemd-binfmt.service && \
2693                 $(LN_S) ../proc-sys-fs-binfmt_misc.automount proc-sys-fs-binfmt_misc.automount )
2694
2695 INSTALL_DATA_HOOKS += \
2696         binfmt-install-data-hook
2697
2698 MANPAGES += \
2699         man/binfmt.d.5 \
2700         man/systemd-binfmt.service.8
2701
2702 MANPAGES_ALIAS +=  \
2703         man/systemd-binfmt.8
2704
2705 man/systemd-binfmt.8: man/systemd-binfmt.service.8
2706 endif
2707
2708 EXTRA_DIST += \
2709         units/systemd-binfmt.service.in
2710
2711 # ------------------------------------------------------------------------------
2712 if ENABLE_VCONSOLE
2713 systemd_vconsole_setup_SOURCES = \
2714         src/vconsole/vconsole-setup.c
2715
2716 systemd_vconsole_setup_LDADD = \
2717         libsystemd-shared.la
2718
2719 rootlibexec_PROGRAMS += \
2720         systemd-vconsole-setup
2721
2722 nodist_systemunit_DATA += \
2723         units/systemd-vconsole-setup.service
2724
2725 vconsole-install-data-hook:
2726         $(MKDIR_P) -m 0755 \
2727                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants
2728         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
2729                 rm -f systemd-vconsole-setup.service && \
2730                 $(LN_S) ../systemd-vconsole-setup.service systemd-vconsole-setup.service )
2731
2732 INSTALL_DATA_HOOKS += \
2733         vconsole-install-data-hook
2734
2735 MANPAGES += \
2736         man/vconsole.conf.5 \
2737         man/systemd-vconsole-setup.service.8
2738
2739 MANPAGES_ALIAS += \
2740         man/systemd-vconsole-setup.8
2741
2742 man/systemd-vconsole-setup.8: man/systemd-vconsole-setup.service.8
2743 endif
2744
2745 EXTRA_DIST += \
2746         units/systemd-vconsole-setup.service.in
2747
2748 # ------------------------------------------------------------------------------
2749 if ENABLE_READAHEAD
2750 systemd_readahead_SOURCES = \
2751         src/readahead/readahead.c \
2752         src/readahead/readahead-collect.c \
2753         src/readahead/readahead-replay.c \
2754         src/readahead/readahead-analyze.c \
2755         src/readahead/readahead-common.c \
2756         src/readahead/readahead-common.h
2757
2758 systemd_readahead_LDADD = \
2759         libsystemd-shared.la \
2760         libsystemd-daemon.la \
2761         libudev.la
2762
2763 dist_doc_DATA += \
2764         src/readahead/sd-readahead.c \
2765         src/systemd/sd-readahead.h
2766
2767 rootlibexec_PROGRAMS += \
2768         systemd-readahead
2769
2770 dist_systemunit_DATA += \
2771         units/systemd-readahead-drop.service \
2772         units/systemd-readahead-done.timer
2773
2774 nodist_systemunit_DATA += \
2775         units/systemd-readahead-collect.service \
2776         units/systemd-readahead-replay.service \
2777         units/systemd-readahead-done.service
2778
2779 MANPAGES += \
2780         man/sd_readahead.3 \
2781         man/sd-readahead.3 \
2782         man/systemd-readahead-replay.service.8
2783
2784 MANPAGES_ALIAS += \
2785         man/systemd-readahead-collect.service.8 \
2786         man/systemd-readahead-done.service.8 \
2787         man/systemd-readahead-done.timer.8 \
2788         man/systemd-readahead.8
2789
2790 man/systemd-readahead-collect.service.8: man/systemd-readahead-replay.service.8
2791 man/systemd-readahead-done.service.8: man/systemd-readahead-replay.service.8
2792 man/systemd-readahead-done.timer.8: man/systemd-readahead-replay.service.8
2793 man/systemd-readahead.8: man/systemd-readahead-replay.service.8
2794
2795 endif
2796
2797 EXTRA_DIST += \
2798         units/systemd-readahead-collect.service.in \
2799         units/systemd-readahead-replay.service.in \
2800         units/systemd-readahead-done.service.in
2801
2802 # ------------------------------------------------------------------------------
2803 if ENABLE_QUOTACHECK
2804 rootlibexec_PROGRAMS += \
2805         systemd-quotacheck
2806
2807 nodist_systemunit_DATA += \
2808         units/systemd-quotacheck.service
2809
2810 systemd_quotacheck_SOURCES = \
2811         src/quotacheck/quotacheck.c
2812
2813 systemd_quotacheck_LDADD = \
2814         libsystemd-shared.la
2815
2816 MANPAGES += \
2817         man/systemd-quotacheck.service.8
2818
2819 MANPAGES_ALIAS += \
2820         man/systemd-quotacheck.8
2821
2822 man/systemd-quotacheck.8: man/systemd-quotacheck.service.8
2823
2824 endif
2825
2826 EXTRA_DIST += \
2827         units/systemd-quotacheck.service.in
2828
2829 nodist_systemunit_DATA += \
2830         units/quotaon.service
2831
2832 # ------------------------------------------------------------------------------
2833 if ENABLE_RANDOMSEED
2834 rootlibexec_PROGRAMS += \
2835         systemd-random-seed
2836
2837 nodist_systemunit_DATA += \
2838         units/systemd-random-seed-save.service \
2839         units/systemd-random-seed-load.service
2840
2841 systemd_random_seed_SOURCES = \
2842         src/random-seed/random-seed.c
2843
2844 systemd_random_seed_LDADD = \
2845         libsystemd-label.la \
2846         libsystemd-shared.la
2847
2848 randomseed-install-data-hook:
2849         $(MKDIR_P) -m 0755 \
2850                 $(DESTDIR)$(systemunitdir)/shutdown.target.wants \
2851                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants
2852         ( cd $(DESTDIR)$(systemunitdir)/shutdown.target.wants && \
2853                 rm -f systemd-random-seed-save.service && \
2854                 $(LN_S) ../systemd-random-seed-save.service systemd-random-seed-save.service )
2855         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
2856                 rm -f systemd-random-seed-load.service && \
2857                 $(LN_S) ../systemd-random-seed-load.service systemd-random-seed-load.service )
2858
2859 INSTALL_DATA_HOOKS += \
2860         randomseed-install-data-hook
2861
2862 MANPAGES += \
2863         man/systemd-random-seed-load.service.8
2864
2865 MANPAGES_ALIAS +=  \
2866         man/systemd-random-seed-save.service.8 \
2867         man/systemd-random-seed.8
2868
2869 man/systemd-random-seed-save.service.8: man/systemd-random-seed-load.service.8
2870 man/systemd-random-seed.8: man/systemd-random-seed-load.service.8
2871
2872 endif
2873
2874 EXTRA_DIST += \
2875         units/systemd-random-seed-save.service.in \
2876         units/systemd-random-seed-load.service.in
2877
2878 # ------------------------------------------------------------------------------
2879 if HAVE_LIBCRYPTSETUP
2880 rootlibexec_PROGRAMS += \
2881         systemd-cryptsetup
2882
2883 systemgenerator_PROGRAMS += \
2884         systemd-cryptsetup-generator
2885
2886 dist_systemunit_DATA += \
2887         units/cryptsetup.target
2888
2889 systemd_cryptsetup_SOURCES = \
2890         src/cryptsetup/cryptsetup.c
2891
2892 systemd_cryptsetup_CFLAGS = \
2893         $(AM_CFLAGS) \
2894         $(LIBCRYPTSETUP_CFLAGS)
2895
2896 systemd_cryptsetup_LDADD = \
2897         libsystemd-label.la \
2898         libsystemd-shared.la \
2899         libudev.la \
2900         $(LIBCRYPTSETUP_LIBS)
2901
2902 systemd_cryptsetup_generator_SOURCES = \
2903         src/cryptsetup/cryptsetup-generator.c
2904
2905 systemd_cryptsetup_generator_LDADD = \
2906         libsystemd-label.la \
2907         libsystemd-shared.la
2908
2909 cryptsetup-install-data-hook:
2910         $(MKDIR_P) -m 0755 \
2911                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants
2912         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
2913                 rm -f cryptsetup.target && \
2914                 $(LN_S) ../cryptsetup.target cryptsetup.target )
2915
2916 INSTALL_DATA_HOOKS += \
2917         cryptsetup-install-data-hook
2918
2919 MANPAGES += \
2920         man/systemd-cryptsetup@.service.8 \
2921         man/systemd-cryptsetup-generator.8 \
2922         man/crypttab.5
2923
2924 MANPAGES_ALIAS += \
2925         man/systemd-cryptsetup.8
2926
2927 man/systemd-cryptsetup.8: man/systemd-cryptsetup@.service.8
2928
2929 endif
2930
2931 # ------------------------------------------------------------------------------
2932 if ENABLE_HOSTNAMED
2933 systemd_hostnamed_SOURCES = \
2934         src/hostname/hostnamed.c
2935
2936 systemd_hostnamed_CFLAGS = \
2937         $(AM_CFLAGS) \
2938         $(DBUS_CFLAGS)
2939
2940 systemd_hostnamed_LDADD = \
2941         libsystemd-shared.la \
2942         libsystemd-daemon.la \
2943         libsystemd-dbus.la
2944
2945 rootlibexec_PROGRAMS += \
2946         systemd-hostnamed
2947
2948 nodist_systemunit_DATA += \
2949         units/systemd-hostnamed.service
2950
2951 dist_dbuspolicy_DATA += \
2952         src/hostname/org.freedesktop.hostname1.conf
2953
2954 dist_dbussystemservice_DATA += \
2955         src/hostname/org.freedesktop.hostname1.service
2956
2957 polkitpolicy_files += \
2958         src/hostname/org.freedesktop.hostname1.policy
2959
2960 dbusinterface_DATA += \
2961         org.freedesktop.hostname1.xml
2962
2963 org.freedesktop.hostname1.xml: systemd-hostnamed
2964         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.hostname1 $< $@.tmp && \
2965                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
2966                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
2967
2968 hostnamed-install-data-hook:
2969         ( cd $(DESTDIR)$(systemunitdir) && \
2970                 rm -f dbus-org.freedesktop.hostname1.service && \
2971                 $(LN_S) systemd-hostnamed.service dbus-org.freedesktop.hostname1.service )
2972
2973 INSTALL_DATA_HOOKS += \
2974         hostnamed-install-data-hook
2975
2976 MANPAGES += \
2977         man/systemd-hostnamed.service.8
2978
2979 MANPAGES_ALIAS += \
2980         man/systemd-hostnamed.8
2981
2982 man/systemd-hostnamed.8: man/systemd-hostnamed.service.8
2983 endif
2984
2985 polkitpolicy_in_files += \
2986         src/hostname/org.freedesktop.hostname1.policy.in
2987
2988 EXTRA_DIST += \
2989         units/systemd-hostnamed.service.in
2990
2991 # ------------------------------------------------------------------------------
2992 if ENABLE_LOCALED
2993 systemd_localed_SOURCES = \
2994         src/locale/localed.c
2995
2996 systemd_localed_CFLAGS = \
2997         $(AM_CFLAGS) \
2998         $(DBUS_CFLAGS)
2999
3000 systemd_localed_LDADD = \
3001         libsystemd-label.la \
3002         libsystemd-shared.la \
3003         libsystemd-daemon.la \
3004         libsystemd-dbus.la
3005
3006 nodist_systemunit_DATA += \
3007         units/systemd-localed.service
3008
3009 rootlibexec_PROGRAMS += \
3010         systemd-localed
3011
3012 dist_dbuspolicy_DATA += \
3013         src/locale/org.freedesktop.locale1.conf
3014
3015 dist_dbussystemservice_DATA += \
3016         src/locale/org.freedesktop.locale1.service
3017
3018 polkitpolicy_files += \
3019         src/locale/org.freedesktop.locale1.policy
3020
3021 dbusinterface_DATA += \
3022         org.freedesktop.locale1.xml
3023
3024 org.freedesktop.locale1.xml: systemd-localed
3025         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.locale1 $< $@.tmp && \
3026                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
3027                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
3028
3029 localed-install-data-hook:
3030         ( cd $(DESTDIR)$(systemunitdir) && \
3031                 rm -f dbus-org.freedesktop.locale1.service && \
3032                 $(LN_S) systemd-localed.service dbus-org.freedesktop.locale1.service )
3033
3034 INSTALL_DATA_HOOKS += \
3035         localed-install-data-hook
3036
3037 MANPAGES += \
3038         man/systemd-localed.service.8
3039
3040 MANPAGES_ALIAS += \
3041         man/systemd-localed.8
3042
3043 man/systemd-localed.8: man/systemd-localed.service.8
3044
3045 dist_pkgdata_DATA += \
3046         src/locale/kbd-model-map
3047
3048 dist_noinst_SCRIPT = \
3049         src/locale/generate-kbd-model-map
3050
3051 update-kbd-model-map:
3052         src/locale/generate-kbd-model-map > src/locale/kbd-model-map
3053
3054 endif
3055
3056 polkitpolicy_in_files += \
3057         src/locale/org.freedesktop.locale1.policy.in
3058
3059 EXTRA_DIST += \
3060         units/systemd-localed.service.in
3061
3062 # ------------------------------------------------------------------------------
3063 if ENABLE_TIMEDATED
3064 systemd_timedated_SOURCES = \
3065         src/timedate/timedated.c
3066
3067 systemd_timedated_CFLAGS = \
3068         $(AM_CFLAGS) \
3069         $(DBUS_CFLAGS)
3070
3071 systemd_timedated_LDADD = \
3072         libsystemd-shared.la \
3073         libsystemd-daemon.la \
3074         libsystemd-dbus.la
3075
3076 rootlibexec_PROGRAMS += \
3077         systemd-timedated
3078
3079 dist_dbussystemservice_DATA += \
3080         src/timedate/org.freedesktop.timedate1.service
3081
3082 dist_dbuspolicy_DATA += \
3083         src/timedate/org.freedesktop.timedate1.conf
3084
3085 nodist_systemunit_DATA += \
3086         units/systemd-timedated.service
3087
3088 polkitpolicy_files += \
3089         src/timedate/org.freedesktop.timedate1.policy
3090
3091 org.freedesktop.timedate1.xml: systemd-timedated
3092         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.timedate1 $< $@.tmp && \
3093                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
3094                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
3095
3096 dbusinterface_DATA += \
3097         org.freedesktop.timedate1.xml
3098
3099 timedated-install-data-hook:
3100         $(MKDIR_P) -m 0755 \
3101                 $(DESTDIR)$(prefix)/lib/systemd/ntp-units.d \
3102                 $(DESTDIR)$(sysconfdir)/systemd/ntp-units.d
3103         ( cd $(DESTDIR)$(systemunitdir) && \
3104                 rm -f dbus-org.freedesktop.timedate1.service  && \
3105                 $(LN_S) systemd-timedated.service dbus-org.freedesktop.timedate1.service )
3106
3107 INSTALL_DATA_HOOKS += \
3108         timedated-install-data-hook
3109
3110 MANPAGES += \
3111         man/systemd-timedated.service.8
3112
3113 MANPAGES_ALIAS += \
3114         man/systemd-timedated.8
3115
3116 man/systemd-timedated.8: man/systemd-timedated.service.8
3117 endif
3118
3119 polkitpolicy_in_files += \
3120         src/timedate/org.freedesktop.timedate1.policy.in
3121
3122 EXTRA_DIST += \
3123         units/systemd-timedated.service.in
3124
3125 # ------------------------------------------------------------------------------
3126 if ENABLE_LOGIND
3127 systemd_logind_SOURCES = \
3128         src/login/logind.c \
3129         src/login/logind.h \
3130         src/login/logind-dbus.c \
3131         src/login/logind-device.c \
3132         src/login/logind-device.h \
3133         src/login/logind-button.c \
3134         src/login/logind-button.h \
3135         src/login/logind-seat.c \
3136         src/login/logind-seat.h \
3137         src/login/logind-session.c \
3138         src/login/logind-session.h \
3139         src/login/logind-user.c \
3140         src/login/logind-user.h \
3141         src/login/logind-inhibit.c \
3142         src/login/logind-inhibit.h \
3143         src/login/logind-session-dbus.c \
3144         src/login/logind-seat-dbus.c \
3145         src/login/logind-user-dbus.c \
3146         src/login/logind-acl.h
3147
3148 nodist_systemd_logind_SOURCES = \
3149         src/login/logind-gperf.c
3150
3151 systemd_logind_CFLAGS = \
3152         $(AM_CFLAGS) \
3153         $(DBUS_CFLAGS)
3154
3155 systemd_logind_LDADD = \
3156         libsystemd-label.la \
3157         libsystemd-shared.la \
3158         libsystemd-audit.la \
3159         libsystemd-daemon.la \
3160         libsystemd-dbus.la \
3161         libudev.la
3162
3163 if HAVE_ACL
3164 systemd_logind_SOURCES += \
3165         src/login/logind-acl.c
3166
3167 systemd_logind_LDADD += \
3168         libsystemd-acl.la
3169 endif
3170
3171 systemd_user_sessions_SOURCES = \
3172         src/login/user-sessions.c
3173
3174 systemd_user_sessions_LDADD = \
3175         libsystemd-shared.la
3176
3177 rootlibexec_PROGRAMS += \
3178         systemd-logind \
3179         systemd-user-sessions
3180
3181 loginctl_SOURCES = \
3182         src/login/loginctl.c \
3183         src/login/sysfs-show.c
3184
3185 loginctl_CFLAGS = \
3186         $(AM_CFLAGS) \
3187         $(DBUS_CFLAGS)
3188
3189 loginctl_LDADD = \
3190         libsystemd-shared.la \
3191         libsystemd-dbus.la \
3192         libudev.la
3193
3194 rootbin_PROGRAMS += \
3195         loginctl
3196
3197 systemd_inhibit_SOURCES = \
3198         src/login/inhibit.c
3199
3200 systemd_inhibit_CFLAGS = \
3201         $(AM_CFLAGS) \
3202         $(DBUS_CFLAGS)
3203
3204 systemd_inhibit_LDADD = \
3205         libsystemd-shared.la \
3206         libsystemd-dbus.la
3207
3208 rootbin_PROGRAMS += \
3209         systemd-inhibit
3210
3211 test_login_SOURCES = \
3212         src/login/test-login.c
3213
3214 test_login_LDADD = \
3215         libsystemd-login-internal.la \
3216         libsystemd-shared.la
3217
3218 test_inhibit_SOURCES = \
3219         src/login/test-inhibit.c
3220
3221 test_inhibit_LDADD = \
3222         libsystemd-shared.la \
3223         libsystemd-dbus.la
3224
3225 test_inhibit_CFLAGS = \
3226         $(AM_CFLAGS) \
3227         $(DBUS_CFLAGS)
3228
3229 noinst_PROGRAMS += \
3230         test-login \
3231         test-inhibit
3232
3233 libsystemd_login_la_SOURCES = \
3234         src/login/sd-login.c
3235
3236 libsystemd_login_la_CFLAGS = \
3237         $(AM_CFLAGS) \
3238         -fvisibility=hidden
3239
3240 libsystemd_login_la_LDFLAGS = \
3241         $(AM_LDFLAGS) \
3242         -shared \
3243         -version-info $(LIBSYSTEMD_LOGIN_CURRENT):$(LIBSYSTEMD_LOGIN_REVISION):$(LIBSYSTEMD_LOGIN_AGE) \
3244         -Wl,--version-script=$(top_srcdir)/src/login/libsystemd-login.sym
3245
3246 libsystemd_login_la_LIBADD = \
3247         libsystemd-shared.la
3248
3249 libsystemd_login_internal_la_SOURCES = \
3250         $(libsystemd_login_la_SOURCES)
3251
3252 if HAVE_PAM
3253 pam_systemd_la_SOURCES = \
3254         src/login/pam-module.c
3255
3256 pam_systemd_la_CFLAGS = \
3257         $(AM_CFLAGS) \
3258         $(PAM_CFLAGS) \
3259         $(DBUS_CFLAGS) \
3260         -fvisibility=hidden
3261
3262 pam_systemd_la_LDFLAGS = \
3263         $(AM_LDFLAGS) \
3264         -module \
3265         -export-dynamic \
3266         -avoid-version \
3267         -shared \
3268         -export-symbols-regex '^pam_sm_.*'
3269
3270 pam_systemd_la_LIBADD = \
3271         libsystemd-daemon.la \
3272         libsystemd-audit.la \
3273         libsystemd-dbus.la \
3274         libsystemd-shared.la \
3275         $(PAM_LIBS)
3276
3277 pamlib_LTLIBRARIES = \
3278         pam_systemd.la
3279 endif
3280
3281 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
3282 libsystemd-login-install-hook:
3283         if test "$(libdir)" != "$(rootlibdir)"; then \
3284                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
3285                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-login.so) && \
3286                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
3287                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-login.so && \
3288                 mv $(DESTDIR)$(libdir)/libsystemd-login.so.* $(DESTDIR)$(rootlibdir); \
3289         fi
3290
3291 INSTALL_EXEC_HOOKS += \
3292         libsystemd-login-install-hook
3293
3294 libsystemd-login-uninstall-hook:
3295         rm -f $(DESTDIR)$(rootlibdir)/libsystemd-login.so*
3296
3297 UNINSTALL_EXEC_HOOKS += \
3298         libsystemd-login-uninstall-hook
3299
3300 nodist_systemunit_DATA += \
3301         units/systemd-logind.service \
3302         units/systemd-user-sessions.service
3303
3304 dist_dbussystemservice_DATA += \
3305         src/login/org.freedesktop.login1.service
3306
3307 dist_dbuspolicy_DATA += \
3308         src/login/org.freedesktop.login1.conf
3309
3310 dist_pkgsysconf_DATA += \
3311         src/login/logind.conf
3312
3313 pkginclude_HEADERS += \
3314         src/systemd/sd-login.h
3315
3316 lib_LTLIBRARIES += \
3317         libsystemd-login.la
3318
3319 noinst_LTLIBRARIES += \
3320         libsystemd-login-internal.la
3321
3322 pkgconfiglib_DATA += \
3323         src/login/libsystemd-login.pc
3324
3325 polkitpolicy_files += \
3326         src/login/org.freedesktop.login1.policy
3327
3328 logind-install-data-hook:
3329         $(MKDIR_P) -m 0755 \
3330                 $(DESTDIR)$(systemunitdir)/multi-user.target.wants \
3331                 $(DESTDIR)$(localstatedir)/lib/systemd
3332         ( cd $(DESTDIR)$(systemunitdir) && \
3333                 rm -f dbus-org.freedesktop.login1.service && \
3334                 $(LN_S) systemd-logind.service dbus-org.freedesktop.login1.service)
3335         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
3336                 rm -f systemd-logind.service systemd-user-sessions.service && \
3337                 $(LN_S) ../systemd-logind.service systemd-logind.service && \
3338                 $(LN_S) ../systemd-user-sessions.service systemd-user-sessions.service )
3339
3340 INSTALL_DATA_HOOKS += \
3341         logind-install-data-hook
3342
3343 systemd_multi_seat_x_SOURCES = \
3344         src/login/multi-seat-x.c
3345
3346 systemd_multi_seat_x_LDADD = \
3347         libsystemd-label.la \
3348         libsystemd-shared.la \
3349         libudev.la
3350
3351 rootlibexec_PROGRAMS += \
3352         systemd-multi-seat-x
3353
3354 dist_udevrules_DATA += \
3355         src/login/70-uaccess.rules \
3356         src/login/70-power-switch.rules
3357
3358 nodist_udevrules_DATA += \
3359         src/login/71-seat.rules \
3360         src/login/73-seat-late.rules
3361
3362 MANPAGES += \
3363         man/systemd-logind.service.8 \
3364         man/logind.conf.5 \
3365         man/sd-login.3 \
3366         man/loginctl.1 \
3367         man/sd_login_monitor_new.3 \
3368         man/sd_pid_get_session.3 \
3369         man/sd_uid_get_state.3 \
3370         man/sd_session_is_active.3 \
3371         man/sd_seat_get_active.3 \
3372         man/sd_get_seats.3 \
3373         man/systemd-user-sessions.service.8
3374
3375 MANPAGES_ALIAS += \
3376         man/sd_login_monitor_unref.3 \
3377         man/sd_login_monitor_flush.3 \
3378         man/sd_login_monitor_get_fd.3 \
3379         man/sd_login_monitor.3 \
3380         man/sd_session_get_uid.3 \
3381         man/sd_session_get_seat.3 \
3382         man/sd_session_get_service.3 \
3383         man/sd_session_get_state.3 \
3384         man/sd_session_get_type.3 \
3385         man/sd_session_get_class.3 \
3386         man/sd_session_get_display.3 \
3387         man/sd_pid_get_owner_uid.3 \
3388         man/sd_pid_get_unit.3 \
3389         man/sd_uid_is_on_seat.3 \
3390         man/sd_uid_get_sessions.3 \
3391         man/sd_uid_get_seats.3 \
3392         man/sd_seat_get_sessions.3 \
3393         man/sd_seat_can_multi_session.3 \
3394         man/sd_get_sessions.3 \
3395         man/sd_get_uids.3 \
3396         man/systemd-logind.8 \
3397         man/systemd-user-sessions.8
3398
3399 man/systemd-logind.8: man/systemd-logind.service.8
3400 man/sd_login_monitor_unref.3: man/sd_login_monitor_new.3
3401 man/sd_login_monitor_flush.3: man/sd_login_monitor_new.3
3402 man/sd_login_monitor_get_fd.3: man/sd_login_monitor_new.3
3403 man/sd_login_monitor.3: man/sd_login_monitor_new.3
3404 man/sd_session_get_uid.3: man/sd_session_is_active.3
3405 man/sd_session_get_seat.3: man/sd_session_is_active.3
3406 man/sd_session_get_service.3: man/sd_session_is_active.3
3407 man/sd_session_get_state.3: man/sd_session_is_active.3
3408 man/sd_session_get_type.3: man/sd_session_is_active.3
3409 man/sd_session_get_class.3: man/sd_session_is_active.3
3410 man/sd_session_get_display.3: man/sd_session_is_active.3
3411 man/sd_pid_get_owner_uid.3: man/sd_pid_get_session.3
3412 man/sd_pid_get_unit.3: man/sd_pid_get_session.3
3413 man/sd_uid_is_on_seat.3: man/sd_uid_get_state.3
3414 man/sd_uid_get_sessions.3: man/sd_uid_get_state.3
3415 man/sd_uid_get_seats.3: man/sd_uid_get_state.3
3416 man/sd_seat_get_sessions.3: man/sd_seat_get_active.3
3417 man/sd_seat_can_multi_session.3: man/sd_seat_get_active.3
3418 man/sd_get_sessions.3: man/sd_get_seats.3
3419 man/sd_get_uids.3: man/sd_get_seats.3
3420 man/systemd-user-sessions.8: man/systemd-user-sessions.service.8
3421
3422 CLEANFILES += \
3423         src/login/logind-gperf.c \
3424         src/login/71-seat.rules \
3425         src/login/73-seat-late.rules
3426 endif
3427
3428 polkitpolicy_in_files += \
3429         src/login/org.freedesktop.login1.policy.in
3430
3431 EXTRA_DIST += \
3432         src/login/logind-gperf.gperf \
3433         src/login/libsystemd-login.pc.in \
3434         src/login/libsystemd-login.sym \
3435         src/login/71-seat.rules.in \
3436         src/login/73-seat-late.rules.in \
3437         units/systemd-logind.service.in \
3438         units/systemd-user-sessions.service.in
3439
3440 # ------------------------------------------------------------------------------
3441
3442 if HAVE_PYTHON_DEVEL
3443
3444 pkgpyexec_LTLIBRARIES = \
3445         _journal.la
3446
3447 _journal_la_SOURCES = \
3448         src/python-systemd/_journal.c
3449
3450 _journal_la_CFLAGS = \
3451         $(AM_CFLAGS) \
3452         -fvisibility=default \
3453         $(PYTHON_CFLAGS)
3454
3455 _journal_la_LDFLAGS = \
3456         $(AM_LDFLAGS) \
3457         -shared \
3458         -module \
3459         -avoid-version
3460
3461 _journal_la_LIBADD = \
3462         $(PYTHON_LIBS) \
3463         libsystemd-journal.la
3464
3465 dist_pkgpyexec_PYTHON = \
3466         src/python-systemd/journal.py \
3467         src/python-systemd/__init__.py
3468
3469 endif
3470
3471 # ------------------------------------------------------------------------------
3472
3473 SED_PROCESS = \
3474         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
3475         $(SED)  -e 's,@rootlibexecdir\@,$(rootlibexecdir),g' \
3476                 -e 's,@rootbindir\@,$(rootbindir),g' \
3477                 -e 's,@bindir\@,$(bindir),g' \
3478                 -e 's,@SYSTEMCTL\@,$(rootbindir)/systemctl,g' \
3479                 -e 's,@SYSTEMD_NOTIFY\@,$(rootbindir)/systemd-notify,g' \
3480                 -e 's,@pkgsysconfdir\@,$(pkgsysconfdir),g' \
3481                 -e 's,@pkgdatadir\@,$(pkgdatadir),g' \
3482                 -e 's,@systemunitdir\@,$(systemunitdir),g' \
3483                 -e 's,@userunitdir\@,$(userunitdir),g' \
3484                 -e 's,@systempresetdir\@,$(systempresetdir),g' \
3485                 -e 's,@userpresetdir\@,$(userpresetdir),g' \
3486                 -e 's,@PACKAGE_VERSION\@,$(PACKAGE_VERSION),g' \
3487                 -e 's,@PACKAGE_NAME\@,$(PACKAGE_NAME),g' \
3488                 -e 's,@PACKAGE_URL\@,$(PACKAGE_URL),g' \
3489                 -e 's,@RANDOM_SEED\@,$(localstatedir)/lib/random-seed,g' \
3490                 -e 's,@prefix\@,$(prefix),g' \
3491                 -e 's,@exec_prefix\@,$(exec_prefix),g' \
3492                 -e 's,@libdir\@,$(libdir),g' \
3493                 -e 's,@includedir\@,$(includedir),g' \
3494                 -e 's,@VERSION\@,$(VERSION),g' \
3495                 -e 's,@rootprefix\@,$(rootprefix),g' \
3496                 -e 's,@udevlibexecdir\@,$(udevlibexecdir),g' \
3497                 -e 's,@sushell\@,$(sushell),g' \
3498                 -e 's,@QUOTAON\@,$(QUOTAON),g' \
3499                 -e 's,@QUOTACHECK\@,$(QUOTACHECK),g' \
3500                 < $< > $@
3501
3502 units/%: units/%.in Makefile
3503         $(SED_PROCESS)
3504
3505 man/%: man/%.in Makefile
3506         $(SED_PROCESS)
3507
3508 sysctl.d/%: sysctl.d/%.in Makefile
3509         $(SED_PROCESS)
3510
3511 %.pc: %.pc.in Makefile
3512         $(SED_PROCESS)
3513
3514 src/core/macros.%: src/core/macros.%.in Makefile
3515         $(SED_PROCESS)
3516
3517 src/%.policy.in: src/%.policy.in.in Makefile
3518         $(SED_PROCESS)
3519
3520 %.rules: %.rules.in Makefile
3521         $(SED_PROCESS)
3522
3523 %.sh: %.sh.in Makefile
3524         $(SED_PROCESS)
3525         $(AM_V_GEN)chmod +x $@
3526
3527 src/%.c: src/%.gperf
3528         $(AM_V_at)$(MKDIR_P) $(dir $@)
3529         $(AM_V_GEN)$(GPERF) < $< > $@
3530
3531 src/%: src/%.m4
3532         $(AM_V_at)$(MKDIR_P) $(dir $@)
3533         $(AM_V_GEN)$(M4) -P $(M4_DEFINES) < $< > $@
3534
3535 M4_PROCESS_SYSTEM = \
3536         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
3537         $(M4) -P $(M4_DEFINES) -DFOR_SYSTEM=1 < $< > $@
3538
3539 M4_PROCESS_USER = \
3540         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
3541         $(M4) -P $(M4_DEFINES) -DFOR_USER=1 < $< > $@
3542
3543 units/%: units/%.m4 Makefile
3544         $(M4_PROCESS_SYSTEM)
3545
3546 units/user/%: units/%.m4 Makefile
3547         $(M4_PROCESS_USER)
3548
3549 nodist_polkitpolicy_DATA = \
3550         $(polkitpolicy_files) \
3551         $(polkitpolicy_in_in_files:.policy.in.in=.policy)
3552
3553 EXTRA_DIST += \
3554         $(polkitpolicy_in_files) \
3555         $(polkitpolicy_in_in_files)
3556
3557 CLEANFILES += \
3558         $(nodist_systemunit_DATA) \
3559         $(nodist_userunit_DATA) \
3560         $(nodist_man_MANS) \
3561         $(pkgconfigdata_DATA) \
3562         $(pkgconfiglib_DATA) \
3563         $(nodist_polkitpolicy_DATA)
3564
3565 if ENABLE_MANPAGES
3566 XSLTPROC_FLAGS = \
3567         --nonet \
3568         --stringparam man.output.quietly 1 \
3569         --stringparam funcsynopsis.style ansi \
3570         --stringparam man.th.extra1.suppress 1 \
3571         --stringparam man.authors.section.enabled 0 \
3572         --stringparam man.copyright.section.enabled 0
3573
3574 XSLTPROC_PROCESS_MAN = \
3575         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
3576         $(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
3577
3578 XSLTPROC_PROCESS_HTML = \
3579         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
3580         $(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) $(srcdir)/man/custom-html.xsl $<
3581
3582 man/%.1: man/%.xml
3583         $(XSLTPROC_PROCESS_MAN)
3584
3585 man/%.3: man/%.xml
3586         $(XSLTPROC_PROCESS_MAN)
3587
3588 man/%.5: man/%.xml
3589         $(XSLTPROC_PROCESS_MAN)
3590
3591 man/%.7: man/%.xml
3592         $(XSLTPROC_PROCESS_MAN)
3593
3594 man/%.8: man/%.xml
3595         $(XSLTPROC_PROCESS_MAN)
3596
3597 man/%.html: man/%.xml man/custom-html.xsl
3598         $(XSLTPROC_PROCESS_HTML)
3599
3600 CLEANFILES += \
3601         $(dist_man_MANS) \
3602         ${XML_FILES:.xml=.html}
3603 endif
3604
3605 DBUS_PREPROCESS = $(CPP) -P $(CFLAGS) $(DBUS_CFLAGS) -imacros dbus/dbus-protocol.h
3606
3607 CLEANFILES += \
3608         $(dbusinterface_DATA)
3609
3610 systemd-install-data-hook:
3611         $(MKDIR_P) -m 0755 \
3612                 $(DESTDIR)$(tmpfilesdir) \
3613                 $(DESTDIR)$(sysconfdir)/tmpfiles.d \
3614                 $(DESTDIR)$(prefix)/lib/modules-load.d \
3615                 $(DESTDIR)$(sysconfdir)/modules-load.d \
3616                 $(DESTDIR)$(prefix)/lib/sysctl.d \
3617                 $(DESTDIR)$(sysconfdir)/sysctl.d \
3618                 $(DESTDIR)$(systemshutdowndir) \
3619                 $(DESTDIR)$(systemsleepdir) \
3620                 $(DESTDIR)$(systemgeneratordir) \
3621                 $(DESTDIR)$(usergeneratordir)
3622         $(MKDIR_P) -m 0755 \
3623                 $(DESTDIR)$(systemunitdir) \
3624                 $(DESTDIR)$(userunitdir) \
3625                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants \
3626                 $(DESTDIR)$(systemunitdir)/sockets.target.wants \
3627                 $(DESTDIR)$(systemunitdir)/basic.target.wants \
3628                 $(DESTDIR)$(systemunitdir)/shutdown.target.wants \
3629                 $(DESTDIR)$(systemunitdir)/local-fs.target.wants \
3630                 $(DESTDIR)$(systemunitdir)/runlevel1.target.wants \
3631                 $(DESTDIR)$(systemunitdir)/runlevel2.target.wants \
3632                 $(DESTDIR)$(systemunitdir)/runlevel3.target.wants \
3633                 $(DESTDIR)$(systemunitdir)/runlevel4.target.wants \
3634                 $(DESTDIR)$(systemunitdir)/runlevel5.target.wants \
3635                 $(DESTDIR)$(systemunitdir)/multi-user.target.wants \
3636                 $(DESTDIR)$(systemunitdir)/graphical.target.wants \
3637                 $(DESTDIR)$(pkgsysconfdir)/system \
3638                 $(DESTDIR)$(pkgsysconfdir)/system/sysinit.target.wants \
3639                 $(DESTDIR)$(pkgsysconfdir)/system/local-fs.target.wants \
3640                 $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants \
3641                 $(DESTDIR)$(pkgsysconfdir)/system/getty.target.wants \
3642                 $(DESTDIR)$(pkgsysconfdir)/user \
3643                 $(DESTDIR)$(dbussessionservicedir) \
3644                 $(DESTDIR)$(sysconfdir)/xdg/systemd
3645         ( cd $(DESTDIR)$(sysconfdir)/xdg/systemd/ && \
3646                 rm -f user && \
3647                 $(LN_S) $(pkgsysconfdir)/user user )
3648         ( cd $(DESTDIR)$(systemunitdir)/sockets.target.wants && \
3649                 rm -f systemd-initctl.socket systemd-shutdownd.socket && \
3650                 $(LN_S) ../systemd-initctl.socket systemd-initctl.socket && \
3651                 $(LN_S) ../systemd-shutdownd.socket systemd-shutdownd.socket )
3652         ( cd $(DESTDIR)$(systemunitdir)/runlevel1.target.wants && \
3653                 rm -f systemd-update-utmp-runlevel.service && \
3654                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
3655         ( cd $(DESTDIR)$(systemunitdir)/runlevel2.target.wants && \
3656                 rm -f systemd-update-utmp-runlevel.service && \
3657                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
3658         ( cd $(DESTDIR)$(systemunitdir)/runlevel3.target.wants && \
3659                 rm -f systemd-update-utmp-runlevel.service && \
3660                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
3661         ( cd $(DESTDIR)$(systemunitdir)/runlevel4.target.wants && \
3662                 rm -f systemd-update-utmp-runlevel.service && \
3663                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
3664         ( cd $(DESTDIR)$(systemunitdir)/runlevel5.target.wants && \
3665                 rm -f systemd-update-utmp-runlevel.service && \
3666                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
3667         ( cd $(DESTDIR)$(systemunitdir)/shutdown.target.wants && \
3668                 rm -f systemd-update-utmp-shutdown.service && \
3669                 $(LN_S) ../systemd-update-utmp-shutdown.service systemd-update-utmp-shutdown.service )
3670         ( cd $(DESTDIR)$(systemunitdir)/local-fs.target.wants && \
3671                 rm -f systemd-remount-fs.service \
3672                         systemd-fsck-root.service \
3673                         tmp.mount && \
3674                 $(LN_S) ../systemd-remount-fs.service systemd-remount-fs.service && \
3675                 $(LN_S) ../systemd-fsck-root.service systemd-fsck-root.service && \
3676                 $(LN_S) ../tmp.mount tmp.mount )
3677         ( cd $(DESTDIR)$(userunitdir) && \
3678                 rm -f shutdown.target sockets.target bluetooth.target printer.target sound.target && \
3679                 $(LN_S) $(systemunitdir)/shutdown.target shutdown.target && \
3680                 $(LN_S) $(systemunitdir)/sockets.target sockets.target && \
3681                 $(LN_S) $(systemunitdir)/bluetooth.target bluetooth.target && \
3682                 $(LN_S) $(systemunitdir)/printer.target printer.target && \
3683                 $(LN_S) $(systemunitdir)/sound.target sound.target )
3684         ( cd $(DESTDIR)$(systemunitdir) && \
3685                 rm -f runlevel0.target runlevel1.target runlevel2.target runlevel3.target runlevel4.target runlevel5.target runlevel6.target && \
3686                 $(LN_S) poweroff.target runlevel0.target && \
3687                 $(LN_S) rescue.target runlevel1.target && \
3688                 $(LN_S) multi-user.target runlevel2.target && \
3689                 $(LN_S) multi-user.target runlevel3.target && \
3690                 $(LN_S) multi-user.target runlevel4.target && \
3691                 $(LN_S) graphical.target runlevel5.target && \
3692                 $(LN_S) reboot.target runlevel6.target )
3693         ( cd $(DESTDIR)$(systemunitdir) && \
3694                 rm -f default.target ctrl-alt-del.target autovt@.service && \
3695                 $(LN_S) graphical.target default.target && \
3696                 $(LN_S) reboot.target ctrl-alt-del.target && \
3697                 $(LN_S) getty@.service autovt@.service )
3698         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
3699                 rm -f getty.target systemd-ask-password-wall.path && \
3700                 $(LN_S) ../getty.target getty.target && \
3701                 $(LN_S) ../systemd-ask-password-wall.path systemd-ask-password-wall.path)
3702         ( cd $(DESTDIR)$(pkgsysconfdir)/system/getty.target.wants && \
3703                 rm -f getty@tty1.service && \
3704                 $(LN_S) $(systemunitdir)/getty@.service getty@tty1.service )
3705         ( cd $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants && \
3706                 rm -f remote-fs.target && \
3707                 $(LN_S) $(systemunitdir)/remote-fs.target remote-fs.target )
3708         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
3709                 rm -f dev-hugepages.mount \
3710                         dev-mqueue.mount \
3711                         sys-kernel-config.mount \
3712                         sys-kernel-debug.mount \
3713                         sys-fs-fuse-connections.mount \
3714                         systemd-modules-load.service \
3715                         systemd-tmpfiles-setup.service \
3716                         systemd-sysctl.service \
3717                         systemd-ask-password-console.path && \
3718                 $(LN_S) ../dev-hugepages.mount dev-hugepages.mount && \
3719                 $(LN_S) ../dev-mqueue.mount dev-mqueue.mount && \
3720                 $(LN_S) ../sys-kernel-config.mount sys-kernel-config.mount && \
3721                 $(LN_S) ../sys-kernel-debug.mount sys-kernel-debug.mount && \
3722                 $(LN_S) ../sys-fs-fuse-connections.mount sys-fs-fuse-connections.mount && \
3723                 $(LN_S) ../systemd-modules-load.service systemd-modules-load.service && \
3724                 $(LN_S) ../systemd-tmpfiles-setup.service systemd-tmpfiles-setup.service && \
3725                 $(LN_S) ../systemd-sysctl.service systemd-sysctl.service && \
3726                 $(LN_S) ../systemd-ask-password-console.path systemd-ask-password-console.path )
3727         ( cd $(DESTDIR)$(systemunitdir)/basic.target.wants && \
3728                 rm -f systemd-tmpfiles-clean.timer && \
3729                 $(LN_S) ../systemd-tmpfiles-clean.timer systemd-tmpfiles-clean.timer )
3730         ( cd $(DESTDIR)$(dbussessionservicedir) && \
3731                 rm -f org.freedesktop.systemd1.service && \
3732                 $(LN_S) ../system-services/org.freedesktop.systemd1.service org.freedesktop.systemd1.service )
3733
3734 if TARGET_FEDORA
3735         ( cd $(DESTDIR)$(systemunitdir) && \
3736                 rm -f display-manager.service single.service && \
3737                 $(LN_S) rescue.service single.service )
3738 endif
3739
3740 if TARGET_MANDRIVA
3741         ( cd $(DESTDIR)$(systemunitdir) && \
3742                 rm -f display-manager.service dm.service single.service && \
3743                 $(LN_S) rescue.service single.service )
3744 endif
3745
3746 if TARGET_DEBIAN_OR_UBUNTU
3747         ( cd $(DESTDIR)$(systemunitdir) && \
3748                 rm -f runlevel5.target && \
3749                 $(LN_S) multi-user.target runlevel5.target )
3750 endif
3751
3752 if TARGET_SUSE
3753         ( cd $(DESTDIR)$(systemunitdir) && \
3754                 rm -f local.service && \
3755                 $(LN_S) rc-local.service local.service )
3756 endif
3757
3758 if TARGET_MAGEIA
3759         ( cd $(DESTDIR)$(systemunitdir) && \
3760                 rm -f display-manager.service )
3761 endif
3762
3763 install-exec-hook: $(INSTALL_EXEC_HOOKS)
3764
3765 uninstall-hook: $(UNINSTALL_EXEC_HOOKS)
3766
3767 install-data-hook: systemd-install-data-hook $(INSTALL_DATA_HOOKS)
3768
3769 distclean-local: $(DISTCLEAN_LOCAL_HOOKS)
3770
3771 clean-local:
3772         rm -rf $(abs_srcdir)/install-tree
3773
3774 DISTCHECK_CONFIGURE_FLAGS = \
3775      &nbs