chiark / gitweb /
build-sys: prepare v190
[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=1
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=4
39 LIBSYSTEMD_LOGIN_AGE=3
40
41 LIBSYSTEMD_DAEMON_CURRENT=0
42 LIBSYSTEMD_DAEMON_REVISION=5
43 LIBSYSTEMD_DAEMON_AGE=0
44
45 LIBSYSTEMD_ID128_CURRENT=0
46 LIBSYSTEMD_ID128_REVISION=10
47 LIBSYSTEMD_ID128_AGE=0
48
49 LIBSYSTEMD_JOURNAL_CURRENT=5
50 LIBSYSTEMD_JOURNAL_REVISION=0
51 LIBSYSTEMD_JOURNAL_AGE=5
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/unit-printf.c \
913         src/core/unit-printf.h \
914         src/core/job.c \
915         src/core/job.h \
916         src/core/manager.c \
917         src/core/manager.h \
918         src/core/transaction.c \
919         src/core/transaction.h \
920         src/core/load-fragment.c \
921         src/core/load-fragment.h \
922         src/core/service.c \
923         src/core/service.h \
924         src/core/automount.c \
925         src/core/automount.h \
926         src/core/mount.c \
927         src/core/mount.h \
928         src/core/swap.c \
929         src/core/swap.h \
930         src/core/device.c \
931         src/core/device.h \
932         src/core/target.c \
933         src/core/target.h \
934         src/core/snapshot.c \
935         src/core/snapshot.h \
936         src/core/socket.c \
937         src/core/socket.h \
938         src/core/timer.c \
939         src/core/timer.h \
940         src/core/path.c \
941         src/core/path.h \
942         src/core/load-dropin.c \
943         src/core/load-dropin.h \
944         src/core/execute.c \
945         src/core/execute.h \
946         src/core/kill.c \
947         src/core/kill.h \
948         src/core/dbus.c \
949         src/core/dbus.h \
950         src/core/dbus-manager.c \
951         src/core/dbus-manager.h \
952         src/core/dbus-unit.c \
953         src/core/dbus-unit.h \
954         src/core/dbus-job.c \
955         src/core/dbus-job.h \
956         src/core/dbus-service.c \
957         src/core/dbus-service.h \
958         src/core/dbus-socket.c \
959         src/core/dbus-socket.h \
960         src/core/dbus-timer.c \
961         src/core/dbus-timer.h \
962         src/core/dbus-target.c \
963         src/core/dbus-target.h \
964         src/core/dbus-mount.c \
965         src/core/dbus-mount.h \
966         src/core/dbus-automount.c \
967         src/core/dbus-automount.h \
968         src/core/dbus-swap.c \
969         src/core/dbus-swap.h \
970         src/core/dbus-snapshot.c \
971         src/core/dbus-snapshot.h \
972         src/core/dbus-device.c \
973         src/core/dbus-device.h \
974         src/core/dbus-execute.c \
975         src/core/dbus-execute.h \
976         src/core/dbus-kill.c \
977         src/core/dbus-kill.h \
978         src/core/dbus-path.c \
979         src/core/dbus-path.h \
980         src/core/cgroup.c \
981         src/core/cgroup.h \
982         src/core/selinux-access.c \
983         src/core/selinux-access.h \
984         src/core/selinux-setup.c \
985         src/core/selinux-setup.h \
986         src/core/ima-setup.c \
987         src/core/ima-setup.h \
988         src/core/kmod-setup.c \
989         src/core/kmod-setup.h \
990         src/core/locale-setup.h \
991         src/core/locale-setup.c \
992         src/core/hostname-setup.c \
993         src/core/hostname-setup.h \
994         src/core/machine-id-setup.c \
995         src/core/machine-id-setup.h \
996         src/core/mount-setup.c \
997         src/core/mount-setup.h \
998         src/core/loopback-setup.h \
999         src/core/loopback-setup.c \
1000         src/core/fdset.c \
1001         src/core/fdset.h \
1002         src/core/condition.c \
1003         src/core/condition.h \
1004         src/core/namespace.c \
1005         src/core/namespace.h \
1006         src/core/tcpwrap.c \
1007         src/core/tcpwrap.h \
1008         src/core/cgroup-attr.c \
1009         src/core/cgroup-attr.h \
1010         src/core/securebits.h \
1011         src/core/initreq.h \
1012         src/core/special.h \
1013         src/core/bus-errors.h \
1014         src/core/build.h \
1015         src/core/sysfs-show.h \
1016         src/core/switch-root.h \
1017         src/core/switch-root.c \
1018         src/core/killall.h \
1019         src/core/killall.c \
1020         src/core/syscall-list.c \
1021         src/core/syscall-list.h
1022
1023 nodist_libsystemd_core_la_SOURCES = \
1024         src/core/load-fragment-gperf.c \
1025         src/core/load-fragment-gperf-nulstr.c \
1026         src/core/syscall-from-name.h \
1027         src/core/syscall-to-name.h
1028
1029 libsystemd_core_la_CFLAGS = \
1030         $(AM_CFLAGS) \
1031         $(DBUS_CFLAGS) \
1032         $(LIBWRAP_CFLAGS) \
1033         $(PAM_CFLAGS) \
1034         $(AUDIT_CFLAGS) \
1035         $(KMOD_CFLAGS)
1036
1037 libsystemd_core_la_LIBADD = \
1038         libsystemd-capability.la \
1039         libsystemd-units.la \
1040         libsystemd-label.la \
1041         libsystemd-shared.la \
1042         libsystemd-dbus.la \
1043         libsystemd-audit.la \
1044         libsystemd-id128-internal.la \
1045         libudev.la \
1046         $(LIBWRAP_LIBS) \
1047         $(PAM_LIBS) \
1048         $(AUDIT_LIBS) \
1049         $(CAP_LIBS) \
1050         $(KMOD_LIBS)
1051
1052 src/core/load-fragment-gperf-nulstr.c: src/core/load-fragment-gperf.gperf
1053         $(AM_V_at)$(MKDIR_P) $(dir $@)
1054         $(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 ";" }' < $< > $@
1055
1056 EXTRA_DIST += \
1057         src/core/load-fragment-gperf.gperf.m4
1058
1059 CLEANFILES += \
1060         src/core/load-fragment-gperf.gperf \
1061         src/core/load-fragment-gperf.c \
1062         src/core/load-fragment-gperf-nulstr.c \
1063         src/core/syscall-list.txt \
1064         src/core/syscall-from-name.gperf
1065
1066 BUILT_SOURCES += \
1067         src/core/syscall-from-name.h \
1068         src/core/syscall-to-name.h
1069
1070 src/core/syscall-list.txt: Makefile
1071         $(AM_V_at)$(MKDIR_P) $(dir $@)
1072         $(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; }' > $@
1073
1074 src/core/syscall-from-name.gperf: src/core/syscall-list.txt Makefile
1075         $(AM_V_at)$(MKDIR_P) $(dir $@)
1076         $(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 }' < $< > $@
1077
1078 src/core/syscall-from-name.h: src/core/syscall-from-name.gperf Makefile
1079         $(AM_V_at)$(MKDIR_P) $(dir $@)
1080         $(AM_V_GEN)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_syscall -H hash_syscall_name -p -C < $< > $@
1081
1082 src/core/syscall-to-name.h: src/core/syscall-list.txt Makefile
1083         $(AM_V_at)$(MKDIR_P) $(dir $@)
1084         $(AM_V_GEN)$(AWK) 'BEGIN{ print "const char* const syscall_names[] = { "} { printf "[__NR_%s] = \"%s\",\n", $$1, $$1 } END{print "};"}' < $< > $@
1085
1086 # ------------------------------------------------------------------------------
1087 systemd_SOURCES = \
1088         src/core/main.c
1089
1090 systemd_CFLAGS = \
1091         $(AM_CFLAGS) \
1092         $(DBUS_CFLAGS)
1093
1094 systemd_LDADD = \
1095         libsystemd-core.la \
1096         libsystemd-daemon.la \
1097         libsystemd-id128-internal.la \
1098         libsystemd-dbus.la
1099
1100 dist_pkgsysconf_DATA += \
1101         src/core/system.conf \
1102         src/core/user.conf
1103
1104 dist_dbuspolicy_DATA += \
1105         src/core/org.freedesktop.systemd1.conf
1106
1107 dist_dbussystemservice_DATA += \
1108         src/core/org.freedesktop.systemd1.service
1109
1110 dbusinterface_DATA += \
1111         org.freedesktop.systemd1.Manager.xml \
1112         org.freedesktop.systemd1.Job.xml \
1113         org.freedesktop.systemd1.Unit.xml \
1114         org.freedesktop.systemd1.Service.xml \
1115         org.freedesktop.systemd1.Socket.xml \
1116         org.freedesktop.systemd1.Timer.xml \
1117         org.freedesktop.systemd1.Target.xml \
1118         org.freedesktop.systemd1.Device.xml \
1119         org.freedesktop.systemd1.Mount.xml \
1120         org.freedesktop.systemd1.Automount.xml \
1121         org.freedesktop.systemd1.Snapshot.xml \
1122         org.freedesktop.systemd1.Swap.xml \
1123         org.freedesktop.systemd1.Path.xml
1124
1125 polkitpolicy_in_in_files = \
1126         src/core/org.freedesktop.systemd1.policy.in.in
1127
1128 org.freedesktop.systemd1.%.xml: systemd
1129         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.$* $< $@.tmp && \
1130                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
1131                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
1132
1133 pkgconfigdata_DATA = \
1134         src/core/systemd.pc
1135
1136 nodist_rpmmacros_DATA = \
1137         src/core/macros.systemd
1138
1139 EXTRA_DIST += \
1140         src/core/systemd.pc.in \
1141         src/core/macros.systemd.in
1142
1143 CLEANFILES += \
1144         src/core/macros.systemd
1145
1146 # ------------------------------------------------------------------------------
1147 noinst_PROGRAMS += \
1148         test-engine \
1149         test-job-type \
1150         test-ns \
1151         test-loopback \
1152         test-hostname \
1153         test-daemon \
1154         test-cgroup \
1155         test-env-replace \
1156         test-strv \
1157         test-install \
1158         test-watchdog \
1159         test-unit-name \
1160         test-log \
1161         test-unit-file
1162
1163 TESTS += \
1164         test-job-type \
1165         test-env-replace \
1166         test-strv \
1167         test-unit-name \
1168         test-unit-file
1169
1170 test_engine_SOURCES = \
1171         src/test/test-engine.c
1172
1173 test_engine_CFLAGS = \
1174         $(AM_CFLAGS) \
1175         $(DBUS_CFLAGS)
1176
1177 test_engine_LDADD = \
1178         libsystemd-core.la \
1179         libsystemd-daemon.la \
1180         libsystemd-dbus.la
1181
1182 test_job_type_SOURCES = \
1183         src/test/test-job-type.c
1184
1185 test_job_type_CFLAGS = \
1186         $(AM_CFLAGS) \
1187         $(DBUS_CFLAGS)
1188
1189 test_job_type_LDADD = \
1190         libsystemd-core.la \
1191         libsystemd-daemon.la
1192
1193 test_ns_SOURCES = \
1194         src/test/test-ns.c
1195
1196 test_ns_LDADD = \
1197         libsystemd-core.la
1198
1199 test_loopback_SOURCES = \
1200         src/test/test-loopback.c
1201
1202 test_loopback_LDADD = \
1203         libsystemd-shared.la \
1204         libsystemd-core.la
1205
1206 test_hostname_SOURCES = \
1207         src/test/test-hostname.c
1208
1209 test_hostname_LDADD = \
1210         libsystemd-core.la
1211
1212 test_unit_name_SOURCES = \
1213         src/test/test-unit-name.c
1214
1215 test_unit_name_LDADD = \
1216         libsystemd-core.la
1217
1218 test_unit_file_SOURCES = \
1219         src/test/test-unit-file.c
1220
1221 test_unit_file_LDADD = \
1222         libsystemd-core.la
1223
1224 test_log_SOURCES = \
1225         src/test/test-log.c
1226
1227 test_log_LDADD = \
1228         libsystemd-core.la
1229
1230 test_daemon_SOURCES = \
1231         src/test/test-daemon.c
1232
1233 test_daemon_LDADD = \
1234         libsystemd-shared.la \
1235         libsystemd-daemon.la
1236
1237 test_cgroup_SOURCES = \
1238         src/test/test-cgroup.c
1239
1240 test_cgroup_LDADD = \
1241         libsystemd-label.la \
1242         libsystemd-shared.la
1243
1244 test_env_replace_SOURCES = \
1245         src/test/test-env-replace.c
1246
1247 test_env_replace_LDADD = \
1248         libsystemd-shared.la
1249
1250 test_strv_SOURCES = \
1251         src/test/test-strv.c
1252
1253 test_strv_LDADD = \
1254         libsystemd-shared.la
1255
1256 test_install_SOURCES = \
1257         src/test/test-install.c
1258
1259 test_install_CFLAGS = \
1260         $(AM_CFLAGS) \
1261         $(DBUS_CFLAGS)
1262
1263 test_install_LDADD = \
1264         libsystemd-units.la \
1265         libsystemd-label.la \
1266         libsystemd-shared.la
1267
1268 test_watchdog_SOURCES = \
1269         src/test/test-watchdog.c
1270
1271 test_watchdog_LDADD = \
1272         libsystemd-shared.la
1273
1274 # ------------------------------------------------------------------------------
1275 systemd_initctl_SOURCES = \
1276         src/initctl/initctl.c
1277
1278 systemd_initctl_CFLAGS = \
1279         $(AM_CFLAGS) \
1280         $(DBUS_CFLAGS)
1281
1282 systemd_initctl_LDADD = \
1283         libsystemd-shared.la \
1284         libsystemd-daemon.la \
1285         libsystemd-dbus.la
1286
1287 # ------------------------------------------------------------------------------
1288 systemd_update_utmp_SOURCES = \
1289         src/update-utmp/update-utmp.c
1290
1291 systemd_update_utmp_CFLAGS = \
1292         $(AM_CFLAGS) \
1293         $(DBUS_CFLAGS) \
1294         $(AUDIT_CFLAGS)
1295
1296 systemd_update_utmp_LDADD = \
1297         libsystemd-shared.la \
1298         libsystemd-dbus.la \
1299         $(AUDIT_LIBS)
1300
1301 # ------------------------------------------------------------------------------
1302 systemd_shutdownd_SOURCES = \
1303         src/shutdownd/shutdownd.c
1304
1305 systemd_shutdownd_LDADD = \
1306         libsystemd-label.la \
1307         libsystemd-shared.la \
1308         libsystemd-daemon.la
1309
1310 pkginclude_HEADERS += \
1311         src/systemd/sd-shutdown.h
1312
1313 # ------------------------------------------------------------------------------
1314 systemd_shutdown_SOURCES = \
1315         src/core/umount.c \
1316         src/core/umount.h \
1317         src/core/shutdown.c \
1318         src/core/mount-setup.c \
1319         src/core/mount-setup.h \
1320         src/core/killall.h \
1321         src/core/killall.c
1322
1323 systemd_shutdown_LDADD = \
1324         libsystemd-label.la \
1325         libsystemd-shared.la \
1326         libudev.la
1327
1328 # ------------------------------------------------------------------------------
1329 systemd_modules_load_SOURCES = \
1330         src/modules-load/modules-load.c
1331
1332 systemd_modules_load_CFLAGS = \
1333         $(AM_CFLAGS) \
1334         $(KMOD_CFLAGS)
1335
1336 systemd_modules_load_LDADD = \
1337         libsystemd-shared.la \
1338         $(KMOD_LIBS)
1339
1340 # ------------------------------------------------------------------------------
1341 systemd_tmpfiles_SOURCES = \
1342         src/tmpfiles/tmpfiles.c
1343
1344 systemd_tmpfiles_LDADD = \
1345         libsystemd-label.la \
1346         libsystemd-shared.la \
1347         libsystemd-capability.la
1348
1349 # ------------------------------------------------------------------------------
1350 systemd_machine_id_setup_SOURCES = \
1351         src/machine-id-setup/machine-id-setup-main.c \
1352         src/core/machine-id-setup.c \
1353         src/core/machine-id-setup.h
1354
1355 systemd_machine_id_setup_LDADD = \
1356         libsystemd-label.la \
1357         libsystemd-shared.la \
1358         libsystemd-id128-internal.la
1359
1360 # ------------------------------------------------------------------------------
1361 systemd_sysctl_SOURCES = \
1362         src/sysctl/sysctl.c
1363
1364 systemd_sysctl_LDADD = \
1365         libsystemd-shared.la
1366
1367 # ------------------------------------------------------------------------------
1368 systemd_sleep_SOURCES = \
1369         src/sleep/sleep.c
1370
1371 systemd_sleep_LDADD = \
1372         libsystemd-shared.la
1373
1374 # ------------------------------------------------------------------------------
1375 systemd_fsck_SOURCES = \
1376         src/fsck/fsck.c
1377
1378 systemd_fsck_CFLAGS = \
1379         $(AM_CFLAGS) \
1380         $(DBUS_CFLAGS)
1381
1382 systemd_fsck_LDADD = \
1383         libsystemd-shared.la \
1384         libsystemd-dbus.la \
1385         libudev.la
1386
1387 # ------------------------------------------------------------------------------
1388 systemd_timestamp_SOURCES = \
1389         src/timestamp/timestamp.c
1390
1391 systemd_timestamp_LDADD = \
1392         libsystemd-shared.la
1393
1394 # ------------------------------------------------------------------------------
1395 systemd_ac_power_SOURCES = \
1396         src/ac-power/ac-power.c
1397
1398 systemd_ac_power_LDADD = \
1399         libsystemd-shared.la \
1400         libudev.la
1401
1402 # ------------------------------------------------------------------------------
1403 systemd_detect_virt_SOURCES = \
1404         src/detect-virt/detect-virt.c
1405
1406 systemd_detect_virt_LDADD = \
1407         libsystemd-shared.la
1408
1409 # ------------------------------------------------------------------------------
1410 systemd_delta_SOURCES = \
1411         src/delta/delta.c
1412
1413 systemd_delta_LDADD = \
1414         libsystemd-shared.la
1415
1416 # ------------------------------------------------------------------------------
1417 systemd_getty_generator_SOURCES = \
1418         src/getty-generator/getty-generator.c
1419
1420 systemd_getty_generator_LDADD = \
1421         libsystemd-label.la \
1422         libsystemd-shared.la
1423
1424 # ------------------------------------------------------------------------------
1425 systemd_fstab_generator_SOURCES = \
1426         src/fstab-generator/fstab-generator.c \
1427         src/core/mount-setup.c
1428
1429 systemd_fstab_generator_LDADD = \
1430         libsystemd-label.la \
1431         libsystemd-shared.la
1432
1433 # ------------------------------------------------------------------------------
1434 systemd_system_update_generator_SOURCES = \
1435         src/system-update-generator/system-update-generator.c
1436
1437 systemd_system_update_generator_LDADD = \
1438         libsystemd-label.la \
1439         libsystemd-shared.la
1440
1441 # ------------------------------------------------------------------------------
1442 systemd_rc_local_generator_SOURCES = \
1443         src/rc-local-generator/rc-local-generator.c
1444
1445 systemd_rc_local_generator_LDADD = \
1446         libsystemd-label.la \
1447         libsystemd-shared.la
1448
1449 # ------------------------------------------------------------------------------
1450 systemd_remount_fs_SOURCES = \
1451         src/remount-fs/remount-fs.c \
1452         src/core/mount-setup.c \
1453         src/core/mount-setup.h
1454
1455 systemd_remount_fs_LDADD = \
1456         libsystemd-label.la \
1457         libsystemd-shared.la
1458
1459 # ------------------------------------------------------------------------------
1460 systemd_cgroups_agent_SOURCES = \
1461         src/cgroups-agent/cgroups-agent.c
1462
1463 systemd_cgroups_agent_CFLAGS = \
1464         $(AM_CFLAGS) \
1465         $(DBUS_CFLAGS)
1466
1467 systemd_cgroups_agent_LDADD = \
1468         libsystemd-shared.la \
1469         libsystemd-dbus.la
1470
1471 # ------------------------------------------------------------------------------
1472 systemctl_SOURCES = \
1473         src/systemctl/systemctl.c
1474
1475 systemctl_CFLAGS = \
1476         $(AM_CFLAGS) \
1477         $(DBUS_CFLAGS)
1478
1479 systemctl_LDADD = \
1480         libsystemd-units.la \
1481         libsystemd-label.la \
1482         libsystemd-shared.la \
1483         libsystemd-daemon.la \
1484         libsystemd-dbus.la \
1485         libsystemd-logs.la
1486
1487 # ------------------------------------------------------------------------------
1488 systemd_notify_SOURCES = \
1489         src/notify/notify.c \
1490         src/readahead/sd-readahead.c
1491
1492 systemd_notify_LDADD = \
1493         libsystemd-shared.la \
1494         libsystemd-daemon.la
1495
1496 # ------------------------------------------------------------------------------
1497 systemd_ask_password_SOURCES = \
1498         src/ask-password/ask-password.c
1499
1500 systemd_ask_password_LDADD = \
1501         libsystemd-label.la \
1502         libsystemd-shared.la
1503
1504 # ------------------------------------------------------------------------------
1505 systemd_reply_password_SOURCES = \
1506         src/reply-password/reply-password.c
1507
1508 systemd_reply_password_LDADD = \
1509         libsystemd-shared.la
1510
1511 # ------------------------------------------------------------------------------
1512 systemd_cgls_SOURCES = \
1513         src/cgls/cgls.c
1514
1515 systemd_cgls_LDADD = \
1516         libsystemd-shared.la
1517
1518 # ------------------------------------------------------------------------------
1519 systemd_cgtop_SOURCES = \
1520         src/cgtop/cgtop.c
1521
1522 systemd_cgtop_LDADD = \
1523         libsystemd-shared.la
1524
1525 # ------------------------------------------------------------------------------
1526 systemd_nspawn_SOURCES = \
1527         src/nspawn/nspawn.c \
1528         src/core/mount-setup.c \
1529         src/core/mount-setup.h \
1530         src/core/loopback-setup.c \
1531         src/core/loopback-setup.h
1532
1533 systemd_nspawn_LDADD = \
1534         libsystemd-label.la \
1535         libsystemd-capability.la \
1536         libsystemd-shared.la \
1537         libsystemd-daemon.la \
1538         libsystemd-id128-internal.la
1539
1540 # ------------------------------------------------------------------------------
1541 systemd_stdio_bridge_SOURCES = \
1542         src/stdio-bridge/stdio-bridge.c
1543
1544 systemd_stdio_bridge_LDADD = \
1545         libsystemd-shared.la
1546
1547 # ------------------------------------------------------------------------------
1548 systemd_tty_ask_password_agent_SOURCES = \
1549         src/tty-ask-password-agent/tty-ask-password-agent.c
1550
1551 systemd_tty_ask_password_agent_LDADD = \
1552         libsystemd-label.la \
1553         libsystemd-shared.la
1554
1555 # ------------------------------------------------------------------------------
1556 libsystemd_daemon_la_SOURCES = \
1557         src/libsystemd-daemon/sd-daemon.c
1558
1559 libsystemd_daemon_la_CFLAGS = \
1560         $(AM_CFLAGS) \
1561         -fvisibility=hidden \
1562         -DSD_EXPORT_SYMBOLS
1563
1564 libsystemd_daemon_la_LDFLAGS = \
1565         $(AM_LDFLAGS) \
1566         -shared \
1567         -version-info $(LIBSYSTEMD_DAEMON_CURRENT):$(LIBSYSTEMD_DAEMON_REVISION):$(LIBSYSTEMD_DAEMON_AGE) \
1568         -Wl,--version-script=$(top_srcdir)/src/libsystemd-daemon/libsystemd-daemon.sym
1569
1570 pkginclude_HEADERS += \
1571         src/systemd/sd-daemon.h
1572
1573 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
1574 libsystemd-daemon-install-hook:
1575         if test "$(libdir)" != "$(rootlibdir)"; then \
1576                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
1577                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-daemon.so) && \
1578                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
1579                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-daemon.so && \
1580                 mv $(DESTDIR)$(libdir)/libsystemd-daemon.so.* $(DESTDIR)$(rootlibdir); \
1581         fi
1582
1583 INSTALL_EXEC_HOOKS += \
1584         libsystemd-daemon-install-hook
1585
1586 libsystemd-daemon-uninstall-hook:
1587         rm -f $(DESTDIR)$(rootlibdir)/libsystemd-daemon.so*
1588
1589 UNINSTALL_EXEC_HOOKS += \
1590         libsystemd-daemon-uninstall-hook
1591
1592 lib_LTLIBRARIES += \
1593         libsystemd-daemon.la
1594
1595 pkgconfiglib_DATA += \
1596         src/libsystemd-daemon/libsystemd-daemon.pc
1597
1598 MANPAGES += \
1599         man/sd-daemon.3 \
1600         man/sd_notify.3 \
1601         man/sd_listen_fds.3 \
1602         man/sd_is_fifo.3 \
1603         man/sd_booted.3
1604
1605 MANPAGES_ALIAS += \
1606         man/sd_is_socket.3 \
1607         man/sd_is_socket_unix.3 \
1608         man/sd_is_socket_inet.3 \
1609         man/sd_is_mq.3 \
1610         man/sd_notifyf.3 \
1611         man/SD_LISTEN_FDS_START.3 \
1612         man/SD_EMERG.3 \
1613         man/SD_ALERT.3 \
1614         man/SD_CRIT.3 \
1615         man/SD_ERR.3 \
1616         man/SD_WARNING.3 \
1617         man/SD_NOTICE.3 \
1618         man/SD_INFO.3 \
1619         man/SD_DEBUG.3
1620
1621 man/sd_is_socket.3: man/sd_is_fifo.3
1622 man/sd_is_socket_unix.3: man/sd_is_fifo.3
1623 man/sd_is_socket_inet.3: man/sd_is_fifo.3
1624 man/sd_is_mq.3: man/sd_is_fifo.3
1625 man/sd_notifyf.3: man/sd_notify.3
1626 man/SD_LISTEN_FDS_START.3: man/sd_listen_fds.3
1627 man/SD_EMERG.3: man/sd-daemon.3
1628 man/SD_ALERT.3: man/sd-daemon.3
1629 man/SD_CRIT.3: man/sd-daemon.3
1630 man/SD_ERR.3: man/sd-daemon.3
1631 man/SD_WARNING.3: man/sd-daemon.3
1632 man/SD_NOTICE.3: man/sd-daemon.3
1633 man/SD_INFO.3: man/sd-daemon.3
1634 man/SD_DEBUG.3: man/sd-daemon.3
1635
1636 EXTRA_DIST += \
1637         src/libsystemd-daemon/libsystemd-daemon.pc.in \
1638         src/libsystemd-daemon/libsystemd-daemon.sym
1639
1640 # ------------------------------------------------------------------------------
1641 if ENABLE_GTK_DOC
1642 SUBDIRS += \
1643         docs/libudev
1644 endif
1645
1646 include_HEADERS += \
1647         src/libudev/libudev.h
1648
1649 lib_LTLIBRARIES += \
1650         libudev.la
1651
1652 libudev_la_SOURCES =\
1653         src/libudev/libudev-private.h \
1654         src/libudev/libudev.c \
1655         src/libudev/libudev-list.c \
1656         src/libudev/libudev-util.c \
1657         src/libudev/libudev-device.c \
1658         src/libudev/libudev-enumerate.c \
1659         src/libudev/libudev-monitor.c \
1660         src/libudev/libudev-queue.c
1661
1662 libudev_la_CFLAGS = \
1663         $(AM_CFLAGS) \
1664         -fvisibility=hidden
1665
1666 libudev_la_LDFLAGS = \
1667         $(AM_LDFLAGS) \
1668         -version-info $(LIBUDEV_CURRENT):$(LIBUDEV_REVISION):$(LIBUDEV_AGE) \
1669         -Wl,--version-script=$(top_srcdir)/src/libudev/libudev.sym
1670
1671 libudev_la_LIBADD = \
1672         libsystemd-shared.la
1673
1674 pkgconfiglib_DATA += \
1675         src/libudev/libudev.pc
1676
1677 EXTRA_DIST += \
1678         src/libudev/libudev.pc.in \
1679         src/libudev/libudev.sym
1680
1681 CLEANFILES += \
1682         src/libudev/libudev.pc
1683
1684 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
1685 libudev-install-move-hook:
1686         if test "$(libdir)" != "$(rootlibdir)"; then \
1687                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
1688                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libudev.so) && \
1689                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
1690                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libudev.so && \
1691                 mv $(DESTDIR)$(libdir)/libudev.so.* $(DESTDIR)$(rootlibdir); \
1692         fi
1693
1694 libudev-uninstall-move-hook:
1695         rm -f $(DESTDIR)$(rootlibdir)/libudev.so*
1696
1697 INSTALL_EXEC_HOOKS += libudev-install-move-hook
1698 UNINSTALL_EXEC_HOOKS += libudev-uninstall-move-hook
1699
1700 # ------------------------------------------------------------------------------
1701 noinst_LTLIBRARIES += \
1702         libudev-private.la
1703
1704 libudev_private_la_SOURCES =\
1705         $(libudev_la_SOURCES) \
1706         src/libudev/libudev-device-private.c \
1707         src/libudev/libudev-queue-private.c
1708
1709 libudev_private_la_CFLAGS = \
1710         $(AM_CFLAGS) \
1711         -fvisibility=default
1712
1713 libudev_private_la_LIBADD = \
1714         libsystemd-shared.la
1715
1716 # ------------------------------------------------------------------------------
1717 MANPAGES += \
1718         man/udev.7 \
1719         man/udevadm.8 \
1720         man/systemd-udevd.service.8
1721
1722 MANPAGES_ALIAS += \
1723         man/systemd-udevd.8 \
1724         man/systemd-udevd-control.socket.8 \
1725         man/systemd-udevd-kernel.socket.8
1726
1727 man/systemd-udevd.8: man/systemd-udevd.service.8
1728 man/systemd-udevd-control.socket.8: man/systemd-udevd.service.8
1729 man/systemd-udevd-kernel.socket.8: man/systemd-udevd.service.8
1730
1731 udev-confdirs:
1732         -$(MKDIR_P) $(DESTDIR)$(sysconfdir)/udev/rules.d
1733
1734 INSTALL_DATA_HOOKS += udev-confdirs
1735
1736 dist_udevrules_DATA += \
1737         rules/99-systemd.rules \
1738         rules/42-usb-hid-pm.rules \
1739         rules/50-udev-default.rules \
1740         rules/60-persistent-storage-tape.rules \
1741         rules/60-persistent-serial.rules \
1742         rules/60-persistent-input.rules \
1743         rules/60-persistent-alsa.rules \
1744         rules/60-persistent-storage.rules \
1745         rules/64-btrfs.rules \
1746         rules/75-net-description.rules \
1747         rules/75-tty-description.rules \
1748         rules/78-sound-card.rules \
1749         rules/80-drivers.rules \
1750         rules/95-udev-late.rules
1751
1752 udevconfdir = $(sysconfdir)/udev
1753 dist_udevconf_DATA = \
1754         src/udev/udev.conf
1755
1756 sharepkgconfigdir = $(datadir)/pkgconfig
1757 sharepkgconfig_DATA = \
1758         src/udev/udev.pc
1759
1760 EXTRA_DIST += \
1761         rules/99-systemd.rules.in \
1762         src/udev/udev.pc.in
1763
1764 CLEANFILES += \
1765         rules/99-systemd.rules \
1766         src/udev/udev.pc
1767
1768 EXTRA_DIST += \
1769         units/systemd-udevd.service.in \
1770         units/systemd-udev-trigger.service.in \
1771         units/systemd-udev-settle.service.in
1772
1773 CLEANFILES += \
1774         units/systemd-udevd.service \
1775         units/systemd-udev-trigger.service \
1776         units/systemd-udev-settle.service
1777
1778 systemd-install-hook:
1779         $(MKDIR_P) $(DESTDIR)$(systemunitdir)/sockets.target.wants
1780         ln -sf ../systemd-udevd-control.socket $(DESTDIR)$(systemunitdir)/sockets.target.wants/systemd-udevd-control.socket
1781         ln -sf ../systemd-udevd-kernel.socket $(DESTDIR)$(systemunitdir)/sockets.target.wants/systemd-udevd-kernel.socket
1782         $(MKDIR_P) $(DESTDIR)$(systemunitdir)/sysinit.target.wants
1783         ln -sf ../systemd-udevd.service $(DESTDIR)$(systemunitdir)/sysinit.target.wants/systemd-udevd.service
1784         ln -sf ../systemd-udev-trigger.service $(DESTDIR)$(systemunitdir)/sysinit.target.wants/systemd-udev-trigger.service
1785
1786 INSTALL_DATA_HOOKS += systemd-install-hook
1787
1788 bin_PROGRAMS += \
1789         udevadm
1790
1791 rootlibexec_PROGRAMS += \
1792         systemd-udevd
1793
1794 noinst_LTLIBRARIES += \
1795         libudev-core.la
1796
1797 libudev_core_la_SOURCES = \
1798         src/udev/udev.h \
1799         src/udev/udev-event.c \
1800         src/udev/udev-watch.c \
1801         src/udev/udev-node.c \
1802         src/udev/udev-rules.c \
1803         src/udev/udev-ctrl.c \
1804         src/udev/udev-builtin.c \
1805         src/udev/udev-builtin-blkid.c \
1806         src/udev/udev-builtin-btrfs.c \
1807         src/udev/udev-builtin-firmware.c \
1808         src/udev/udev-builtin-hwdb.c \
1809         src/udev/udev-builtin-input_id.c \
1810         src/udev/udev-builtin-kmod.c \
1811         src/udev/udev-builtin-path_id.c \
1812         src/udev/udev-builtin-usb_id.c \
1813         src/libsystemd-daemon/sd-daemon.c
1814
1815 libudev_core_la_CFLAGS = \
1816         $(AM_CFLAGS) \
1817         $(BLKID_CFLAGS) \
1818         $(KMOD_CFLAGS)
1819
1820 libudev_core_la_LIBADD = \
1821         libudev-private.la \
1822         libsystemd-label.la \
1823         libsystemd-shared.la \
1824         $(BLKID_LIBS) \
1825         $(KMOD_LIBS)
1826
1827 libudev_core_la_CPPFLAGS = \
1828         $(AM_CPPFLAGS) \
1829         -DFIRMWARE_PATH="$(FIRMWARE_PATH)" \
1830         -DUSB_DATABASE=\"$(USB_DATABASE)\" -DPCI_DATABASE=\"$(PCI_DATABASE)\"
1831
1832 if HAVE_ACL
1833 libudev_core_la_SOURCES += \
1834         src/udev/udev-builtin-uaccess.c \
1835         src/login/logind-acl.c \
1836         src/login/sd-login.c
1837
1838 libudev_core_la_LIBADD += \
1839         libsystemd-acl.la
1840 endif
1841
1842 systemd_udevd_SOURCES = \
1843         src/udev/udevd.c
1844
1845 systemd_udevd_LDADD = \
1846         libudev-core.la
1847
1848 udevadm_SOURCES = \
1849         src/udev/udevadm.c \
1850         src/udev/udevadm-info.c \
1851         src/udev/udevadm-control.c \
1852         src/udev/udevadm-monitor.c \
1853         src/udev/udevadm-settle.c \
1854         src/udev/udevadm-trigger.c \
1855         src/udev/udevadm-test.c \
1856         src/udev/udevadm-test-builtin.c
1857
1858 udevadm_LDADD = \
1859         libudev-core.la \
1860         libsystemd-shared.la
1861
1862 # ------------------------------------------------------------------------------
1863 TESTS += \
1864         test/udev-test.pl \
1865         test/rules-test.sh
1866
1867 noinst_PROGRAMS += \
1868         test-libudev \
1869         test-udev
1870
1871 test_libudev_SOURCES = \
1872         src/test/test-libudev.c
1873
1874 test_libudev_LDADD = \
1875         libsystemd-label.la \
1876         libsystemd-shared.la \
1877         libudev.la
1878
1879 test_udev_SOURCES = \
1880         src/test/test-udev.c
1881
1882 test_udev_LDADD = \
1883         libudev-core.la \
1884         libsystemd-shared.la \
1885         $(BLKID_LIBS) \
1886         $(KMOD_LIBS) \
1887         $(SELINUX_LIBS)
1888
1889 if HAVE_ACL
1890 test_udev_LDADD += \
1891         libsystemd-acl.la
1892 endif
1893
1894 check_DATA += \
1895         test/sys
1896
1897 # packed sysfs test tree
1898 test/sys:
1899         $(AM_V_at)$(MKDIR_P) $(dir $@)
1900         $(AM_V_GEN)tar -C test/ -xJf $(top_srcdir)/test/sys.tar.xz
1901
1902 test-sys-distclean:
1903         -rm -rf test/sys
1904 DISTCLEAN_LOCAL_HOOKS += test-sys-distclean
1905
1906 EXTRA_DIST += \
1907         test/sys.tar.xz \
1908         test/udev-test.pl \
1909         test/rules-test.sh \
1910         test/rule-syntax-check.py
1911
1912 # ------------------------------------------------------------------------------
1913 ata_id_SOURCES = \
1914         src/udev/ata_id/ata_id.c
1915
1916 ata_id_LDADD = \
1917         libudev-private.la \
1918         libsystemd-shared.la
1919
1920 udevlibexec_PROGRAMS += \
1921         ata_id
1922
1923 # ------------------------------------------------------------------------------
1924 cdrom_id_SOURCES = \
1925         src/udev/cdrom_id/cdrom_id.c
1926
1927 cdrom_id_LDADD = \
1928         libudev.la \
1929         libsystemd-shared.la
1930
1931 udevlibexec_PROGRAMS += \
1932         cdrom_id
1933
1934 dist_udevrules_DATA += \
1935         rules/60-cdrom_id.rules
1936
1937 # ------------------------------------------------------------------------------
1938 collect_SOURCES = \
1939         src/udev/collect/collect.c
1940
1941 collect_LDADD = \
1942         libudev-private.la
1943
1944 udevlibexec_PROGRAMS += \
1945         collect
1946
1947 # ------------------------------------------------------------------------------
1948 scsi_id_SOURCES =\
1949         src/udev/scsi_id/scsi_id.c \
1950         src/udev/scsi_id/scsi_serial.c \
1951         src/udev/scsi_id/scsi.h \
1952         src/udev/scsi_id/scsi_id.h
1953
1954 scsi_id_LDADD = \
1955         libudev-private.la \
1956         libsystemd-shared.la
1957
1958 udevlibexec_PROGRAMS += \
1959         scsi_id
1960
1961 EXTRA_DIST += \
1962         src/udev/scsi_id/README
1963
1964 # ------------------------------------------------------------------------------
1965 v4l_id_SOURCES = \
1966         src/udev/v4l_id/v4l_id.c
1967
1968 v4l_id_LDADD = \
1969         libudev.la
1970
1971 udevlibexec_PROGRAMS += \
1972         v4l_id
1973
1974 dist_udevrules_DATA += \
1975         rules/60-persistent-v4l.rules
1976
1977 # ------------------------------------------------------------------------------
1978 accelerometer_SOURCES = \
1979         src/udev/accelerometer/accelerometer.c
1980
1981 accelerometer_LDADD = \
1982         libudev.la -lm \
1983         libsystemd-shared.la
1984
1985 udevlibexec_PROGRAMS += \
1986         accelerometer
1987
1988 dist_udevrules_DATA += \
1989         rules/61-accelerometer.rules
1990
1991 # ------------------------------------------------------------------------------
1992 if ENABLE_GUDEV
1993 if ENABLE_GTK_DOC
1994 SUBDIRS += \
1995         docs/gudev
1996 endif
1997
1998 libgudev_includedir = \
1999         $(includedir)/gudev-1.0/gudev
2000
2001 libgudev_include_HEADERS = \
2002         src/gudev/gudev.h \
2003         src/gudev/gudevenums.h \
2004         src/gudev/gudevenumtypes.h \
2005         src/gudev/gudevtypes.h \
2006         src/gudev/gudevclient.h \
2007         src/gudev/gudevdevice.h \
2008         src/gudev/gudevenumerator.h
2009
2010 lib_LTLIBRARIES += libgudev-1.0.la
2011
2012 pkgconfiglib_DATA += \
2013         src/gudev/gudev-1.0.pc
2014
2015 CLEANFILES += \
2016         src/gudev/gudev-1.0.pc
2017
2018 libgudev_1_0_la_SOURCES = \
2019         src/gudev/gudevenums.h \
2020         src/gudev/gudevenumtypes.h \
2021         src/gudev/gudevenumtypes.h\
2022         src/gudev/gudevtypes.h \
2023         src/gudev/gudevclient.h \
2024         src/gudev/gudevclient.c \
2025         src/gudev/gudevdevice.h \
2026         src/gudev/gudevdevice.c \
2027         src/gudev/gudevenumerator.h \
2028         src/gudev/gudevenumerator.c \
2029         src/gudev/gudevprivate.h
2030
2031 nodist_libgudev_1_0_la_SOURCES = \
2032         src/gudev/gudevmarshal.h \
2033         src/gudev/gudevmarshal.c \
2034         src/gudev/gudevenumtypes.h \
2035         src/gudev/gudevenumtypes.c
2036
2037 BUILT_SOURCES += \
2038         $(nodist_libgudev_1_0_la_SOURCES)
2039
2040 libgudev_1_0_la_CPPFLAGS = \
2041         $(AM_CPPFLAGS) \
2042         -I$(top_builddir)/src\
2043         -I$(top_srcdir)/src\
2044         -I$(top_builddir)/src/gudev \
2045         -I$(top_srcdir)/src/gudev \
2046         -D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT \
2047         -D_GUDEV_COMPILATION \
2048         -DG_LOG_DOMAIN=\"GUdev\"
2049
2050 libgudev_1_0_la_CFLAGS = \
2051         $(AM_CFLAGS) \
2052         -fvisibility=default \
2053         $(GLIB_CFLAGS)
2054
2055 libgudev_1_0_la_LIBADD = \
2056         libudev.la \
2057         $(GLIB_LIBS)
2058
2059 libgudev_1_0_la_LDFLAGS = \
2060         $(AM_LDFLAGS) \
2061         -version-info $(LIBGUDEV_CURRENT):$(LIBGUDEV_REVISION):$(LIBGUDEV_AGE) \
2062         -export-dynamic -no-undefined \
2063         -export-symbols-regex '^g_udev_.*'
2064
2065 src/gudev/gudevmarshal.h: src/gudev/gudevmarshal.list
2066         $(AM_V_at)$(MKDIR_P) $(dir $@)
2067         $(AM_V_GEN)glib-genmarshal $< --prefix=g_udev_marshal --header > $@
2068
2069 src/gudev/gudevmarshal.c: src/gudev/gudevmarshal.list
2070         $(AM_V_at)$(MKDIR_P) $(dir $@)
2071         $(AM_V_GEN)echo '#include "gudevmarshal.h"' > $@ && \
2072         glib-genmarshal $< --prefix=g_udev_marshal --body >> $@
2073
2074 src/gudev/gudevenumtypes.%: src/gudev/gudevenumtypes.%.template src/gudev/gudevenums.h
2075         $(AM_V_at)$(MKDIR_P) $(dir $@)
2076         $(AM_V_GEN)glib-mkenums --template $^ > $@
2077
2078 if HAVE_INTROSPECTION
2079 -include $(INTROSPECTION_MAKEFILE)
2080
2081 src/gudev/GUdev-1.0.gir: libgudev-1.0.la
2082
2083 src_gudev_GUdev_1_0_gir_INCLUDES = GObject-2.0
2084
2085 src_gudev_GUdev_1_0_gir_CFLAGS = \
2086         $(INCLUDES) \
2087         -D_GUDEV_COMPILATION \
2088         -D_GUDEV_WORK_AROUND_DEV_T_BUG \
2089         -I$(top_srcdir)/src \
2090         -I$(top_builddir)/src \
2091         -I$(top_srcdir)/src/gdev \
2092         -I$(top_builddir)/src/gdev
2093
2094 src_gudev_GUdev_1_0_gir_LIBS = libgudev-1.0.la
2095
2096 src_gudev_GUdev_1_0_gir_SCANNERFLAGS = \
2097         --pkg-export=gudev-1.0 \
2098         --warn-all
2099
2100 src_gudev_GUdev_1_0_gir_FILES = \
2101         src/gudev/gudev.h \
2102         src/gudev/gudevtypes.h \
2103         src/gudev/gudevenums.h \
2104         src/gudev/gudevenumtypes.h \
2105         src/gudev/gudevclient.h \
2106         src/gudev/gudevdevice.h \
2107         src/gudev/gudevenumerator.h \
2108         src/gudev/gudevclient.c \
2109         src/gudev/gudevdevice.c \
2110         src/gudev/gudevenumerator.c
2111
2112 INTROSPECTION_GIRS = src/gudev/GUdev-1.0.gir
2113 INTROSPECTION_SCANNER_ARGS = --c-include=gudev/gudev.h
2114
2115 girdir = $(datadir)/gir-1.0
2116 gir_DATA = \
2117         src/gudev/GUdev-1.0.gir
2118
2119 typelibsdir = $(libdir)/girepository-1.0
2120 typelibs_DATA = \
2121         src/gudev/GUdev-1.0.typelib
2122
2123 CLEANFILES += $(gir_DATA) $(typelibs_DATA)
2124 endif # HAVE_INTROSPECTION
2125
2126 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
2127 libgudev-install-move-hook:
2128         if test "$(libdir)" != "$(rootlibdir)"; then \
2129                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
2130                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libgudev-1.0.so) && \
2131                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
2132                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libgudev-1.0.so && \
2133                 mv $(DESTDIR)$(libdir)/libgudev-1.0.so.* $(DESTDIR)$(rootlibdir); \
2134         fi
2135
2136 libgudev-uninstall-move-hook:
2137         rm -f $(DESTDIR)$(rootlibdir)/libgudev-1.0.so*
2138
2139 INSTALL_EXEC_HOOKS += libgudev-install-move-hook
2140 UNINSTALL_EXEC_HOOKS += libgudev-uninstall-move-hook
2141 endif
2142
2143 EXTRA_DIST += \
2144         src/gudev/gudev-1.0.pc.in \
2145         src/gudev/gudevmarshal.list \
2146         src/gudev/gudevenumtypes.h.template \
2147         src/gudev/gudevenumtypes.c.template \
2148         src/gudev/gjs-example.js \
2149         src/gudev/seed-example-enum.js \
2150         src/gudev/seed-example.js
2151
2152
2153 # ------------------------------------------------------------------------------
2154 if ENABLE_KEYMAP
2155 keymap_SOURCES = \
2156         src/udev/keymap/keymap.c
2157
2158 keymap_CPPFLAGS = \
2159         $(AM_CPPFLAGS) -I src/udev/keymap
2160
2161 keymap_LDADD = \
2162         libsystemd-shared.la
2163
2164 nodist_keymap_SOURCES = \
2165         src/udev/keymap/keys-from-name.h \
2166         src/udev/keymap/keys-to-name.h
2167
2168 BUILT_SOURCES += \
2169         $(nodist_keymap_SOURCES)
2170
2171 udevlibexec_PROGRAMS += \
2172         keymap
2173
2174 dist_doc_DATA += \
2175         src/udev/keymap/README.keymap.txt
2176
2177 dist_udevrules_DATA += \
2178         src/udev/keymap/95-keymap.rules \
2179         src/udev/keymap/95-keyboard-force-release.rules
2180
2181 dist_udevhome_SCRIPTS = \
2182         src/udev/keymap/findkeyboards \
2183         src/udev/keymap/keyboard-force-release.sh
2184
2185 TESTS += \
2186         src/udev/keymap/check-keymaps.sh
2187
2188 CLEANFILES += \
2189         src/udev/keymap/keys.txt \
2190         src/udev/keymap/keys-from-name.gperf \
2191         src/udev/keymap/keyboard-force-release.sh
2192
2193 udevkeymapdir = $(udevlibexecdir)/keymaps
2194 dist_udevkeymap_DATA = \
2195         keymaps/acer \
2196         keymaps/acer-aspire_5720 \
2197         keymaps/acer-aspire_8930 \
2198         keymaps/acer-aspire_5920g \
2199         keymaps/acer-aspire_6920 \
2200         keymaps/acer-travelmate_c300 \
2201         keymaps/asus \
2202         keymaps/compaq-e_evo \
2203         keymaps/dell \
2204         keymaps/dell-latitude-xt2 \
2205         keymaps/everex-xt5000 \
2206         keymaps/fujitsu-amilo_li_2732 \
2207         keymaps/fujitsu-amilo_pa_2548 \
2208         keymaps/fujitsu-amilo_pro_edition_v3505 \
2209         keymaps/fujitsu-amilo_pro_v3205 \
2210         keymaps/fujitsu-amilo_si_1520 \
2211         keymaps/fujitsu-esprimo_mobile_v5 \
2212         keymaps/fujitsu-esprimo_mobile_v6 \
2213         keymaps/genius-slimstar-320 \
2214         keymaps/hewlett-packard \
2215         keymaps/hewlett-packard-2510p_2530p \
2216         keymaps/hewlett-packard-compaq_elitebook \
2217         keymaps/hewlett-packard-pavilion \
2218         keymaps/hewlett-packard-presario-2100 \
2219         keymaps/hewlett-packard-tablet \
2220         keymaps/hewlett-packard-tx2 \
2221         keymaps/ibm-thinkpad-usb-keyboard-trackpoint \
2222         keymaps/inventec-symphony_6.0_7.0 \
2223         keymaps/lenovo-3000 \
2224         keymaps/lenovo-ideapad \
2225         keymaps/lenovo-thinkpad-usb-keyboard-trackpoint \
2226         keymaps/lenovo-thinkpad_x6_tablet \
2227         keymaps/lenovo-thinkpad_x200_tablet \
2228         keymaps/lg-x110 \
2229         keymaps/logitech-wave \
2230         keymaps/logitech-wave-cordless \
2231         keymaps/logitech-wave-pro-cordless \
2232         keymaps/maxdata-pro_7000 \
2233         keymaps/medion-fid2060 \
2234         keymaps/medionnb-a555 \
2235         keymaps/micro-star \
2236         keymaps/module-asus-w3j \
2237         keymaps/module-ibm \
2238         keymaps/module-lenovo \
2239         keymaps/module-sony \
2240         keymaps/module-sony-old \
2241         keymaps/module-sony-vgn \
2242         keymaps/module-sony-vpc \
2243         keymaps/olpc-xo \
2244         keymaps/onkyo \
2245         keymaps/oqo-model2 \
2246         keymaps/samsung-other \
2247         keymaps/samsung-90x3a \
2248         keymaps/samsung-sq1us \
2249         keymaps/samsung-sx20s \
2250         keymaps/toshiba-satellite_a100 \
2251         keymaps/toshiba-satellite_a110 \
2252         keymaps/toshiba-satellite_m30x \
2253         keymaps/zepto-znote
2254
2255 udevkeymapforcereldir = $(udevlibexecdir)/keymaps/force-release
2256 dist_udevkeymapforcerel_DATA = \
2257         keymaps-force-release/dell-touchpad \
2258         keymaps-force-release/dell-xps \
2259         keymaps-force-release/hp-other \
2260         keymaps-force-release/samsung-other \
2261         keymaps-force-release/samsung-90x3a \
2262         keymaps-force-release/common-volume-keys
2263
2264 src/udev/keymap/keys.txt: Makefile
2265         $(AM_V_at)$(MKDIR_P) $(dir $@)
2266         $(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/' > $@
2267
2268 src/udev/keymap/keys-from-name.gperf: src/udev/keymap/keys.txt Makefile
2269         $(AM_V_GEN)$(AWK) 'BEGIN{ print "struct key { const char* name; unsigned short id; };"; print "%null-strings"; print "%%";} { print $$1 ", " $$1 }' < $< > $@
2270
2271 src/udev/keymap/keys-from-name.h: src/udev/keymap/keys-from-name.gperf Makefile
2272         $(AM_V_GEN)$(GPERF) -L ANSI-C -t --ignore-case -N lookup_key -H hash_key_name -p -C < $< > $@
2273
2274 src/udev/keymap/keys-to-name.h: src/udev/keymap/keys.txt Makefile
2275         $(AM_V_GEN)$(AWK) 'BEGIN{ print "const char* const key_names[KEY_CNT] = { "} { print "[" $$1 "] = \"" $$1 "\"," } END{print "};"}' < $< > $@
2276 endif
2277
2278 EXTRA_DIST += \
2279         src/udev/keymap/check-keymaps.sh \
2280         src/udev/keymap/keyboard-force-release.sh.in
2281
2282 # ------------------------------------------------------------------------------
2283 mtd_probe_SOURCES =  \
2284         src/udev/mtd_probe/mtd_probe.c \
2285         src/udev/mtd_probe/mtd_probe.h \
2286         src/udev/mtd_probe/probe_smartmedia.c
2287
2288 mtd_probe_CPPFLAGS = \
2289         $(AM_CPPFLAGS)
2290
2291 dist_udevrules_DATA += \
2292         rules/75-probe_mtd.rules
2293
2294 udevlibexec_PROGRAMS += \
2295         mtd_probe
2296
2297 # ------------------------------------------------------------------------------
2298 libsystemd_id128_la_SOURCES = \
2299         src/libsystemd-id128/sd-id128.c
2300
2301 libsystemd_id128_la_CFLAGS = \
2302         $(AM_CFLAGS) \
2303         -fvisibility=hidden
2304
2305 libsystemd_id128_la_LDFLAGS = \
2306         $(AM_LDFLAGS) \
2307         -shared \
2308         -version-info $(LIBSYSTEMD_ID128_CURRENT):$(LIBSYSTEMD_ID128_REVISION):$(LIBSYSTEMD_ID128_AGE) \
2309         -Wl,--version-script=$(top_srcdir)/src/libsystemd-id128/libsystemd-id128.sym
2310
2311 libsystemd_id128_la_LIBADD = \
2312         libsystemd-shared.la
2313
2314 libsystemd_id128_internal_la_SOURCES = \
2315         $(libsystemd_id128_la_SOURCES)
2316
2317 test_id128_SOURCES = \
2318         src/test/test-id128.c
2319
2320 test_id128_LDADD = \
2321         libsystemd-shared.la \
2322         libsystemd-id128-internal.la
2323
2324 noinst_PROGRAMS += \
2325         test-id128
2326
2327 TESTS += \
2328         test-id128
2329
2330 pkginclude_HEADERS += \
2331         src/systemd/sd-id128.h
2332
2333 lib_LTLIBRARIES += \
2334         libsystemd-id128.la
2335
2336 noinst_LTLIBRARIES += \
2337         libsystemd-id128-internal.la
2338
2339 pkgconfiglib_DATA += \
2340         src/libsystemd-id128/libsystemd-id128.pc
2341
2342 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
2343 libsystemd-id128-install-hook:
2344         if test "$(libdir)" != "$(rootlibdir)"; then \
2345                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
2346                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-id128.so) && \
2347                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
2348                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-id128.so && \
2349                 mv $(DESTDIR)$(libdir)/libsystemd-id128.so.* $(DESTDIR)$(rootlibdir); \
2350         fi
2351
2352 INSTALL_EXEC_HOOKS += \
2353         libsystemd-id128-install-hook
2354
2355 libsystemd-id128-uninstall-hook:
2356         rm -f $(DESTDIR)$(rootlibdir)/libsystemd-id128.so*
2357
2358 UNINSTALL_EXEC_HOOKS += \
2359         libsystemd-id128-uninstall-hook
2360
2361 EXTRA_DIST += \
2362         src/libsystemd-id128/libsystemd-id128.pc.in \
2363         src/libsystemd-id128/libsystemd-id128.sym
2364
2365 # ------------------------------------------------------------------------------
2366 systemd_journald_SOURCES = \
2367         src/journal/journald.c \
2368         src/journal/journald.h \
2369         src/journal/journald-kmsg.c \
2370         src/journal/journald-kmsg.h \
2371         src/journal/journald-syslog.c \
2372         src/journal/journald-syslog.h \
2373         src/journal/journald-stream.c \
2374         src/journal/journald-stream.h \
2375         src/journal/journald-console.c \
2376         src/journal/journald-console.h \
2377         src/journal/journald-native.c \
2378         src/journal/journald-native.h \
2379         src/journal/journald-rate-limit.c \
2380         src/journal/journald-rate-limit.h \
2381         src/journal/journal-internal.h
2382
2383 nodist_systemd_journald_SOURCES = \
2384         src/journal/journald-gperf.c
2385
2386 systemd_journald_LDADD = \
2387         libsystemd-label.la \
2388         libsystemd-shared.la \
2389         libsystemd-audit.la \
2390         libsystemd-daemon.la \
2391         libsystemd-id128-internal.la \
2392         libsystemd-journal-internal.la \
2393         libudev.la
2394
2395 if ENABLE_LOGIND
2396 systemd_journald_LDADD += \
2397         libsystemd-login-internal.la
2398 endif
2399
2400 if HAVE_ACL
2401 systemd_journald_LDADD += \
2402         libsystemd-acl.la
2403 endif
2404
2405 systemd_cat_SOURCES = \
2406         src/journal/cat.c
2407
2408 systemd_cat_LDADD = \
2409         libsystemd-shared.la \
2410         libsystemd-journal-internal.la
2411
2412 journalctl_SOURCES = \
2413         src/journal/journalctl.c
2414
2415 journalctl_CFLAGS = \
2416         $(AM_CFLAGS)
2417
2418 journalctl_LDADD = \
2419         libsystemd-shared.la \
2420         libsystemd-journal-internal.la \
2421         libsystemd-id128-internal.la \
2422         libsystemd-logs.la
2423
2424 if HAVE_QRENCODE
2425 journalctl_SOURCES += \
2426         src/journal/journal-qrcode.c \
2427         src/journal/journal-qrcode.h
2428
2429 journalctl_CFLAGS += \
2430         $(QRENCODE_CFLAGS)
2431
2432 journalctl_LDADD += \
2433         $(QRENCODE_LIBS)
2434 endif
2435
2436 test_journal_SOURCES = \
2437         src/journal/test-journal.c
2438
2439 test_journal_LDADD = \
2440         libsystemd-shared.la \
2441         libsystemd-journal-internal.la \
2442         libsystemd-id128-internal.la
2443
2444 test_journal_send_SOURCES = \
2445         src/journal/test-journal-send.c
2446
2447 test_journal_send_LDADD = \
2448         libsystemd-shared.la \
2449         libsystemd-journal-internal.la \
2450         libsystemd-id128-internal.la
2451
2452 test_journal_match_SOURCES = \
2453         src/journal/test-journal-match.c
2454
2455 test_journal_match_LDADD = \
2456         libsystemd-shared.la \
2457         libsystemd-journal-internal.la \
2458         libsystemd-id128-internal.la
2459
2460 test_journal_stream_SOURCES = \
2461         src/journal/test-journal-stream.c
2462
2463 test_journal_stream_LDADD = \
2464         libsystemd-shared.la \
2465         libsystemd-journal-internal.la \
2466         libsystemd-id128-internal.la
2467
2468 test_journal_verify_SOURCES = \
2469         src/journal/test-journal-verify.c
2470
2471 test_journal_verify_LDADD = \
2472         libsystemd-shared.la \
2473         libsystemd-journal-internal.la \
2474         libsystemd-id128-internal.la
2475
2476 libsystemd_journal_la_SOURCES = \
2477         src/journal/sd-journal.c \
2478         src/systemd/sd-journal.h \
2479         src/journal/journal-file.c \
2480         src/journal/journal-file.h \
2481         src/journal/journal-vacuum.c \
2482         src/journal/journal-vacuum.h \
2483         src/journal/journal-verify.c \
2484         src/journal/journal-verify.h \
2485         src/journal/lookup3.c \
2486         src/journal/lookup3.h \
2487         src/journal/journal-send.c \
2488         src/journal/sparse-endian.h \
2489         src/journal/journal-def.h \
2490         src/journal/compress.h \
2491         src/journal/mmap-cache.c \
2492         src/journal/mmap-cache.h
2493
2494 libsystemd_journal_la_CFLAGS = \
2495         $(AM_CFLAGS) \
2496         -fvisibility=hidden
2497
2498 libsystemd_journal_la_LDFLAGS = \
2499         $(AM_LDFLAGS) \
2500         -shared \
2501         -version-info $(LIBSYSTEMD_JOURNAL_CURRENT):$(LIBSYSTEMD_JOURNAL_REVISION):$(LIBSYSTEMD_JOURNAL_AGE) \
2502         -Wl,--version-script=$(top_srcdir)/src/journal/libsystemd-journal.sym
2503
2504 libsystemd_journal_la_LIBADD = \
2505         libsystemd-shared.la \
2506         libsystemd-id128-internal.la
2507
2508 libsystemd_journal_internal_la_SOURCES = \
2509         $(libsystemd_journal_la_SOURCES)
2510
2511 libsystemd_journal_internal_la_CFLAGS = \
2512         $(AM_CFLAGS)
2513
2514 libsystemd_journal_internal_la_LIBADD =
2515
2516 if HAVE_XZ
2517 libsystemd_journal_la_SOURCES += \
2518         src/journal/compress.c
2519
2520 libsystemd_journal_la_CFLAGS += \
2521         $(XZ_CFLAGS)
2522
2523 libsystemd_journal_la_LIBADD += \
2524         $(XZ_LIBS)
2525
2526 libsystemd_journal_internal_la_CFLAGS += \
2527         $(XZ_CFLAGS)
2528
2529 libsystemd_journal_internal_la_LIBADD += \
2530         $(XZ_LIBS)
2531
2532 endif
2533
2534 if HAVE_GCRYPT
2535 libsystemd_journal_la_SOURCES += \
2536         src/journal/journal-authenticate.c \
2537         src/journal/journal-authenticate.h \
2538         src/journal/fsprg.c \
2539         src/journal/fsprg.h
2540
2541 libsystemd_journal_la_CFLAGS += \
2542         $(GCRYPT_CFLAGS) \
2543         -Wno-pointer-arith
2544
2545 libsystemd_journal_la_LIBADD += \
2546         $(GCRYPT_LIBS)
2547
2548 libsystemd_journal_internal_la_CFLAGS += \
2549         $(GCRYPT_CFLAGS) \
2550         -Wno-pointer-arith
2551
2552 libsystemd_journal_internal_la_LIBADD += \
2553         $(GCRYPT_LIBS)
2554 endif
2555
2556 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
2557 libsystemd-journal-install-hook:
2558         if test "$(libdir)" != "$(rootlibdir)"; then \
2559                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
2560                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-journal.so) && \
2561                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
2562                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-journal.so && \
2563                 mv $(DESTDIR)$(libdir)/libsystemd-journal.so.* $(DESTDIR)$(rootlibdir); \
2564         fi
2565
2566 INSTALL_EXEC_HOOKS += \
2567         libsystemd-journal-install-hook
2568
2569 libsystemd-journal-uninstall-hook:
2570         rm -f $(DESTDIR)$(rootlibdir)/libsystemd-journal.so*
2571
2572 UNINSTALL_EXEC_HOOKS += \
2573         libsystemd-journal-uninstall-hook
2574
2575 noinst_PROGRAMS += \
2576         test-journal \
2577         test-journal-send \
2578         test-journal-match \
2579         test-journal-stream \
2580         test-journal-verify
2581
2582 TESTS += \
2583         test-journal \
2584         test-journal-match \
2585         test-journal-stream \
2586         test-journal-verify
2587
2588 pkginclude_HEADERS += \
2589         src/systemd/sd-journal.h \
2590         src/systemd/sd-messages.h
2591
2592 lib_LTLIBRARIES += \
2593         libsystemd-journal.la
2594
2595 noinst_LTLIBRARIES += \
2596         libsystemd-journal-internal.la
2597
2598 rootlibexec_PROGRAMS += \
2599         systemd-journald
2600
2601 rootbin_PROGRAMS += \
2602         journalctl
2603
2604 bin_PROGRAMS += \
2605         systemd-cat
2606
2607 dist_systemunit_DATA += \
2608         units/systemd-journald.socket
2609
2610 nodist_systemunit_DATA += \
2611         units/systemd-journald.service \
2612         units/systemd-journal-flush.service
2613
2614 dist_pkgsysconf_DATA += \
2615         src/journal/journald.conf
2616
2617 pkgconfiglib_DATA += \
2618         src/journal/libsystemd-journal.pc
2619
2620 journal-install-data-hook:
2621         $(MKDIR_P) -m 0755 \
2622                 $(DESTDIR)$(systemunitdir)/sockets.target.wants \
2623                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants
2624         ( cd $(DESTDIR)$(systemunitdir)/sockets.target.wants && \
2625                 rm -f systemd-journald.socket && \
2626                 $(LN_S) ../systemd-journald.socket )
2627         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
2628                 rm -f systemd-journald.service systemd-journal-flush.service && \
2629                 $(LN_S) ../systemd-journald.service && \
2630                 $(LN_S) ../systemd-journal-flush.service )
2631
2632 INSTALL_DATA_HOOKS += \
2633         journal-install-data-hook
2634
2635 EXTRA_DIST += \
2636         src/journal/libsystemd-journal.pc.in \
2637         src/journal/libsystemd-journal.sym \
2638         units/systemd-journald.service.in \
2639         units/systemd-journal-flush.service.in \
2640         src/journal/journald-gperf.gperf
2641
2642 CLEANFILES += \
2643         src/journal/journald-gperf.c
2644
2645 # ------------------------------------------------------------------------------
2646 if ENABLE_COREDUMP
2647 systemd_coredump_SOURCES = \
2648         src/journal/coredump.c
2649
2650 systemd_coredump_LDADD = \
2651         libsystemd-journal-internal.la \
2652         libsystemd-label.la \
2653         libsystemd-shared.la
2654
2655 if ENABLE_LOGIND
2656 systemd_coredump_LDADD += \
2657         libsystemd-login-internal.la
2658 endif
2659
2660 rootlibexec_PROGRAMS += \
2661         systemd-coredump
2662
2663 sysctl_DATA = \
2664         sysctl.d/coredump.conf
2665
2666 CLEANFILES += \
2667         sysctl.d/coredump.conf
2668 endif
2669
2670 EXTRA_DIST += \
2671         sysctl.d/coredump.conf.in
2672
2673 # ------------------------------------------------------------------------------
2674 if ENABLE_BINFMT
2675 systemd_binfmt_SOURCES = \
2676         src/binfmt/binfmt.c
2677
2678 systemd_binfmt_LDADD = \
2679         libsystemd-shared.la
2680
2681 rootlibexec_PROGRAMS += \
2682         systemd-binfmt
2683
2684 dist_systemunit_DATA += \
2685         units/proc-sys-fs-binfmt_misc.automount \
2686         units/proc-sys-fs-binfmt_misc.mount
2687
2688 nodist_systemunit_DATA += \
2689         units/systemd-binfmt.service
2690
2691 binfmt-install-data-hook:
2692         $(MKDIR_P) -m 0755 \
2693                 $(DESTDIR)$(prefix)/lib/binfmt.d \
2694                 $(DESTDIR)$(sysconfdir)/binfmt.d \
2695                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants
2696         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
2697                 rm -f systemd-binfmt.service \
2698                         proc-sys-fs-binfmt_misc.automount && \
2699                 $(LN_S) ../systemd-binfmt.service systemd-binfmt.service && \
2700                 $(LN_S) ../proc-sys-fs-binfmt_misc.automount proc-sys-fs-binfmt_misc.automount )
2701
2702 INSTALL_DATA_HOOKS += \
2703         binfmt-install-data-hook
2704
2705 MANPAGES += \
2706         man/binfmt.d.5 \
2707         man/systemd-binfmt.service.8
2708
2709 MANPAGES_ALIAS +=  \
2710         man/systemd-binfmt.8
2711
2712 man/systemd-binfmt.8: man/systemd-binfmt.service.8
2713 endif
2714
2715 EXTRA_DIST += \
2716         units/systemd-binfmt.service.in
2717
2718 # ------------------------------------------------------------------------------
2719 if ENABLE_VCONSOLE
2720 systemd_vconsole_setup_SOURCES = \
2721         src/vconsole/vconsole-setup.c
2722
2723 systemd_vconsole_setup_LDADD = \
2724         libsystemd-shared.la
2725
2726 rootlibexec_PROGRAMS += \
2727         systemd-vconsole-setup
2728
2729 nodist_systemunit_DATA += \
2730         units/systemd-vconsole-setup.service
2731
2732 vconsole-install-data-hook:
2733         $(MKDIR_P) -m 0755 \
2734                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants
2735         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
2736                 rm -f systemd-vconsole-setup.service && \
2737                 $(LN_S) ../systemd-vconsole-setup.service systemd-vconsole-setup.service )
2738
2739 INSTALL_DATA_HOOKS += \
2740         vconsole-install-data-hook
2741
2742 MANPAGES += \
2743         man/vconsole.conf.5 \
2744         man/systemd-vconsole-setup.service.8
2745
2746 MANPAGES_ALIAS += \
2747         man/systemd-vconsole-setup.8
2748
2749 man/systemd-vconsole-setup.8: man/systemd-vconsole-setup.service.8
2750 endif
2751
2752 EXTRA_DIST += \
2753         units/systemd-vconsole-setup.service.in
2754
2755 # ------------------------------------------------------------------------------
2756 if ENABLE_READAHEAD
2757 systemd_readahead_SOURCES = \
2758         src/readahead/readahead.c \
2759         src/readahead/readahead-collect.c \
2760         src/readahead/readahead-replay.c \
2761         src/readahead/readahead-analyze.c \
2762         src/readahead/readahead-common.c \
2763         src/readahead/readahead-common.h
2764
2765 systemd_readahead_LDADD = \
2766         libsystemd-shared.la \
2767         libsystemd-daemon.la \
2768         libudev.la
2769
2770 dist_doc_DATA += \
2771         src/readahead/sd-readahead.c \
2772         src/systemd/sd-readahead.h
2773
2774 rootlibexec_PROGRAMS += \
2775         systemd-readahead
2776
2777 dist_systemunit_DATA += \
2778         units/systemd-readahead-drop.service \
2779         units/systemd-readahead-done.timer
2780
2781 nodist_systemunit_DATA += \
2782         units/systemd-readahead-collect.service \
2783         units/systemd-readahead-replay.service \
2784         units/systemd-readahead-done.service
2785
2786 MANPAGES += \
2787         man/sd_readahead.3 \
2788         man/sd-readahead.3 \
2789         man/systemd-readahead-replay.service.8
2790
2791 MANPAGES_ALIAS += \
2792         man/systemd-readahead-collect.service.8 \
2793         man/systemd-readahead-done.service.8 \
2794         man/systemd-readahead-done.timer.8 \
2795         man/systemd-readahead.8
2796
2797 man/systemd-readahead-collect.service.8: man/systemd-readahead-replay.service.8
2798 man/systemd-readahead-done.service.8: man/systemd-readahead-replay.service.8
2799 man/systemd-readahead-done.timer.8: man/systemd-readahead-replay.service.8
2800 man/systemd-readahead.8: man/systemd-readahead-replay.service.8
2801
2802 endif
2803
2804 EXTRA_DIST += \
2805         units/systemd-readahead-collect.service.in \
2806         units/systemd-readahead-replay.service.in \
2807         units/systemd-readahead-done.service.in
2808
2809 # ------------------------------------------------------------------------------
2810 if ENABLE_QUOTACHECK
2811 rootlibexec_PROGRAMS += \
2812         systemd-quotacheck
2813
2814 nodist_systemunit_DATA += \
2815         units/systemd-quotacheck.service
2816
2817 systemd_quotacheck_SOURCES = \
2818         src/quotacheck/quotacheck.c
2819
2820 systemd_quotacheck_LDADD = \
2821         libsystemd-shared.la
2822
2823 MANPAGES += \
2824         man/systemd-quotacheck.service.8
2825
2826 MANPAGES_ALIAS += \
2827         man/systemd-quotacheck.8
2828
2829 man/systemd-quotacheck.8: man/systemd-quotacheck.service.8
2830
2831 endif
2832
2833 EXTRA_DIST += \
2834         units/systemd-quotacheck.service.in
2835
2836 nodist_systemunit_DATA += \
2837         units/quotaon.service
2838
2839 # ------------------------------------------------------------------------------
2840 if ENABLE_RANDOMSEED
2841 rootlibexec_PROGRAMS += \
2842         systemd-random-seed
2843
2844 nodist_systemunit_DATA += \
2845         units/systemd-random-seed-save.service \
2846         units/systemd-random-seed-load.service
2847
2848 systemd_random_seed_SOURCES = \
2849         src/random-seed/random-seed.c
2850
2851 systemd_random_seed_LDADD = \
2852         libsystemd-label.la \
2853         libsystemd-shared.la
2854
2855 randomseed-install-data-hook:
2856         $(MKDIR_P) -m 0755 \
2857                 $(DESTDIR)$(systemunitdir)/shutdown.target.wants \
2858                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants
2859         ( cd $(DESTDIR)$(systemunitdir)/shutdown.target.wants && \
2860                 rm -f systemd-random-seed-save.service && \
2861                 $(LN_S) ../systemd-random-seed-save.service systemd-random-seed-save.service )
2862         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
2863                 rm -f systemd-random-seed-load.service && \
2864                 $(LN_S) ../systemd-random-seed-load.service systemd-random-seed-load.service )
2865
2866 INSTALL_DATA_HOOKS += \
2867         randomseed-install-data-hook
2868
2869 MANPAGES += \
2870         man/systemd-random-seed-load.service.8
2871
2872 MANPAGES_ALIAS +=  \
2873         man/systemd-random-seed-save.service.8 \
2874         man/systemd-random-seed.8
2875
2876 man/systemd-random-seed-save.service.8: man/systemd-random-seed-load.service.8
2877 man/systemd-random-seed.8: man/systemd-random-seed-load.service.8
2878
2879 endif
2880
2881 EXTRA_DIST += \
2882         units/systemd-random-seed-save.service.in \
2883         units/systemd-random-seed-load.service.in
2884
2885 # ------------------------------------------------------------------------------
2886 if HAVE_LIBCRYPTSETUP
2887 rootlibexec_PROGRAMS += \
2888         systemd-cryptsetup
2889
2890 systemgenerator_PROGRAMS += \
2891         systemd-cryptsetup-generator
2892
2893 dist_systemunit_DATA += \
2894         units/cryptsetup.target
2895
2896 systemd_cryptsetup_SOURCES = \
2897         src/cryptsetup/cryptsetup.c
2898
2899 systemd_cryptsetup_CFLAGS = \
2900         $(AM_CFLAGS) \
2901         $(LIBCRYPTSETUP_CFLAGS)
2902
2903 systemd_cryptsetup_LDADD = \
2904         libsystemd-label.la \
2905         libsystemd-shared.la \
2906         libudev.la \
2907         $(LIBCRYPTSETUP_LIBS)
2908
2909 systemd_cryptsetup_generator_SOURCES = \
2910         src/cryptsetup/cryptsetup-generator.c
2911
2912 systemd_cryptsetup_generator_LDADD = \
2913         libsystemd-label.la \
2914         libsystemd-shared.la
2915
2916 cryptsetup-install-data-hook:
2917         $(MKDIR_P) -m 0755 \
2918                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants
2919         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
2920                 rm -f cryptsetup.target && \
2921                 $(LN_S) ../cryptsetup.target cryptsetup.target )
2922
2923 INSTALL_DATA_HOOKS += \
2924         cryptsetup-install-data-hook
2925
2926 MANPAGES += \
2927         man/systemd-cryptsetup@.service.8 \
2928         man/systemd-cryptsetup-generator.8 \
2929         man/crypttab.5
2930
2931 MANPAGES_ALIAS += \
2932         man/systemd-cryptsetup.8
2933
2934 man/systemd-cryptsetup.8: man/systemd-cryptsetup@.service.8
2935
2936 endif
2937
2938 # ------------------------------------------------------------------------------
2939 if ENABLE_HOSTNAMED
2940 systemd_hostnamed_SOURCES = \
2941         src/hostname/hostnamed.c
2942
2943 systemd_hostnamed_CFLAGS = \
2944         $(AM_CFLAGS) \
2945         $(DBUS_CFLAGS)
2946
2947 systemd_hostnamed_LDADD = \
2948         libsystemd-shared.la \
2949         libsystemd-daemon.la \
2950         libsystemd-dbus.la
2951
2952 rootlibexec_PROGRAMS += \
2953         systemd-hostnamed
2954
2955 nodist_systemunit_DATA += \
2956         units/systemd-hostnamed.service
2957
2958 dist_dbuspolicy_DATA += \
2959         src/hostname/org.freedesktop.hostname1.conf
2960
2961 dist_dbussystemservice_DATA += \
2962         src/hostname/org.freedesktop.hostname1.service
2963
2964 polkitpolicy_files += \
2965         src/hostname/org.freedesktop.hostname1.policy
2966
2967 dbusinterface_DATA += \
2968         org.freedesktop.hostname1.xml
2969
2970 org.freedesktop.hostname1.xml: systemd-hostnamed
2971         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.hostname1 $< $@.tmp && \
2972                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
2973                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
2974
2975 hostnamed-install-data-hook:
2976         ( cd $(DESTDIR)$(systemunitdir) && \
2977                 rm -f dbus-org.freedesktop.hostname1.service && \
2978                 $(LN_S) systemd-hostnamed.service dbus-org.freedesktop.hostname1.service )
2979
2980 INSTALL_DATA_HOOKS += \
2981         hostnamed-install-data-hook
2982
2983 MANPAGES += \
2984         man/systemd-hostnamed.service.8
2985
2986 MANPAGES_ALIAS += \
2987         man/systemd-hostnamed.8
2988
2989 man/systemd-hostnamed.8: man/systemd-hostnamed.service.8
2990 endif
2991
2992 polkitpolicy_in_files += \
2993         src/hostname/org.freedesktop.hostname1.policy.in
2994
2995 EXTRA_DIST += \
2996         units/systemd-hostnamed.service.in
2997
2998 # ------------------------------------------------------------------------------
2999 if ENABLE_LOCALED
3000 systemd_localed_SOURCES = \
3001         src/locale/localed.c
3002
3003 systemd_localed_CFLAGS = \
3004         $(AM_CFLAGS) \
3005         $(DBUS_CFLAGS)
3006
3007 systemd_localed_LDADD = \
3008         libsystemd-label.la \
3009         libsystemd-shared.la \
3010         libsystemd-daemon.la \
3011         libsystemd-dbus.la
3012
3013 nodist_systemunit_DATA += \
3014         units/systemd-localed.service
3015
3016 rootlibexec_PROGRAMS += \
3017         systemd-localed
3018
3019 dist_dbuspolicy_DATA += \
3020         src/locale/org.freedesktop.locale1.conf
3021
3022 dist_dbussystemservice_DATA += \
3023         src/locale/org.freedesktop.locale1.service
3024
3025 polkitpolicy_files += \
3026         src/locale/org.freedesktop.locale1.policy
3027
3028 dbusinterface_DATA += \
3029         org.freedesktop.locale1.xml
3030
3031 org.freedesktop.locale1.xml: systemd-localed
3032         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.locale1 $< $@.tmp && \
3033                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
3034                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
3035
3036 localed-install-data-hook:
3037         ( cd $(DESTDIR)$(systemunitdir) && \
3038                 rm -f dbus-org.freedesktop.locale1.service && \
3039                 $(LN_S) systemd-localed.service dbus-org.freedesktop.locale1.service )
3040
3041 INSTALL_DATA_HOOKS += \
3042         localed-install-data-hook
3043
3044 MANPAGES += \
3045         man/systemd-localed.service.8
3046
3047 MANPAGES_ALIAS += \
3048         man/systemd-localed.8
3049
3050 man/systemd-localed.8: man/systemd-localed.service.8
3051
3052 dist_pkgdata_DATA += \
3053         src/locale/kbd-model-map
3054
3055 dist_noinst_SCRIPT = \
3056         src/locale/generate-kbd-model-map
3057
3058 update-kbd-model-map:
3059         src/locale/generate-kbd-model-map > src/locale/kbd-model-map
3060
3061 endif
3062
3063 polkitpolicy_in_files += \
3064         src/locale/org.freedesktop.locale1.policy.in
3065
3066 EXTRA_DIST += \
3067         units/systemd-localed.service.in
3068
3069 # ------------------------------------------------------------------------------
3070 if ENABLE_TIMEDATED
3071 systemd_timedated_SOURCES = \
3072         src/timedate/timedated.c
3073
3074 systemd_timedated_CFLAGS = \
3075         $(AM_CFLAGS) \
3076         $(DBUS_CFLAGS)
3077
3078 systemd_timedated_LDADD = \
3079         libsystemd-shared.la \
3080         libsystemd-daemon.la \
3081         libsystemd-dbus.la
3082
3083 rootlibexec_PROGRAMS += \
3084         systemd-timedated
3085
3086 dist_dbussystemservice_DATA += \
3087         src/timedate/org.freedesktop.timedate1.service
3088
3089 dist_dbuspolicy_DATA += \
3090         src/timedate/org.freedesktop.timedate1.conf
3091
3092 nodist_systemunit_DATA += \
3093         units/systemd-timedated.service
3094
3095 polkitpolicy_files += \
3096         src/timedate/org.freedesktop.timedate1.policy
3097
3098 org.freedesktop.timedate1.xml: systemd-timedated
3099         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.timedate1 $< $@.tmp && \
3100                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
3101                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
3102
3103 dbusinterface_DATA += \
3104         org.freedesktop.timedate1.xml
3105
3106 timedated-install-data-hook:
3107         $(MKDIR_P) -m 0755 \
3108                 $(DESTDIR)$(prefix)/lib/systemd/ntp-units.d \
3109                 $(DESTDIR)$(sysconfdir)/systemd/ntp-units.d
3110         ( cd $(DESTDIR)$(systemunitdir) && \
3111                 rm -f dbus-org.freedesktop.timedate1.service  && \
3112                 $(LN_S) systemd-timedated.service dbus-org.freedesktop.timedate1.service )
3113
3114 INSTALL_DATA_HOOKS += \
3115         timedated-install-data-hook
3116
3117 MANPAGES += \
3118         man/systemd-timedated.service.8
3119
3120 MANPAGES_ALIAS += \
3121         man/systemd-timedated.8
3122
3123 man/systemd-timedated.8: man/systemd-timedated.service.8
3124 endif
3125
3126 polkitpolicy_in_files += \
3127         src/timedate/org.freedesktop.timedate1.policy.in
3128
3129 EXTRA_DIST += \
3130         units/systemd-timedated.service.in
3131
3132 # ------------------------------------------------------------------------------
3133 if ENABLE_LOGIND
3134 systemd_logind_SOURCES = \
3135         src/login/logind.c \
3136         src/login/logind.h \
3137         src/login/logind-dbus.c \
3138         src/login/logind-device.c \
3139         src/login/logind-device.h \
3140         src/login/logind-button.c \
3141         src/login/logind-button.h \
3142         src/login/logind-seat.c \
3143         src/login/logind-seat.h \
3144         src/login/logind-session.c \
3145         src/login/logind-session.h \
3146         src/login/logind-user.c \
3147         src/login/logind-user.h \
3148         src/login/logind-inhibit.c \
3149         src/login/logind-inhibit.h \
3150         src/login/logind-session-dbus.c \
3151         src/login/logind-seat-dbus.c \
3152         src/login/logind-user-dbus.c \
3153         src/login/logind-acl.h
3154
3155 nodist_systemd_logind_SOURCES = \
3156         src/login/logind-gperf.c
3157
3158 systemd_logind_CFLAGS = \
3159         $(AM_CFLAGS) \
3160         $(DBUS_CFLAGS)
3161
3162 systemd_logind_LDADD = \
3163         libsystemd-label.la \
3164         libsystemd-shared.la \
3165         libsystemd-audit.la \
3166         libsystemd-daemon.la \
3167         libsystemd-dbus.la \
3168         libudev.la
3169
3170 if HAVE_ACL
3171 systemd_logind_SOURCES += \
3172         src/login/logind-acl.c
3173
3174 systemd_logind_LDADD += \
3175         libsystemd-acl.la
3176 endif
3177
3178 systemd_user_sessions_SOURCES = \
3179         src/login/user-sessions.c
3180
3181 systemd_user_sessions_LDADD = \
3182         libsystemd-shared.la
3183
3184 rootlibexec_PROGRAMS += \
3185         systemd-logind \
3186         systemd-user-sessions
3187
3188 loginctl_SOURCES = \
3189         src/login/loginctl.c \
3190         src/login/sysfs-show.c
3191
3192 loginctl_CFLAGS = \
3193         $(AM_CFLAGS) \
3194         $(DBUS_CFLAGS)
3195
3196 loginctl_LDADD = \
3197         libsystemd-shared.la \
3198         libsystemd-dbus.la \
3199         libudev.la
3200
3201 rootbin_PROGRAMS += \
3202         loginctl
3203
3204 systemd_inhibit_SOURCES = \
3205         src/login/inhibit.c
3206
3207 systemd_inhibit_CFLAGS = \
3208         $(AM_CFLAGS) \
3209         $(DBUS_CFLAGS)
3210
3211 systemd_inhibit_LDADD = \
3212         libsystemd-shared.la \
3213         libsystemd-dbus.la
3214
3215 rootbin_PROGRAMS += \
3216         systemd-inhibit
3217
3218 test_login_SOURCES = \
3219         src/login/test-login.c
3220
3221 test_login_LDADD = \
3222         libsystemd-login-internal.la \
3223         libsystemd-shared.la
3224
3225 test_inhibit_SOURCES = \
3226         src/login/test-inhibit.c
3227
3228 test_inhibit_LDADD = \
3229         libsystemd-shared.la \
3230         libsystemd-dbus.la
3231
3232 test_inhibit_CFLAGS = \
3233         $(AM_CFLAGS) \
3234         $(DBUS_CFLAGS)
3235
3236 noinst_PROGRAMS += \
3237         test-login \
3238         test-inhibit
3239
3240 libsystemd_login_la_SOURCES = \
3241         src/login/sd-login.c
3242
3243 libsystemd_login_la_CFLAGS = \
3244         $(AM_CFLAGS) \
3245         -fvisibility=hidden
3246
3247 libsystemd_login_la_LDFLAGS = \
3248         $(AM_LDFLAGS) \
3249         -shared \
3250         -version-info $(LIBSYSTEMD_LOGIN_CURRENT):$(LIBSYSTEMD_LOGIN_REVISION):$(LIBSYSTEMD_LOGIN_AGE) \
3251         -Wl,--version-script=$(top_srcdir)/src/login/libsystemd-login.sym
3252
3253 libsystemd_login_la_LIBADD = \
3254         libsystemd-shared.la
3255
3256 libsystemd_login_internal_la_SOURCES = \
3257         $(libsystemd_login_la_SOURCES)
3258
3259 if HAVE_PAM
3260 pam_systemd_la_SOURCES = \
3261         src/login/pam-module.c
3262
3263 pam_systemd_la_CFLAGS = \
3264         $(AM_CFLAGS) \
3265         $(PAM_CFLAGS) \
3266         $(DBUS_CFLAGS) \
3267         -fvisibility=hidden
3268
3269 pam_systemd_la_LDFLAGS = \
3270         $(AM_LDFLAGS) \
3271         -module \
3272         -export-dynamic \
3273         -avoid-version \
3274         -shared \
3275         -export-symbols-regex '^pam_sm_.*'
3276
3277 pam_systemd_la_LIBADD = \
3278         libsystemd-daemon.la \
3279         libsystemd-audit.la \
3280         libsystemd-dbus.la \
3281         libsystemd-shared.la \
3282         $(PAM_LIBS)
3283
3284 pamlib_LTLIBRARIES = \
3285         pam_systemd.la
3286 endif
3287
3288 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
3289 libsystemd-login-install-hook:
3290         if test "$(libdir)" != "$(rootlibdir)"; then \
3291                 $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \
3292                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-login.so) && \
3293                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
3294                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-login.so && \
3295                 mv $(DESTDIR)$(libdir)/libsystemd-login.so.* $(DESTDIR)$(rootlibdir); \
3296         fi
3297
3298 INSTALL_EXEC_HOOKS += \
3299         libsystemd-login-install-hook
3300
3301 libsystemd-login-uninstall-hook:
3302         rm -f $(DESTDIR)$(rootlibdir)/libsystemd-login.so*
3303
3304 UNINSTALL_EXEC_HOOKS += \
3305         libsystemd-login-uninstall-hook
3306
3307 nodist_systemunit_DATA += \
3308         units/systemd-logind.service \
3309         units/systemd-user-sessions.service
3310
3311 dist_dbussystemservice_DATA += \
3312         src/login/org.freedesktop.login1.service
3313
3314 dist_dbuspolicy_DATA += \
3315         src/login/org.freedesktop.login1.conf
3316
3317 dist_pkgsysconf_DATA += \
3318         src/login/logind.conf
3319
3320 pkginclude_HEADERS += \
3321         src/systemd/sd-login.h
3322
3323 lib_LTLIBRARIES += \
3324         libsystemd-login.la
3325
3326 noinst_LTLIBRARIES += \
3327         libsystemd-login-internal.la
3328
3329 pkgconfiglib_DATA += \
3330         src/login/libsystemd-login.pc
3331
3332 polkitpolicy_files += \
3333         src/login/org.freedesktop.login1.policy
3334
3335 logind-install-data-hook:
3336         $(MKDIR_P) -m 0755 \
3337                 $(DESTDIR)$(systemunitdir)/multi-user.target.wants \
3338                 $(DESTDIR)$(localstatedir)/lib/systemd
3339         ( cd $(DESTDIR)$(systemunitdir) && \
3340                 rm -f dbus-org.freedesktop.login1.service && \
3341                 $(LN_S) systemd-logind.service dbus-org.freedesktop.login1.service)
3342         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
3343                 rm -f systemd-logind.service systemd-user-sessions.service && \
3344                 $(LN_S) ../systemd-logind.service systemd-logind.service && \
3345                 $(LN_S) ../systemd-user-sessions.service systemd-user-sessions.service )
3346
3347 INSTALL_DATA_HOOKS += \
3348         logind-install-data-hook
3349
3350 systemd_multi_seat_x_SOURCES = \
3351         src/login/multi-seat-x.c
3352
3353 systemd_multi_seat_x_LDADD = \
3354         libsystemd-label.la \
3355         libsystemd-shared.la \
3356         libudev.la
3357
3358 rootlibexec_PROGRAMS += \
3359         systemd-multi-seat-x
3360
3361 dist_udevrules_DATA += \
3362         src/login/70-uaccess.rules \
3363         src/login/70-power-switch.rules
3364
3365 nodist_udevrules_DATA += \
3366         src/login/71-seat.rules \
3367         src/login/73-seat-late.rules
3368
3369 MANPAGES += \
3370         man/systemd-logind.service.8 \
3371         man/logind.conf.5 \
3372         man/sd-login.3 \
3373         man/loginctl.1 \
3374         man/sd_login_monitor_new.3 \
3375         man/sd_pid_get_session.3 \
3376         man/sd_uid_get_state.3 \
3377         man/sd_session_is_active.3 \
3378         man/sd_seat_get_active.3 \
3379         man/sd_get_seats.3 \
3380         man/systemd-user-sessions.service.8
3381
3382 MANPAGES_ALIAS += \
3383         man/sd_login_monitor_unref.3 \
3384         man/sd_login_monitor_flush.3 \
3385         man/sd_login_monitor_get_fd.3 \
3386         man/sd_login_monitor.3 \
3387         man/sd_session_get_uid.3 \
3388         man/sd_session_get_seat.3 \
3389         man/sd_session_get_service.3 \
3390         man/sd_session_get_state.3 \
3391         man/sd_session_get_type.3 \
3392         man/sd_session_get_class.3 \
3393         man/sd_session_get_display.3 \
3394         man/sd_pid_get_owner_uid.3 \
3395         man/sd_pid_get_unit.3 \
3396         man/sd_uid_is_on_seat.3 \
3397         man/sd_uid_get_sessions.3 \
3398         man/sd_uid_get_seats.3 \
3399         man/sd_seat_get_sessions.3 \
3400         man/sd_seat_can_multi_session.3 \
3401         man/sd_get_sessions.3 \
3402         man/sd_get_uids.3 \
3403         man/systemd-logind.8 \
3404         man/systemd-user-sessions.8
3405
3406 man/systemd-logind.8: man/systemd-logind.service.8
3407 man/sd_login_monitor_unref.3: man/sd_login_monitor_new.3
3408 man/sd_login_monitor_flush.3: man/sd_login_monitor_new.3
3409 man/sd_login_monitor_get_fd.3: man/sd_login_monitor_new.3
3410 man/sd_login_monitor.3: man/sd_login_monitor_new.3
3411 man/sd_session_get_uid.3: man/sd_session_is_active.3
3412 man/sd_session_get_seat.3: man/sd_session_is_active.3
3413 man/sd_session_get_service.3: man/sd_session_is_active.3
3414 man/sd_session_get_state.3: man/sd_session_is_active.3
3415 man/sd_session_get_type.3: man/sd_session_is_active.3
3416 man/sd_session_get_class.3: man/sd_session_is_active.3
3417 man/sd_session_get_display.3: man/sd_session_is_active.3
3418 man/sd_pid_get_owner_uid.3: man/sd_pid_get_session.3
3419 man/sd_pid_get_unit.3: man/sd_pid_get_session.3
3420 man/sd_uid_is_on_seat.3: man/sd_uid_get_state.3
3421 man/sd_uid_get_sessions.3: man/sd_uid_get_state.3
3422 man/sd_uid_get_seats.3: man/sd_uid_get_state.3
3423 man/sd_seat_get_sessions.3: man/sd_seat_get_active.3
3424 man/sd_seat_can_multi_session.3: man/sd_seat_get_active.3
3425 man/sd_get_sessions.3: man/sd_get_seats.3
3426 man/sd_get_uids.3: man/sd_get_seats.3
3427 man/systemd-user-sessions.8: man/systemd-user-sessions.service.8
3428
3429 CLEANFILES += \
3430         src/login/logind-gperf.c \
3431         src/login/71-seat.rules \
3432         src/login/73-seat-late.rules
3433 endif
3434
3435 polkitpolicy_in_files += \
3436         src/login/org.freedesktop.login1.policy.in
3437
3438 EXTRA_DIST += \
3439         src/login/logind-gperf.gperf \
3440         src/login/libsystemd-login.pc.in \
3441         src/login/libsystemd-login.sym \
3442         src/login/71-seat.rules.in \
3443         src/login/73-seat-late.rules.in \
3444         units/systemd-logind.service.in \
3445         units/systemd-user-sessions.service.in
3446
3447 # ------------------------------------------------------------------------------
3448
3449 if HAVE_PYTHON_DEVEL
3450
3451 pkgpyexec_LTLIBRARIES = \
3452         _journal.la
3453
3454 _journal_la_SOURCES = \
3455         src/python-systemd/_journal.c
3456
3457 _journal_la_CFLAGS = \
3458         $(AM_CFLAGS) \
3459         -fvisibility=default \
3460         $(PYTHON_CFLAGS)
3461
3462 _journal_la_LDFLAGS = \
3463         $(AM_LDFLAGS) \
3464         -shared \
3465         -module \
3466         -avoid-version
3467
3468 _journal_la_LIBADD = \
3469         $(PYTHON_LIBS) \
3470         libsystemd-journal.la
3471
3472 dist_pkgpyexec_PYTHON = \
3473         src/python-systemd/journal.py \
3474         src/python-systemd/__init__.py
3475
3476 endif
3477
3478 # ------------------------------------------------------------------------------
3479
3480 SED_PROCESS = \
3481         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
3482         $(SED)  -e 's,@rootlibexecdir\@,$(rootlibexecdir),g' \
3483                 -e 's,@rootbindir\@,$(rootbindir),g' \
3484                 -e 's,@bindir\@,$(bindir),g' \
3485                 -e 's,@SYSTEMCTL\@,$(rootbindir)/systemctl,g' \
3486                 -e 's,@SYSTEMD_NOTIFY\@,$(rootbindir)/systemd-notify,g' \
3487                 -e 's,@pkgsysconfdir\@,$(pkgsysconfdir),g' \
3488                 -e 's,@pkgdatadir\@,$(pkgdatadir),g' \
3489                 -e 's,@systemunitdir\@,$(systemunitdir),g' \
3490                 -e 's,@userunitdir\@,$(userunitdir),g' \
3491                 -e 's,@systempresetdir\@,$(systempresetdir),g' \
3492                 -e 's,@userpresetdir\@,$(userpresetdir),g' \
3493                 -e 's,@PACKAGE_VERSION\@,$(PACKAGE_VERSION),g' \
3494                 -e 's,@PACKAGE_NAME\@,$(PACKAGE_NAME),g' \
3495                 -e 's,@PACKAGE_URL\@,$(PACKAGE_URL),g' \
3496                 -e 's,@RANDOM_SEED\@,$(localstatedir)/lib/random-seed,g' \
3497                 -e 's,@prefix\@,$(prefix),g' \
3498                 -e 's,@exec_prefix\@,$(exec_prefix),g' \
3499                 -e 's,@libdir\@,$(libdir),g' \
3500                 -e 's,@includedir\@,$(includedir),g' \
3501                 -e 's,@VERSION\@,$(VERSION),g' \
3502                 -e 's,@rootprefix\@,$(rootprefix),g' \
3503                 -e 's,@udevlibexecdir\@,$(udevlibexecdir),g' \
3504                 -e 's,@sushell\@,$(sushell),g' \
3505                 -e 's,@QUOTAON\@,$(QUOTAON),g' \
3506                 -e 's,@QUOTACHECK\@,$(QUOTACHECK),g' \
3507                 < $< > $@
3508
3509 units/%: units/%.in Makefile
3510         $(SED_PROCESS)
3511
3512 man/%: man/%.in Makefile
3513         $(SED_PROCESS)
3514
3515 sysctl.d/%: sysctl.d/%.in Makefile
3516         $(SED_PROCESS)
3517
3518 %.pc: %.pc.in Makefile
3519         $(SED_PROCESS)
3520
3521 src/core/macros.%: src/core/macros.%.in Makefile
3522         $(SED_PROCESS)
3523
3524 src/%.policy.in: src/%.policy.in.in Makefile
3525         $(SED_PROCESS)
3526
3527 %.rules: %.rules.in Makefile
3528         $(SED_PROCESS)
3529
3530 %.sh: %.sh.in Makefile
3531         $(SED_PROCESS)
3532         $(AM_V_GEN)chmod +x $@
3533
3534 src/%.c: src/%.gperf
3535         $(AM_V_at)$(MKDIR_P) $(dir $@)
3536         $(AM_V_GEN)$(GPERF) < $< > $@
3537
3538 src/%: src/%.m4
3539         $(AM_V_at)$(MKDIR_P) $(dir $@)
3540         $(AM_V_GEN)$(M4) -P $(M4_DEFINES) < $< > $@
3541
3542 M4_PROCESS_SYSTEM = \
3543         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
3544         $(M4) -P $(M4_DEFINES) -DFOR_SYSTEM=1 < $< > $@
3545
3546 M4_PROCESS_USER = \
3547         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
3548         $(M4) -P $(M4_DEFINES) -DFOR_USER=1 < $< > $@
3549
3550 units/%: units/%.m4 Makefile
3551         $(M4_PROCESS_SYSTEM)
3552
3553 units/user/%: units/%.m4 Makefile
3554         $(M4_PROCESS_USER)
3555
3556 nodist_polkitpolicy_DATA = \
3557         $(polkitpolicy_files) \
3558         $(polkitpolicy_in_in_files:.policy.in.in=.policy)
3559
3560 EXTRA_DIST += \
3561         $(polkitpolicy_in_files) \
3562         $(polkitpolicy_in_in_files)
3563
3564 CLEANFILES += \
3565         $(nodist_systemunit_DATA) \
3566         $(nodist_userunit_DATA) \
3567         $(nodist_man_MANS) \
3568         $(pkgconfigdata_DATA) \
3569         $(pkgconfiglib_DATA) \
3570         $(nodist_polkitpolicy_DATA)
3571
3572 if ENABLE_MANPAGES
3573 XSLTPROC_FLAGS = \
3574         --nonet \
3575         --stringparam man.output.quietly 1 \
3576         --stringparam funcsynopsis.style ansi \
3577         --stringparam man.th.extra1.suppress 1 \
3578         --stringparam man.authors.section.enabled 0 \
3579         --stringparam man.copyright.section.enabled 0
3580
3581 XSLTPROC_PROCESS_MAN = \
3582         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
3583         $(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
3584
3585 XSLTPROC_PROCESS_HTML = \
3586         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
3587         $(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) $(srcdir)/man/custom-html.xsl $<
3588
3589 man/%.1: man/%.xml
3590         $(XSLTPROC_PROCESS_MAN)
3591
3592 man/%.3: man/%.xml
3593         $(XSLTPROC_PROCESS_MAN)
3594
3595 man/%.5: man/%.xml
3596         $(XSLTPROC_PROCESS_MAN)
3597
3598 man/%.7: man/%.xml
3599         $(XSLTPROC_PROCESS_MAN)
3600
3601 man/%.8: man/%.xml
3602         $(XSLTPROC_PROCESS_MAN)
3603
3604 man/%.html: man/%.xml man/custom-html.xsl
3605         $(XSLTPROC_PROCESS_HTML)
3606
3607 CLEANFILES += \
3608         $(dist_man_MANS) \
3609         ${XML_FILES:.xml=.html}
3610 endif
3611
3612 DBUS_PREPROCESS = $(CPP) -P $(CFLAGS) $(DBUS_CFLAGS) -imacros dbus/dbus-protocol.h
3613
3614 CLEANFILES += \
3615         $(dbusinterface_DATA)
3616
3617 systemd-install-data-hook:
3618         $(MKDIR_P) -m 0755 \
3619                 $(DESTDIR)$(tmpfilesdir) \
3620                 $(DESTDIR)$(sysconfdir)/tmpfiles.d \
3621                 $(DESTDIR)$(prefix)/lib/modules-load.d \
3622                 $(DESTDIR)$(sysconfdir)/modules-load.d \
3623                 $(DESTDIR)$(prefix)/lib/sysctl.d \
3624                 $(DESTDIR)$(sysconfdir)/sysctl.d \
3625                 $(DESTDIR)$(systemshutdowndir) \
3626                 $(DESTDIR)$(systemsleepdir) \
3627                 $(DESTDIR)$(systemgeneratordir) \
3628                 $(DESTDIR)$(usergeneratordir)
3629         $(MKDIR_P) -m 0755 \
3630                 $(DESTDIR)$(systemunitdir) \
3631                 $(DESTDIR)$(userunitdir) \
3632                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants \
3633                 $(DESTDIR)$(systemunitdir)/sockets.target.wants \
3634                 $(DESTDIR)$(systemunitdir)/basic.target.wants \
3635                 $(DESTDIR)$(systemunitdir)/shutdown.target.wants \
3636                 $(DESTDIR)$(systemunitdir)/local-fs.target.wants \
3637                 $(DESTDIR)$(systemunitdir)/runlevel1.target.wants \
3638                 $(DESTDIR)$(systemunitdir)/runlevel2.target.wants \
3639                 $(DESTDIR)$(systemunitdir)/runlevel3.target.wants \
3640                 $(DESTDIR)$(systemunitdir)/runlevel4.target.wants \
3641                 $(DESTDIR)$(systemunitdir)/runlevel5.target.wants \
3642                 $(DESTDIR)$(systemunitdir)/multi-user.target.wants \
3643                 $(DESTDIR)$(systemunitdir)/graphical.target.wants \
3644                 $(DESTDIR)$(pkgsysconfdir)/system \
3645                 $(DESTDIR)$(pkgsysconfdir)/system/sysinit.target.wants \
3646                 $(DESTDIR)$(pkgsysconfdir)/system/local-fs.target.wants \
3647                 $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants \
3648                 $(DESTDIR)$(pkgsysconfdir)/system/getty.target.wants \
3649                 $(DESTDIR)$(pkgsysconfdir)/user \
3650                 $(DESTDIR)$(dbussessionservicedir) \
3651                 $(DESTDIR)$(sysconfdir)/xdg/systemd
3652         ( cd $(DESTDIR)$(sysconfdir)/xdg/systemd/ && \
3653                 rm -f user && \
3654                 $(LN_S) $(pkgsysconfdir)/user user )
3655         ( cd $(DESTDIR)$(systemunitdir)/sockets.target.wants && \
3656                 rm -f systemd-initctl.socket systemd-shutdownd.socket && \
3657                 $(LN_S) ../systemd-initctl.socket systemd-initctl.socket && \
3658                 $(LN_S) ../systemd-shutdownd.socket systemd-shutdownd.socket )
3659         ( cd $(DESTDIR)$(systemunitdir)/runlevel1.target.wants && \
3660                 rm -f systemd-update-utmp-runlevel.service && \
3661                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
3662         ( cd $(DESTDIR)$(systemunitdir)/runlevel2.target.wants && \
3663                 rm -f systemd-update-utmp-runlevel.service && \
3664                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
3665         ( cd $(DESTDIR)$(systemunitdir)/runlevel3.target.wants && \
3666                 rm -f systemd-update-utmp-runlevel.service && \
3667                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
3668         ( cd $(DESTDIR)$(systemunitdir)/runlevel4.target.wants && \
3669                 rm -f systemd-update-utmp-runlevel.service && \
3670                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
3671         ( cd $(DESTDIR)$(systemunitdir)/runlevel5.target.wants && \
3672                 rm -f systemd-update-utmp-runlevel.service && \
3673                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
3674         ( cd $(DESTDIR)$(systemunitdir)/shutdown.target.wants && \
3675                 rm -f systemd-update-utmp-shutdown.service && \
3676                 $(LN_S) ../systemd-update-utmp-shutdown.service systemd-update-utmp-shutdown.service )
3677         ( cd $(DESTDIR)$(systemunitdir)/local-fs.target.wants && \
3678                 rm -f systemd-remount-fs.service \
3679                         systemd-fsck-root.service \
3680                         tmp.mount && \
3681                 $(LN_S) ../systemd-remount-fs.service systemd-remount-fs.service && \
3682                 $(LN_S) ../systemd-fsck-root.service systemd-fsck-root.service && \
3683                 $(LN_S) ../tmp.mount tmp.mount )
3684         ( cd $(DESTDIR)$(userunitdir) && \
3685                 rm -f shutdown.target sockets.target bluetooth.target printer.target sound.target && \
3686                 $(LN_S) $(systemunitdir)/shutdown.target shutdown.target && \
3687                 $(LN_S) $(systemunitdir)/sockets.target sockets.target && \
3688                 $(LN_S) $(systemunitdir)/bluetooth.target bluetooth.target && \
3689                 $(LN_S) $(systemunitdir)/printer.target printer.target && \
3690                 $(LN_S) $(systemunitdir)/sound.target sound.target )
3691         ( cd $(DESTDIR)$(systemunitdir) && \
3692                 rm -f runlevel0.target runlevel1.target runlevel2.target runlevel3.target runlevel4.target runlevel5.target runlevel6.target && \
3693                 $(LN_S) poweroff.target runlevel0.target && \
3694                 $(LN_S) rescue.target runlevel1.target && \
3695                 $(LN_S) multi-user.target runlevel2.target && \
3696                 $(LN_S) multi-user.target runlevel3.target && \
3697                 $(LN_S) multi-user.target runlevel4.target && \
3698                 $(LN_S) graphical.target runlevel5.target && \
3699                 $(LN_S) reboot.target runlevel6.target )
3700         ( cd $(DESTDIR)$(systemunitdir) && \
3701                 rm -f default.target ctrl-alt-del.target autovt@.service && \
3702                 $(LN_S) graphical.target default.target && \
3703                 $(LN_S) reboot.target ctrl-alt-del.target && \
3704                 $(LN_S) getty@.service autovt@.service )
3705         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
3706                 rm -f getty.target systemd-ask-password-wall.path && \
3707                 $(LN_S) ../getty.target getty.target && \
3708                 $(LN_S) ../systemd-ask-password-wall.path systemd-ask-password-wall.path)
3709         ( cd $(DESTDIR)$(pkgsysconfdir)/system/getty.target.wants && \
3710                 rm -f getty@tty1.service && \
3711                 $(LN_S) $(systemunitdir)/getty@.service getty@tty1.service )
3712         ( cd $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants && \
3713                 rm -f remote-fs.target && \
3714                 $(LN_S) $(systemunitdir)/remote-fs.target remote-fs.target )
3715         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
3716                 rm -f dev-hugepages.mount \
3717                         dev-mqueue.mount \
3718                         sys-kernel-config.mount \
3719                         sys-kernel-debug.mount \
3720                         sys-fs-fuse-connections.mount \
3721                         systemd-modules-load.service \
3722                         systemd-tmpfiles-setup.service \
3723                         systemd-sysctl.service \
3724                         systemd-ask-password-console.path && \
3725                 $(LN_S) ../dev-hugepages.mount dev-hugepages.mount && \
3726                 $(LN_S) ../dev-mqueue.mount dev-mqueue.mount && \
3727                 $(LN_S) ../sys-kernel-config.mount sys-kernel-config.mount && \
3728                 $(LN_S) ../sys-kernel-debug.mount sys-kernel-debug.mount && \
3729                 $(LN_S) ../sys-fs-fuse-connections.mount sys-fs-fuse-connections.mount && \
3730                 $(LN_S) ../systemd-modules-load.service systemd-modules-load.service && \
3731                 $(LN_S) ../systemd-tmpfiles-setup.service systemd-tmpfiles-setup.service && \
3732                 $(LN_S) ../systemd-sysctl.service systemd-sysctl.service && \
3733                 $(LN_S) ../systemd-ask-password-console.path systemd-ask-password-console.path )
3734         ( cd $(DESTDIR)$(systemunitdir)/basic.target.wants && \
3735                 rm -f systemd-tmpfiles-clean.timer && \
3736                 $(LN_S) ../systemd-tmpfiles-clean.timer systemd-tmpfiles-clean.timer )
3737         ( cd $(DESTDIR)$(dbussessionservicedir) && \
3738                 rm -f org.freedesktop.systemd1.service && \
3739                 $(LN_S) ../system-services/org.freedesktop.systemd1.service org.freedesktop.systemd1.service )
3740
3741 if TARGET_FEDORA
3742         ( cd $(DESTDIR)$(systemunitdir) && \
3743                 rm -f display-manager.service single.service && \
3744                 $(LN_S) rescue.service single.service )
3745 endif
3746
3747 if TARGET_MANDRIVA
3748         ( cd $(DESTDIR)$(systemunitdir) && \
3749                 rm -f display-manager.service dm.service single.service && \
3750                 $(LN_S) rescue.service single.service )
3751 endif
3752
3753 if TARGET_DEBIAN_OR_UBUNTU
3754         ( cd $(DESTDIR)$(systemunitdir) && \
3755                 rm -f runlevel5.target && \
3756                 $(LN_S) multi-user.target runlevel5.target )
3757 endif
3758
3759 if TARGET_SUSE
3760         ( cd $(DESTDIR)$(systemunitdir) && \
3761                 rm -f local.service && \
3762                 $(LN_S) rc-local.service local.service )
3763 endif
3764
3765 if TARGET_MAGEIA
3766         ( cd $(DESTDIR)$(systemunitdir) && \
3767                 rm -f display-manager.service )
3768 endif
3769
3770 install-exec-hook: $(INSTALL_EXEC_HOOKS)
3771
3772 uninstall-hook: $(UNINSTALL_EXEC_HOOKS)
3773