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