chiark / gitweb /
systemadm: split the type+status combo box into type combo & status checkbox
[elogind.git] / Makefile.am
1 #  This file is part of systemd.
2 #
3 #  Copyright 2010 Lennart Poettering
4 #
5 #  systemd is free software; you can redistribute it and/or modify it
6 #  under the terms of the GNU General Public License as published by
7 #  the Free Software Foundation; either version 2 of the License, or
8 #  (at your option) any later version.
9 #
10 #  systemd is distributed in the hope that it will be useful, but
11 #  WITHOUT ANY WARRANTY; without even the implied warranty of
12 #  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 #  General Public License for more details.
14 #
15 #  You should have received a copy of the GNU General Public License
16 #  along with systemd; If not, see <http://www.gnu.org/licenses/>.
17
18 ACLOCAL_AMFLAGS = -I m4
19
20 SUBDIRS = po
21
22 LIBSYSTEMD_LOGIN_CURRENT=0
23 LIBSYSTEMD_LOGIN_REVISION=4
24 LIBSYSTEMD_LOGIN_AGE=0
25
26 LIBSYSTEMD_DAEMON_CURRENT=0
27 LIBSYSTEMD_DAEMON_REVISION=0
28 LIBSYSTEMD_DAEMON_AGE=0
29
30 # Dirs of external packages
31 dbuspolicydir=@dbuspolicydir@
32 dbussessionservicedir=@dbussessionservicedir@
33 dbussystemservicedir=@dbussystemservicedir@
34 dbusinterfacedir=@dbusinterfacedir@
35 udevrulesdir=@udevrulesdir@
36 pamlibdir=@pamlibdir@
37 pkgconfigdatadir=$(datadir)/pkgconfig
38 pkgconfiglibdir=$(libdir)/pkgconfig
39 polkitpolicydir=$(datadir)/polkit-1/actions
40 bashcompletiondir=$(sysconfdir)/bash_completion.d
41
42 # Our own, non-special dirs
43 pkgsysconfdir=$(sysconfdir)/systemd
44 userunitdir=$(prefix)/lib/systemd/user
45 tmpfilesdir=$(prefix)/lib/tmpfiles.d
46 usergeneratordir=$(pkglibexecdir)/user-generators
47 pkgincludedir=$(includedir)/systemd
48
49 # And these are the special ones for /
50 rootdir=@rootdir@
51 rootbindir=$(rootdir)/bin
52 rootlibexecdir=$(rootdir)/lib/systemd
53 systemgeneratordir=$(rootlibexecdir)/system-generators
54 systemshutdowndir=$(rootlibexecdir)/system-shutdown
55 systemunitdir=$(rootdir)/lib/systemd/system
56
57 AM_CPPFLAGS = \
58         -include $(top_builddir)/config.h \
59         -DSYSTEM_CONFIG_FILE=\"$(pkgsysconfdir)/system.conf\" \
60         -DSYSTEM_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/system\" \
61         -DSYSTEM_DATA_UNIT_PATH=\"$(systemunitdir)\" \
62         -DSYSTEM_SYSVINIT_PATH=\"$(SYSTEM_SYSVINIT_PATH)\" \
63         -DSYSTEM_SYSVRCND_PATH=\"$(SYSTEM_SYSVRCND_PATH)\" \
64         -DUSER_CONFIG_FILE=\"$(pkgsysconfdir)/user.conf\" \
65         -DUSER_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/user\" \
66         -DUSER_DATA_UNIT_PATH=\"$(userunitdir)\" \
67         -DSYSTEMD_CGROUP_AGENT_PATH=\"$(rootlibexecdir)/systemd-cgroups-agent\" \
68         -DSYSTEMD_BINARY_PATH=\"$(rootbindir)/systemd\" \
69         -DSYSTEMD_SHUTDOWN_BINARY_PATH=\"$(rootlibexecdir)/systemd-shutdown\" \
70         -DSYSTEMCTL_BINARY_PATH=\"$(rootbindir)/systemctl\" \
71         -DSYSTEMD_TTY_ASK_PASSWORD_AGENT_BINARY_PATH=\"$(rootbindir)/systemd-tty-ask-password-agent\" \
72         -DSYSTEMD_STDIO_BRIDGE_BINARY_PATH=\"$(bindir)/systemd-stdio-bridge\" \
73         -DRUNTIME_DIR=\"/run\" \
74         -DRANDOM_SEED=\"$(localstatedir)/lib/random-seed\" \
75         -DSYSTEMD_CRYPTSETUP_PATH=\"$(rootlibexecdir)/systemd-cryptsetup\" \
76         -DSYSTEM_GENERATOR_PATH=\"$(systemgeneratordir)\" \
77         -DUSER_GENERATOR_PATH=\"$(usergeneratordir)\" \
78         -DSYSTEM_SHUTDOWN_PATH=\"$(systemshutdowndir)\" \
79         -I $(top_srcdir)/src
80
81 if TARGET_GENTOO
82 AM_CPPFLAGS += \
83         -DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
84         -DKBD_SETFONT=\"/usr/bin/setfont\" \
85         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
86 else
87 if TARGET_ARCH
88 AM_CPPFLAGS += \
89         -DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
90         -DKBD_SETFONT=\"/usr/bin/setfont\" \
91         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
92 else
93 if TARGET_FRUGALWARE
94 AM_CPPFLAGS += \
95         -DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
96         -DKBD_SETFONT=\"/usr/bin/setfont\" \
97         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
98 else
99 if TARGET_MANDRIVA
100 AM_CPPFLAGS += \
101         -DKBD_LOADKEYS=\"/bin/loadkeys\" \
102         -DKBD_SETFONT=\"/bin/setfont\" \
103         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
104 else
105 if TARGET_MEEGO
106 AM_CPPFLAGS += \
107         -DKBD_LOADKEYS=\"/bin/loadkeys\" \
108         -DKBD_SETFONT=\"/bin/setfont\" \
109         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
110 else
111 if TARGET_ANGSTROM
112 AM_CPPFLAGS += \
113         -DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
114         -DKBD_SETFONT=\"/usr/bin/setfont\" \
115         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
116 else
117 AM_CPPFLAGS += \
118         -DKBD_LOADKEYS=\"/bin/loadkeys\" \
119         -DKBD_SETFONT=\"/bin/setfont\" \
120         -DDEFAULT_FONT=\"latarcyrheb-sun16\"
121 endif
122 endif
123 endif
124 endif
125 endif
126 endif
127
128 rootbin_PROGRAMS = \
129         systemd \
130         systemctl \
131         systemd-loginctl \
132         systemd-notify \
133         systemd-ask-password \
134         systemd-tty-ask-password-agent \
135         systemd-tmpfiles \
136         systemd-machine-id-setup
137
138 bin_PROGRAMS = \
139         systemd-cgls \
140         systemd-stdio-bridge \
141         systemd-nspawn
142
143 dist_bin_SCRIPTS = \
144         src/systemd-analyze
145
146 if HAVE_GTK
147 bin_PROGRAMS += \
148         systemadm \
149         systemd-gnome-ask-password-agent
150 endif
151
152 rootlibexec_PROGRAMS = \
153         systemd-stdout-syslog-bridge \
154         systemd-cgroups-agent \
155         systemd-initctl \
156         systemd-update-utmp \
157         systemd-random-seed \
158         systemd-shutdownd \
159         systemd-shutdown \
160         systemd-modules-load \
161         systemd-remount-api-vfs \
162         systemd-kmsg-syslogd \
163         systemd-vconsole-setup \
164         systemd-reply-password \
165         systemd-readahead-collect \
166         systemd-readahead-replay \
167         systemd-user-sessions \
168         systemd-fsck \
169         systemd-quotacheck \
170         systemd-timestamp \
171         systemd-ac-power \
172         systemd-detect-virt \
173         systemd-sysctl \
174         systemd-logind \
175         systemd-uaccess
176
177 if ENABLE_BINFMT
178 rootlibexec_PROGRAMS += \
179         systemd-binfmt
180 endif
181
182 if ENABLE_HOSTNAMED
183 rootlibexec_PROGRAMS += \
184         systemd-hostnamed
185 endif
186
187 if ENABLE_TIMEDATED
188 rootlibexec_PROGRAMS += \
189         systemd-timedated
190 endif
191
192 if ENABLE_LOCALED
193 rootlibexec_PROGRAMS += \
194         systemd-localed
195 endif
196
197 systemgenerator_PROGRAMS = \
198         systemd-getty-generator
199
200 if HAVE_LIBCRYPTSETUP
201 rootlibexec_PROGRAMS += \
202         systemd-cryptsetup
203
204 systemgenerator_PROGRAMS += \
205         systemd-cryptsetup-generator
206 endif
207
208 lib_LTLIBRARIES = \
209         libsystemd-daemon.la \
210         libsystemd-login.la
211
212 pkginclude_HEADERS = \
213         src/sd-daemon.h \
214         src/sd-login.h
215
216 noinst_PROGRAMS = \
217         test-engine \
218         test-job-type \
219         test-ns \
220         test-loopback \
221         test-hostname \
222         test-daemon \
223         test-cgroup \
224         test-env-replace \
225         test-strv \
226         test-login \
227         test-install
228
229 if HAVE_PAM
230 pamlib_LTLIBRARIES = \
231         pam_systemd.la
232 endif
233
234 dist_pkgsysconf_DATA = \
235         src/system.conf \
236         src/user.conf \
237         src/systemd-logind.conf
238
239 dist_dbuspolicy_DATA = \
240         src/org.freedesktop.systemd1.conf \
241         src/org.freedesktop.login1.conf
242
243 if ENABLE_HOSTNAMED
244 dist_dbuspolicy_DATA += \
245         src/org.freedesktop.hostname1.conf
246 endif
247
248 if ENABLE_TIMEDATED
249 dist_dbuspolicy_DATA += \
250         src/org.freedesktop.timedate1.conf
251 endif
252
253 if ENABLE_LOCALED
254 dist_dbuspolicy_DATA += \
255         src/org.freedesktop.locale1.conf
256 endif
257
258 dist_dbussystemservice_DATA = \
259         src/org.freedesktop.systemd1.service \
260         src/org.freedesktop.login1.service
261
262 if ENABLE_HOSTNAMED
263 dist_dbussystemservice_DATA += \
264         src/org.freedesktop.hostname1.service
265 endif
266
267 if ENABLE_TIMEDATED
268 dist_dbussystemservice_DATA += \
269         src/org.freedesktop.timedate1.service
270 endif
271
272 if ENABLE_LOCALED
273 dist_dbussystemservice_DATA += \
274         src/org.freedesktop.locale1.service
275 endif
276
277 dist_udevrules_DATA = \
278         src/70-uaccess.rules \
279         src/71-seat.rules
280
281 nodist_udevrules_DATA = \
282         src/73-seat-late.rules \
283         src/99-systemd.rules
284
285 dbusinterface_DATA = \
286         org.freedesktop.systemd1.Manager.xml \
287         org.freedesktop.systemd1.Job.xml \
288         org.freedesktop.systemd1.Unit.xml \
289         org.freedesktop.systemd1.Service.xml \
290         org.freedesktop.systemd1.Socket.xml \
291         org.freedesktop.systemd1.Timer.xml \
292         org.freedesktop.systemd1.Target.xml \
293         org.freedesktop.systemd1.Device.xml \
294         org.freedesktop.systemd1.Mount.xml \
295         org.freedesktop.systemd1.Automount.xml \
296         org.freedesktop.systemd1.Snapshot.xml \
297         org.freedesktop.systemd1.Swap.xml \
298         org.freedesktop.systemd1.Path.xml
299
300 if ENABLE_HOSTNAMED
301 dbusinterface_DATA += \
302         org.freedesktop.hostname1.xml
303 endif
304
305 if ENABLE_TIMEDATED
306 dbusinterface_DATA += \
307         org.freedesktop.timedate1.xml
308 endif
309
310 if ENABLE_LOCALED
311 dbusinterface_DATA += \
312         org.freedesktop.locale1.xml
313 endif
314
315 dist_bashcompletion_DATA = \
316         src/systemctl-bash-completion.sh
317
318 dist_tmpfiles_DATA = \
319         tmpfiles.d/systemd.conf \
320         tmpfiles.d/tmp.conf \
321         tmpfiles.d/x11.conf
322
323 if HAVE_SYSV_COMPAT
324 dist_tmpfiles_DATA += \
325         tmpfiles.d/legacy.conf
326 endif
327
328 dist_systemunit_DATA = \
329         units/graphical.target \
330         units/multi-user.target \
331         units/emergency.service \
332         units/emergency.target \
333         units/sysinit.target \
334         units/basic.target \
335         units/getty.target \
336         units/halt.target \
337         units/kexec.target \
338         units/local-fs.target \
339         units/remote-fs.target \
340         units/cryptsetup.target \
341         units/network.target \
342         units/nss-lookup.target \
343         units/mail-transfer-agent.target \
344         units/http-daemon.target \
345         units/poweroff.target \
346         units/reboot.target \
347         units/rescue.target \
348         units/rpcbind.target \
349         units/time-sync.target \
350         units/shutdown.target \
351         units/final.target \
352         units/umount.target \
353         units/sigpwr.target \
354         units/sockets.target \
355         units/swap.target \
356         units/systemd-initctl.socket \
357         units/systemd-stdout-syslog-bridge.socket \
358         units/systemd-shutdownd.socket \
359         units/syslog.socket \
360         units/dev-hugepages.automount \
361         units/dev-hugepages.mount \
362         units/dev-mqueue.automount \
363         units/dev-mqueue.mount \
364         units/sys-kernel-debug.automount \
365         units/sys-kernel-debug.mount \
366         units/sys-kernel-security.automount \
367         units/sys-kernel-security.mount \
368         units/var-run.mount \
369         units/media.mount \
370         units/remount-rootfs.service \
371         units/printer.target \
372         units/sound.target \
373         units/bluetooth.target \
374         units/smartcard.target \
375         units/systemd-readahead-done.timer \
376         units/systemd-tmpfiles-clean.timer \
377         units/quotaon.service \
378         units/systemd-ask-password-wall.path \
379         units/systemd-ask-password-console.path \
380         units/syslog.target
381
382 if HAVE_SYSV_COMPAT
383 dist_systemunit_DATA += \
384         units/var-lock.mount
385 endif
386
387 if ENABLE_BINFMT
388 dist_systemunit_DATA += \
389         units/proc-sys-fs-binfmt_misc.automount \
390         units/proc-sys-fs-binfmt_misc.mount
391 endif
392
393 nodist_systemunit_DATA = \
394         units/getty@.service \
395         units/serial-getty@.service \
396         units/console-shell.service \
397         units/systemd-initctl.service \
398         units/systemd-stdout-syslog-bridge.service \
399         units/systemd-shutdownd.service \
400         units/systemd-logind.service \
401         units/systemd-kmsg-syslogd.service \
402         units/systemd-modules-load.service \
403         units/systemd-vconsole-setup.service \
404         units/systemd-remount-api-vfs.service \
405         units/systemd-update-utmp-runlevel.service \
406         units/systemd-update-utmp-shutdown.service \
407         units/systemd-random-seed-save.service \
408         units/systemd-random-seed-load.service \
409         units/systemd-readahead-collect.service \
410         units/systemd-readahead-replay.service \
411         units/systemd-readahead-done.service \
412         units/systemd-tmpfiles-setup.service \
413         units/systemd-tmpfiles-clean.service \
414         units/systemd-user-sessions.service \
415         units/systemd-ask-password-wall.service \
416         units/systemd-ask-password-console.service \
417         units/systemd-sysctl.service \
418         units/halt.service \
419         units/poweroff.service \
420         units/reboot.service \
421         units/kexec.service \
422         units/fsck@.service \
423         units/fsck-root.service \
424         units/quotacheck.service \
425         units/rescue.service \
426         units/user@.service
427
428 if ENABLE_BINFMT
429 nodist_systemunit_DATA += \
430         units/systemd-binfmt.service
431 endif
432
433 if ENABLE_HOSTNAMED
434 nodist_systemunit_DATA += \
435         units/systemd-hostnamed.service
436 endif
437
438 if ENABLE_TIMEDATED
439 nodist_systemunit_DATA += \
440         units/systemd-timedated.service
441 endif
442
443 if ENABLE_LOCALED
444 nodist_systemunit_DATA += \
445         units/systemd-localed.service
446 endif
447
448 dist_userunit_DATA = \
449         units/user/default.target \
450         units/user/exit.target
451
452 nodist_userunit_DATA = \
453         units/user/exit.service
454
455 EXTRA_DIST = \
456         units/getty@.service.m4 \
457         units/serial-getty@.service.m4 \
458         units/console-shell.service.m4 \
459         units/rescue.service.m4 \
460         units/systemd-initctl.service.in \
461         units/systemd-stdout-syslog-bridge.service.in \
462         units/systemd-shutdownd.service.in \
463         units/systemd-logind.service.in \
464         units/systemd-kmsg-syslogd.service.in \
465         units/systemd-modules-load.service.in \
466         units/systemd-vconsole-setup.service.in \
467         units/systemd-remount-api-vfs.service.in \
468         units/systemd-update-utmp-runlevel.service.in \
469         units/systemd-update-utmp-shutdown.service.in \
470         units/systemd-random-seed-save.service.in \
471         units/systemd-random-seed-load.service.in \
472         units/systemd-readahead-collect.service.in \
473         units/systemd-readahead-replay.service.in \
474         units/systemd-readahead-done.service.in \
475         units/systemd-tmpfiles-setup.service.in \
476         units/systemd-tmpfiles-clean.service.in \
477         units/systemd-user-sessions.service.in \
478         units/systemd-ask-password-wall.service.in \
479         units/systemd-ask-password-console.service.in \
480         units/systemd-sysctl.service.in \
481         units/halt.service.in \
482         units/poweroff.service.in \
483         units/reboot.service.in \
484         units/kexec.service.in \
485         units/user/exit.service.in \
486         units/fsck@.service.in \
487         units/fsck-root.service.in \
488         units/quotacheck.service.in \
489         units/user@.service.in \
490         systemd.pc.in \
491         libsystemd-daemon.pc.in \
492         libsystemd-login.pc.in \
493         src/libsystemd-daemon.sym \
494         src/libsystemd-login.sym \
495         introspect.awk \
496         src/73-seat-late.rules.in \
497         src/99-systemd.rules.in
498
499 if ENABLE_BINFMT
500 EXTRA_DIST += \
501         units/systemd-binfmt.service.in
502 endif
503
504 if ENABLE_HOSTNAMED
505 EXTRA_DIST += \
506         units/systemd-hostnamed.service.in
507 endif
508
509 if ENABLE_TIMEDATED
510 EXTRA_DIST += \
511         units/systemd-timedated.service.in
512 endif
513
514 if ENABLE_LOCALED
515 EXTRA_DIST += \
516         units/systemd-localed.service.in
517 endif
518
519 if TARGET_FEDORA
520 dist_systemunit_DATA += \
521         units/fedora/prefdm.service \
522         units/fedora/rc-local.service \
523         units/fedora/halt-local.service
524 endif
525
526 if TARGET_MANDRIVA
527 dist_systemunit_DATA += \
528         units/mandriva/prefdm.service \
529         units/fedora/rc-local.service \
530         units/fedora/halt-local.service
531 endif
532
533 if TARGET_FRUGALWARE
534 dist_systemunit_DATA += \
535         units/frugalware/display-manager.service
536 endif
537
538 if TARGET_SUSE
539 dist_systemunit_DATA += \
540         units/suse/rc-local.service \
541         units/suse/halt-local.service
542 endif
543
544 if HAVE_PLYMOUTH
545 dist_systemunit_DATA += \
546         units/plymouth-start.service \
547         units/plymouth-read-write.service \
548         units/plymouth-quit.service \
549         units/plymouth-quit-wait.service \
550         units/plymouth-reboot.service \
551         units/plymouth-kexec.service \
552         units/plymouth-poweroff.service \
553         units/plymouth-halt.service \
554         units/systemd-ask-password-plymouth.path
555
556 nodist_systemunit_DATA += \
557         units/systemd-ask-password-plymouth.service
558
559 EXTRA_DIST += \
560         units/systemd-ask-password-plymouth.service.in
561 endif
562
563 dist_doc_DATA = \
564         README \
565         LICENSE \
566         DISTRO_PORTING \
567         src/sd-daemon.h \
568         src/sd-daemon.c \
569         src/sd-readahead.h \
570         src/sd-readahead.c
571
572 pkgconfigdata_DATA = \
573         systemd.pc
574
575 pkgconfiglib_DATA = \
576         libsystemd-daemon.pc \
577         libsystemd-login.pc
578
579 # Passed through intltool only
580 polkitpolicy_in_files = \
581         src/org.freedesktop.login1.policy.in
582
583 if ENABLE_HOSTNAMED
584 polkitpolicy_in_files += \
585         src/org.freedesktop.hostname1.policy.in
586 endif
587
588 if ENABLE_TIMEDATED
589 polkitpolicy_in_files += \
590         src/org.freedesktop.timedate1.policy.in
591 endif
592
593 if ENABLE_LOCALED
594 polkitpolicy_in_files += \
595         src/org.freedesktop.locale1.policy.in
596 endif
597
598 # First passed through sed, followed by intltool
599 polkitpolicy_in_in_files = \
600         src/org.freedesktop.systemd1.policy.in.in
601
602 nodist_polkitpolicy_DATA = \
603         $(polkitpolicy_in_files:.policy.in=.policy) \
604         $(polkitpolicy_in_in_files:.policy.in.in=.policy)
605
606 EXTRA_DIST += \
607         $(polkitpolicy_in_files) \
608         $(polkitpolicy_in_in_files)
609
610 @INTLTOOL_POLICY_RULE@
611
612 noinst_LTLIBRARIES = \
613         libsystemd-basic.la \
614         libsystemd-core.la
615
616 libsystemd_basic_la_SOURCES = \
617         src/util.c \
618         src/label.c \
619         src/hashmap.c \
620         src/set.c \
621         src/strv.c \
622         src/conf-parser.c \
623         src/socket-util.c \
624         src/log.c \
625         src/ratelimit.c \
626         src/exit-status.c
627
628 libsystemd_basic_la_CFLAGS = \
629         $(AM_CFLAGS) \
630         $(SELINUX_CFLAGS)
631
632 libsystemd_basic_la_LIBADD = \
633         $(SELINUX_LIBS) \
634         $(CAP_LIBS)
635
636 libsystemd_core_la_SOURCES = \
637         src/unit.c \
638         src/job.c \
639         src/manager.c \
640         src/path-lookup.c \
641         src/load-fragment.c \
642         src/service.c \
643         src/automount.c \
644         src/mount.c \
645         src/swap.c \
646         src/device.c \
647         src/target.c \
648         src/snapshot.c \
649         src/socket.c \
650         src/timer.c \
651         src/path.c \
652         src/load-dropin.c \
653         src/execute.c \
654         src/utmp-wtmp.c \
655         src/dbus.c \
656         src/dbus-manager.c \
657         src/dbus-unit.c \
658         src/dbus-job.c \
659         src/dbus-service.c \
660         src/dbus-socket.c \
661         src/dbus-timer.c \
662         src/dbus-target.c \
663         src/dbus-mount.c \
664         src/dbus-automount.c \
665         src/dbus-swap.c \
666         src/dbus-snapshot.c \
667         src/dbus-device.c \
668         src/dbus-execute.c \
669         src/dbus-path.c \
670         src/cgroup.c \
671         src/mount-setup.c \
672         src/hostname-setup.c \
673         src/selinux-setup.c \
674         src/loopback-setup.c \
675         src/kmod-setup.c \
676         src/locale-setup.c \
677         src/machine-id-setup.c \
678         src/specifier.c \
679         src/unit-name.c \
680         src/fdset.c \
681         src/namespace.c \
682         src/tcpwrap.c \
683         src/cgroup-util.c \
684         src/condition.c \
685         src/dbus-common.c \
686         src/sd-daemon.c \
687         src/install.c \
688         src/cgroup-attr.c
689
690 nodist_libsystemd_core_la_SOURCES = \
691         src/load-fragment-gperf.c \
692         src/load-fragment-gperf-nulstr.c
693
694 EXTRA_DIST += \
695         src/load-fragment-gperf.gperf.m4
696
697 libsystemd_core_la_CFLAGS = \
698         $(AM_CFLAGS) \
699         $(DBUS_CFLAGS) \
700         $(UDEV_CFLAGS) \
701         $(LIBWRAP_CFLAGS) \
702         $(PAM_CFLAGS) \
703         $(AUDIT_CFLAGS)
704
705 libsystemd_core_la_LIBADD = \
706         libsystemd-basic.la \
707         $(DBUS_LIBS) \
708         $(UDEV_LIBS) \
709         $(LIBWRAP_LIBS) \
710         $(PAM_LIBS) \
711         $(AUDIT_LIBS) \
712         $(CAP_LIBS)
713
714 # This is needed because automake is buggy in how it generates the
715 # rules for C programs, but not Vala programs.  We therefore can't
716 # list the .h files as dependencies if we want make dist to work.
717
718 EXTRA_DIST += \
719         ${libsystemd_basic_la_SOURCES:.c=.h} \
720         ${libsystemd_core_la_SOURCES:.c=.h} \
721         ${libsystemd_daemon_la_SOURCES:.c=.h} \
722         src/macro.h \
723         src/def.h \
724         src/ioprio.h \
725         src/missing.h \
726         src/list.h \
727         src/securebits.h \
728         src/linux/auto_dev-ioctl.h \
729         src/linux/fanotify.h \
730         src/initreq.h \
731         src/sd-readahead.h \
732         src/special.h \
733         src/dbus-common.h \
734         src/bus-errors.h \
735         src/cgroup-show.h \
736         src/build.h \
737         src/shutdownd.h \
738         src/umount.h \
739         src/readahead-common.h \
740         src/ask-password-api.h \
741         src/pager.h \
742         src/sysfs-show.h \
743         src/polkit.h \
744         src/logind.h \
745         src/logind-device.h \
746         src/logind-seat.h \
747         src/logind-session.h \
748         src/logind-user.h \
749         src/logind-acl.h \
750         src/dbus-loop.h \
751         src/spawn-agent.h
752
753 MANPAGES = \
754         man/systemd.1 \
755         man/systemctl.1 \
756         man/systemadm.1 \
757         man/systemd-cgls.1 \
758         man/systemd-nspawn.1 \
759         man/systemd-tmpfiles.8 \
760         man/systemd-notify.1 \
761         man/sd_notify.3 \
762         man/sd_readahead.3 \
763         man/sd_booted.3 \
764         man/sd_listen_fds.3 \
765         man/sd_is_fifo.3 \
766         man/systemd.unit.5 \
767         man/systemd.service.5 \
768         man/systemd.socket.5 \
769         man/systemd.mount.5 \
770         man/systemd.automount.5 \
771         man/systemd.swap.5 \
772         man/systemd.timer.5 \
773         man/systemd.path.5 \
774         man/systemd.target.5 \
775         man/systemd.device.5 \
776         man/systemd.snapshot.5 \
777         man/systemd.exec.5 \
778         man/daemon.7 \
779         man/sd-daemon.7 \
780         man/sd-readahead.7 \
781         man/runlevel.8 \
782         man/telinit.8 \
783         man/halt.8 \
784         man/shutdown.8 \
785         man/pam_systemd.8 \
786         man/systemd.conf.5 \
787         man/systemd-logind.conf.5 \
788         man/tmpfiles.d.5 \
789         man/hostname.5 \
790         man/timezone.5 \
791         man/machine-id.5 \
792         man/vconsole.conf.5 \
793         man/locale.conf.5 \
794         man/os-release.5 \
795         man/machine-info.5 \
796         man/modules-load.d.5 \
797         man/sysctl.d.5 \
798         man/systemd-ask-password.1 \
799         man/systemd-loginctl.1
800
801 if ENABLE_BINFMT
802 MANPAGES += \
803         man/binfmt.d.5
804 endif
805
806 MANPAGES_ALIAS = \
807         man/reboot.8 \
808         man/poweroff.8 \
809         man/sd_is_socket.3 \
810         man/sd_is_socket_unix.3 \
811         man/sd_is_socket_inet.3 \
812         man/sd_notifyf.3 \
813         man/init.1
814
815 man/reboot.8: man/halt.8
816 man/poweroff.8: man/halt.8
817 man/sd_is_socket.3: man/sd_is_fifo.3
818 man/sd_is_socket_unix.3: man/sd_is_fifo.3
819 man/sd_is_socket_inet.3: man/sd_is_fifo.3
820 man/sd_notifyf.3: man/sd_notify.3
821 man/init.1: man/systemd.1
822
823 dist_man_MANS = \
824         $(MANPAGES) \
825         $(MANPAGES_ALIAS)
826
827 nodist_man_MANS = \
828         man/systemd.special.7
829
830 XML_FILES = \
831         ${patsubst %.1,%.xml,${patsubst %.3,%.xml,${patsubst %.5,%.xml,${patsubst %.7,%.xml,${patsubst %.8,%.xml,$(MANPAGES)}}}}}
832
833 XML_IN_FILES = \
834         ${patsubst %.1,%.xml.in,${patsubst %.3,%.xml.in,${patsubst %.5,%.xml.in,${patsubst %.7,%.xml.in,${patsubst %.8,%.xml.in,$(nodist_man_MANS)}}}}}
835
836 dist_noinst_DATA = \
837         ${XML_FILES:.xml=.html}
838
839 nodist_noinst_DATA = \
840         ${XML_IN_FILES:.xml.in=.html}
841
842 EXTRA_DIST += \
843         $(XML_FILES) \
844         $(XML_IN_FILES) \
845         ${nodist_man_MANS:=.in} \
846         ${XML_IN_FILES:.xml.in=.html.in}
847
848 systemd_SOURCES = \
849         src/main.c
850
851 systemd_CFLAGS = \
852         $(AM_CFLAGS) \
853         $(DBUS_CFLAGS) \
854         $(UDEV_CFLAGS)
855
856 systemd_LDADD = \
857         libsystemd-core.la
858
859 test_engine_SOURCES = \
860         src/test-engine.c
861
862 test_engine_CFLAGS = $(systemd_CFLAGS)
863 test_engine_LDADD = $(systemd_LDADD)
864
865 test_job_type_SOURCES = \
866         src/test-job-type.c
867
868 test_job_type_CFLAGS = $(systemd_CFLAGS)
869 test_job_type_LDADD = $(systemd_LDADD)
870
871 test_ns_SOURCES = \
872         src/test-ns.c
873
874 test_ns_CFLAGS = $(systemd_CFLAGS)
875 test_ns_LDADD = $(systemd_LDADD)
876
877 test_loopback_SOURCES = \
878         src/test-loopback.c \
879         src/loopback-setup.c
880
881 test_loopback_LDADD = \
882         libsystemd-basic.la
883
884 test_hostname_SOURCES = \
885         src/test-hostname.c \
886         src/hostname-setup.c
887
888 test_hostname_LDADD = \
889         libsystemd-basic.la
890
891 test_daemon_SOURCES = \
892         src/test-daemon.c
893
894 test_daemon_LDADD = \
895         libsystemd-basic.la \
896         libsystemd-daemon.la
897
898 test_cgroup_SOURCES = \
899         src/test-cgroup.c \
900         src/cgroup-util.c
901
902 test_cgroup_CFLAGS = \
903         $(AM_CFLAGS)
904
905 test_cgroup_LDADD = \
906         libsystemd-basic.la
907
908 test_env_replace_SOURCES = \
909         src/test-env-replace.c
910
911 test_env_replace_CFLAGS = \
912         $(AM_CFLAGS)
913
914 test_env_replace_LDADD = \
915         libsystemd-basic.la
916
917 test_strv_SOURCES = \
918         src/test-strv.c \
919         src/specifier.c
920
921 test_strv_CFLAGS = \
922         $(AM_CFLAGS)
923
924 test_strv_LDADD = \
925         libsystemd-basic.la
926
927 test_login_SOURCES = \
928         src/test-login.c
929
930 test_login_CFLAGS = \
931         $(AM_CFLAGS)
932
933 test_login_LDADD = \
934         libsystemd-basic.la \
935         libsystemd-login.la
936
937 test_install_SOURCES = \
938         src/test-install.c \
939         src/install.c \
940         src/path-lookup.c \
941         src/unit-name.c
942
943 test_install_CFLAGS = \
944         $(AM_CFLAGS) \
945         $(DBUS_CFLAGS)
946
947 test_install_LDADD = \
948         libsystemd-basic.la
949
950 systemd_stdout_syslog_bridge_SOURCES = \
951         src/stdout-syslog-bridge.c \
952         src/tcpwrap.c
953
954 systemd_stdout_syslog_bridge_LDADD = \
955         libsystemd-basic.la \
956         libsystemd-daemon.la \
957         $(LIBWRAP_LIBS)
958
959 systemd_initctl_SOURCES = \
960         src/initctl.c \
961         src/dbus-common.c
962
963 systemd_initctl_CFLAGS = \
964         $(AM_CFLAGS) \
965         $(DBUS_CFLAGS)
966
967 systemd_initctl_LDADD = \
968         libsystemd-basic.la \
969         libsystemd-daemon.la \
970         $(DBUS_LIBS)
971
972 systemd_update_utmp_SOURCES = \
973         src/update-utmp.c \
974         src/dbus-common.c \
975         src/utmp-wtmp.c
976
977 systemd_update_utmp_CFLAGS = \
978         $(AM_CFLAGS) \
979         $(DBUS_CFLAGS) \
980         $(AUDIT_CFLAGS)
981
982 systemd_update_utmp_LDADD = \
983         libsystemd-basic.la \
984         $(DBUS_LIBS) \
985         $(AUDIT_LIBS)
986
987 systemd_random_seed_SOURCES = \
988         src/random-seed.c
989
990 systemd_random_seed_CFLAGS = \
991         $(AM_CFLAGS)
992
993 systemd_random_seed_LDADD = \
994         libsystemd-basic.la
995
996 systemd_shutdownd_SOURCES = \
997         src/utmp-wtmp.c \
998         src/shutdownd.c
999
1000 systemd_shutdownd_CFLAGS = \
1001         $(AM_CFLAGS)
1002
1003 systemd_shutdownd_LDADD = \
1004         libsystemd-basic.la \
1005         libsystemd-daemon.la
1006
1007 systemd_hostnamed_SOURCES = \
1008         src/hostnamed.c \
1009         src/dbus-common.c \
1010         src/polkit.c
1011
1012 systemd_hostnamed_CFLAGS = \
1013         $(AM_CFLAGS) \
1014         $(DBUS_CFLAGS)
1015
1016 systemd_hostnamed_LDADD = \
1017         libsystemd-basic.la \
1018         libsystemd-daemon.la \
1019         $(DBUS_LIBS)
1020
1021 systemd_localed_SOURCES = \
1022         src/localed.c \
1023         src/dbus-common.c \
1024         src/polkit.c
1025
1026 systemd_localed_CFLAGS = \
1027         $(AM_CFLAGS) \
1028         $(DBUS_CFLAGS)
1029
1030 systemd_localed_LDADD = \
1031         libsystemd-basic.la \
1032         libsystemd-daemon.la \
1033         $(DBUS_LIBS)
1034
1035 systemd_timedated_SOURCES = \
1036         src/timedated.c \
1037         src/dbus-common.c \
1038         src/polkit.c
1039
1040 systemd_timedated_CFLAGS = \
1041         $(AM_CFLAGS) \
1042         $(DBUS_CFLAGS)
1043
1044 systemd_timedated_LDADD = \
1045         libsystemd-basic.la \
1046         libsystemd-daemon.la \
1047         $(DBUS_LIBS)
1048
1049 systemd_logind_SOURCES = \
1050         src/logind.c \
1051         src/logind-dbus.c \
1052         src/logind-device.c \
1053         src/logind-seat.c \
1054         src/logind-seat-dbus.c \
1055         src/logind-session.c \
1056         src/logind-session-dbus.c \
1057         src/logind-user.c \
1058         src/logind-user-dbus.c \
1059         src/dbus-common.c \
1060         src/dbus-loop.c \
1061         src/cgroup-util.c \
1062         src/polkit.c
1063
1064 nodist_systemd_logind_SOURCES = \
1065         src/logind-gperf.c
1066
1067 EXTRA_DIST += \
1068         src/logind-gperf.gperf
1069
1070 systemd_logind_CFLAGS = \
1071         $(AM_CFLAGS) \
1072         $(DBUS_CFLAGS) \
1073         $(UDEV_CFLAGS) \
1074         $(ACL_CFLAGS)
1075
1076 systemd_logind_LDADD = \
1077         libsystemd-basic.la \
1078         libsystemd-daemon.la \
1079         $(DBUS_LIBS) \
1080         $(UDEV_LIBS) \
1081         $(ACL_LIBS)
1082
1083 systemd_uaccess_SOURCES = \
1084         src/uaccess.c
1085
1086 if HAVE_ACL
1087 systemd_logind_SOURCES += \
1088         src/logind-acl.c
1089
1090 systemd_uaccess_SOURCES += \
1091         src/logind-acl.c
1092 endif
1093
1094 systemd_uaccess_CFLAGS = \
1095         $(AM_CFLAGS) \
1096         $(UDEV_CFLAGS) \
1097         $(ACL_CFLAGS)
1098
1099 systemd_uaccess_LDADD = \
1100         libsystemd-basic.la \
1101         libsystemd-daemon.la \
1102         libsystemd-login.la \
1103         $(UDEV_LIBS) \
1104         $(ACL_LIBS)
1105
1106 systemd_shutdown_SOURCES = \
1107         src/mount-setup.c \
1108         src/umount.c \
1109         src/shutdown.c
1110
1111 systemd_shutdown_CFLAGS = \
1112         $(AM_CFLAGS) \
1113         $(UDEV_CFLAGS)
1114
1115 systemd_shutdown_LDADD = \
1116         libsystemd-basic.la \
1117         $(UDEV_LIBS)
1118
1119 systemd_modules_load_SOURCES = \
1120         src/modules-load.c
1121
1122 systemd_modules_load_CFLAGS = \
1123         $(AM_CFLAGS)
1124
1125 systemd_modules_load_LDADD = \
1126         libsystemd-basic.la
1127
1128 systemd_tmpfiles_SOURCES = \
1129         src/tmpfiles.c
1130
1131 systemd_tmpfiles_CFLAGS = \
1132         $(AM_CFLAGS)
1133
1134 systemd_tmpfiles_LDADD = \
1135         libsystemd-basic.la
1136
1137 systemd_machine_id_setup_SOURCES = \
1138         src/machine-id-setup.c \
1139         src/machine-id-main.c
1140
1141 systemd_machine_id_setup_CFLAGS = \
1142         $(AM_CFLAGS)
1143
1144 systemd_machine_id_setup_LDADD = \
1145         libsystemd-basic.la
1146
1147 systemd_sysctl_SOURCES = \
1148         src/sysctl.c
1149
1150 systemd_sysctl_CFLAGS = \
1151         $(AM_CFLAGS)
1152
1153 systemd_sysctl_LDADD = \
1154         libsystemd-basic.la
1155
1156 systemd_binfmt_SOURCES = \
1157         src/binfmt.c
1158
1159 systemd_binfmt_CFLAGS = \
1160         $(AM_CFLAGS)
1161
1162 systemd_binfmt_LDADD = \
1163         libsystemd-basic.la
1164
1165 systemd_fsck_SOURCES = \
1166         src/fsck.c \
1167         src/dbus-common.c
1168
1169 systemd_fsck_CFLAGS = \
1170         $(AM_CFLAGS) \
1171         $(UDEV_CFLAGS) \
1172         $(DBUS_CFLAGS)
1173
1174 systemd_fsck_LDADD = \
1175         libsystemd-basic.la \
1176         $(UDEV_LIBS) \
1177         $(DBUS_LIBS)
1178
1179 systemd_quotacheck_SOURCES = \
1180         src/quotacheck.c
1181
1182 systemd_quotacheck_CFLAGS = \
1183         $(AM_CFLAGS)
1184
1185 systemd_quotacheck_LDADD = \
1186         libsystemd-basic.la
1187
1188 systemd_timestamp_SOURCES = \
1189         src/timestamp.c
1190
1191 systemd_timestamp_CFLAGS = \
1192         $(AM_CFLAGS)
1193
1194 systemd_timestamp_LDADD = \
1195         libsystemd-basic.la
1196
1197 systemd_ac_power_SOURCES = \
1198         src/ac-power.c
1199
1200 systemd_ac_power_CFLAGS = \
1201         $(AM_CFLAGS) \
1202         $(UDEV_CFLAGS)
1203
1204 systemd_ac_power_LDADD = \
1205         libsystemd-basic.la \
1206         $(UDEV_LIBS)
1207
1208 systemd_detect_virt_SOURCES = \
1209         src/detect-virt.c
1210
1211 systemd_detect_virt_CFLAGS = \
1212         $(AM_CFLAGS)
1213
1214 systemd_detect_virt_LDADD = \
1215         libsystemd-basic.la
1216
1217 systemd_cryptsetup_SOURCES = \
1218         src/cryptsetup.c \
1219         src/ask-password-api.c
1220
1221 systemd_cryptsetup_CFLAGS = \
1222         $(LIBCRYPTSETUP_CFLAGS) \
1223         $(UDEV_CFLAGS) \
1224         $(AM_CFLAGS)
1225
1226 systemd_cryptsetup_LDADD = \
1227         $(LIBCRYPTSETUP_LIBS) \
1228         $(UDEV_LIBS) \
1229         libsystemd-basic.la
1230
1231 systemd_cryptsetup_generator_SOURCES = \
1232         src/cryptsetup-generator.c \
1233         src/unit-name.c
1234
1235 systemd_cryptsetup_generator_CFLAGS = \
1236         $(AM_CFLAGS)
1237
1238 systemd_cryptsetup_generator_LDADD = \
1239         libsystemd-basic.la
1240
1241 systemd_getty_generator_SOURCES = \
1242         src/getty-generator.c \
1243         src/unit-name.c
1244
1245 systemd_getty_generator_CFLAGS = \
1246         $(AM_CFLAGS)
1247
1248 systemd_getty_generator_LDADD = \
1249         libsystemd-basic.la
1250
1251 systemd_user_sessions_SOURCES = \
1252         src/user-sessions.c \
1253         src/cgroup-util.c
1254
1255 systemd_user_sessions_CFLAGS = \
1256         $(AM_CFLAGS)
1257
1258 systemd_user_sessions_LDADD = \
1259         libsystemd-basic.la
1260
1261 systemd_vconsole_setup_SOURCES = \
1262         src/vconsole-setup.c
1263
1264 systemd_vconsole_setup_CFLAGS = \
1265         $(AM_CFLAGS)
1266
1267 systemd_vconsole_setup_LDADD = \
1268         libsystemd-basic.la
1269
1270 systemd_remount_api_vfs_SOURCES = \
1271         src/remount-api-vfs.c \
1272         src/mount-setup.c \
1273         src/exit-status.c
1274
1275 systemd_remount_api_vfs_CFLAGS = \
1276         $(AM_CFLAGS)
1277
1278 systemd_remount_api_vfs_LDADD = \
1279         libsystemd-basic.la
1280
1281 systemd_cgroups_agent_SOURCES = \
1282         src/cgroups-agent.c \
1283         src/dbus-common.c
1284
1285 systemd_cgroups_agent_CFLAGS = \
1286         $(AM_CFLAGS) \
1287         $(DBUS_CFLAGS)
1288
1289 systemd_cgroups_agent_LDADD = \
1290         libsystemd-basic.la \
1291         $(DBUS_LIBS)
1292
1293 systemd_kmsg_syslogd_SOURCES = \
1294         src/kmsg-syslogd.c \
1295         src/fdset.c
1296
1297 systemd_kmsg_syslogd_CFLAGS = \
1298         $(AM_CFLAGS)
1299
1300 systemd_kmsg_syslogd_LDADD = \
1301         libsystemd-basic.la \
1302         libsystemd-daemon.la
1303
1304 systemctl_SOURCES = \
1305         src/systemctl.c \
1306         src/utmp-wtmp.c \
1307         src/dbus-common.c \
1308         src/path-lookup.c \
1309         src/cgroup-show.c \
1310         src/cgroup-util.c \
1311         src/exit-status.c \
1312         src/unit-name.c \
1313         src/pager.c \
1314         src/install.c \
1315         src/spawn-agent.c
1316
1317 systemctl_CFLAGS = \
1318         $(AM_CFLAGS) \
1319         $(DBUS_CFLAGS)
1320
1321 systemctl_LDADD = \
1322         libsystemd-basic.la \
1323         libsystemd-daemon.la \
1324         $(DBUS_LIBS)
1325
1326 systemd_loginctl_SOURCES = \
1327         src/loginctl.c \
1328         src/dbus-common.c \
1329         src/cgroup-show.c \
1330         src/cgroup-util.c \
1331         src/pager.c \
1332         src/sysfs-show.c
1333
1334 systemd_loginctl_CFLAGS = \
1335         $(AM_CFLAGS) \
1336         $(DBUS_CFLAGS) \
1337         $(UDEV_CFLAGS)
1338
1339 systemd_loginctl_LDADD = \
1340         libsystemd-basic.la \
1341         $(DBUS_LIBS) \
1342         $(UDEV_LIBS)
1343
1344 systemd_notify_SOURCES = \
1345         src/notify.c \
1346         src/sd-readahead.c
1347
1348 systemd_notify_LDADD = \
1349         libsystemd-basic.la \
1350         libsystemd-daemon.la
1351
1352 systemd_ask_password_SOURCES = \
1353         src/ask-password.c \
1354         src/ask-password-api.c
1355
1356 systemd_ask_password_LDADD = \
1357         libsystemd-basic.la
1358
1359 systemd_reply_password_SOURCES = \
1360         src/reply-password.c
1361
1362 systemd_reply_password_LDADD = \
1363         libsystemd-basic.la
1364
1365 systemd_readahead_collect_SOURCES = \
1366         src/readahead-collect.c \
1367         src/readahead-common.c
1368
1369 systemd_readahead_collect_CFLAGS = \
1370         $(UDEV_CFLAGS)
1371
1372 systemd_readahead_collect_LDADD = \
1373         libsystemd-basic.la \
1374         libsystemd-daemon.la \
1375         $(UDEV_LIBS)
1376
1377 systemd_readahead_replay_SOURCES = \
1378         src/readahead-replay.c \
1379         src/readahead-common.c
1380
1381 systemd_readahead_replay_CFLAGS = \
1382         $(UDEV_CFLAGS)
1383
1384 systemd_readahead_replay_LDADD = \
1385         libsystemd-basic.la \
1386         libsystemd-daemon.la \
1387         $(UDEV_LIBS)
1388
1389 systemd_cgls_SOURCES = \
1390         src/cgls.c \
1391         src/cgroup-show.c \
1392         src/cgroup-util.c \
1393         src/pager.c
1394
1395 systemd_cgls_CFLAGS = \
1396         $(AM_CFLAGS)
1397
1398 systemd_cgls_LDADD = \
1399         libsystemd-basic.la
1400
1401 systemd_nspawn_SOURCES = \
1402         src/nspawn.c \
1403         src/cgroup-util.c \
1404         src/loopback-setup.c
1405
1406 systemd_nspawn_CFLAGS = \
1407         $(AM_CFLAGS)
1408
1409 systemd_nspawn_LDADD = \
1410         libsystemd-basic.la \
1411         libsystemd-daemon.la
1412
1413 systemd_stdio_bridge_SOURCES = \
1414         src/bridge.c
1415
1416 systemd_stdio_bridge_LDADD = \
1417         libsystemd-basic.la
1418
1419 systemadm_SOURCES = \
1420         src/systemadm.vala \
1421         src/systemd-interfaces.vala
1422
1423 systemadm_CFLAGS = \
1424         $(AM_CFLAGS) \
1425         $(GTK_CFLAGS) \
1426         -Wno-unused-variable \
1427         -Wno-unused-function \
1428         -Wno-shadow \
1429         -Wno-format-nonliteral
1430
1431 systemadm_VALAFLAGS = \
1432         --pkg=posix \
1433         --pkg=gtk+-2.0 \
1434         -g
1435
1436 systemadm_LDADD = \
1437         $(GTK_LIBS)
1438
1439 systemd_gnome_ask_password_agent_SOURCES = \
1440         src/gnome-ask-password-agent.vala
1441
1442 systemd_gnome_ask_password_agent_CFLAGS = \
1443         $(AM_CFLAGS) \
1444         $(LIBNOTIFY_CFLAGS) \
1445         $(GTK_CFLAGS) \
1446         -Wno-unused-variable \
1447         -Wno-unused-function \
1448         -Wno-shadow \
1449         -Wno-format-nonliteral
1450
1451 systemd_gnome_ask_password_agent_VALAFLAGS = \
1452         --pkg=posix \
1453         --pkg=gtk+-2.0 \
1454         --pkg=linux \
1455         --pkg=gio-unix-2.0 \
1456         --pkg=libnotify
1457 if LIBNOTIFY07
1458 systemd_gnome_ask_password_agent_VALAFLAGS += \
1459         -D LIBNOTIFY07
1460 endif
1461 systemd_gnome_ask_password_agent_VALAFLAGS += \
1462         -g
1463
1464 systemd_gnome_ask_password_agent_LDADD = \
1465         $(LIBNOTIFY_LIBS) \
1466         $(GTK_LIBS)
1467
1468 systemd_tty_ask_password_agent_SOURCES = \
1469         src/tty-ask-password-agent.c \
1470         src/ask-password-api.c \
1471         src/utmp-wtmp.c
1472
1473 systemd_tty_ask_password_agent_LDADD = \
1474         libsystemd-basic.la
1475
1476 pam_systemd_la_SOURCES = \
1477         src/pam-module.c \
1478         src/dbus-common.c
1479
1480 pam_systemd_la_CFLAGS = \
1481         $(AM_CFLAGS) \
1482         $(PAM_CFLAGS) \
1483         $(DBUS_CFLAGS) \
1484         -fvisibility=hidden
1485
1486 pam_systemd_la_LDFLAGS = \
1487         -module \
1488         -export-dynamic \
1489         -avoid-version \
1490         -shared \
1491         -export-symbols-regex '^pam_sm_.*'
1492
1493 pam_systemd_la_LIBADD = \
1494         libsystemd-basic.la \
1495         libsystemd-daemon.la \
1496         $(PAM_LIBS) \
1497         $(DBUS_LIBS)
1498
1499 libsystemd_daemon_la_SOURCES = \
1500         src/sd-daemon.c
1501
1502 libsystemd_daemon_la_CFLAGS = \
1503         $(AM_CFLAGS) \
1504         -fvisibility=hidden \
1505         -DSD_EXPORT_SYMBOLS
1506
1507 libsystemd_daemon_la_LDFLAGS = \
1508         -shared \
1509         -version-info $(LIBSYSTEMD_DAEMON_CURRENT):$(LIBSYSTEMD_DAEMON_REVISION):$(LIBSYSTEMD_DAEMON_AGE) \
1510         -Wl,--version-script=$(top_srcdir)/src/libsystemd-daemon.sym
1511
1512 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
1513 libsystemd-daemon-install-hook:
1514         if test "$(libdir)" != "$(rootlibdir)"; then \
1515                 mkdir -p $(DESTDIR)$(rootlibdir) && \
1516                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-daemon.so) && \
1517                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
1518                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-daemon.so && \
1519                 mv $(DESTDIR)$(libdir)/libsystemd-daemon.so.* $(DESTDIR)$(rootlibdir); \
1520         fi
1521
1522 libsystemd-daemon-uninstall-hook:
1523         rm -f $(DESTDIR)$(rootlibdir)/libsystemd-daemon.so*
1524
1525 libsystemd_login_la_SOURCES = \
1526         src/sd-login.c \
1527         src/cgroup-util.c
1528
1529 libsystemd_login_la_CFLAGS = \
1530         $(AM_CFLAGS) \
1531         -fvisibility=hidden
1532
1533 libsystemd_login_la_LDFLAGS = \
1534         -shared \
1535         -version-info $(LIBSYSTEMD_LOGIN_CURRENT):$(LIBSYSTEMD_LOGIN_REVISION):$(LIBSYSTEMD_LOGIN_AGE) \
1536         -Wl,--version-script=$(top_srcdir)/src/libsystemd-login.sym
1537
1538 libsystemd_login_la_LIBADD = \
1539         libsystemd-basic.la
1540
1541 # move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
1542 libsystemd-login-install-hook:
1543         if test "$(libdir)" != "$(rootlibdir)"; then \
1544                 mkdir -p $(DESTDIR)$(rootlibdir) && \
1545                 so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-login.so) && \
1546                 so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
1547                 ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-login.so && \
1548                 mv $(DESTDIR)$(libdir)/libsystemd-login.so.* $(DESTDIR)$(rootlibdir); \
1549         fi
1550
1551 libsystemd-login-uninstall-hook:
1552         rm -f $(DESTDIR)$(rootlibdir)/libsystemd-login.so*
1553
1554 SED_PROCESS = \
1555         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1556         $(SED)  -e 's,@rootlibexecdir\@,$(rootlibexecdir),g' \
1557                 -e 's,@rootbindir\@,$(rootbindir),g' \
1558                 -e 's,@bindir\@,$(bindir),g' \
1559                 -e 's,@SYSTEMCTL\@,$(rootbindir)/systemctl,g' \
1560                 -e 's,@SYSTEMD_NOTIFY\@,$(rootbindir)/systemd-notify,g' \
1561                 -e 's,@pkgsysconfdir\@,$(pkgsysconfdir),g' \
1562                 -e 's,@pkgdatadir\@,$(pkgdatadir),g' \
1563                 -e 's,@pkglibexecdir\@,$(pkglibexecdir),g' \
1564                 -e 's,@systemunitdir\@,$(systemunitdir),g' \
1565                 -e 's,@userunitdir\@,$(userunitdir),g' \
1566                 -e 's,@PACKAGE_VERSION\@,$(PACKAGE_VERSION),g' \
1567                 -e 's,@PACKAGE_NAME\@,$(PACKAGE_NAME),g' \
1568                 -e 's,@PACKAGE_URL\@,$(PACKAGE_URL),g' \
1569                 -e 's,@prefix\@,$(prefix),g' \
1570                 -e 's,@exec_prefix\@,$(exec_prefix),g' \
1571                 -e 's,@libdir\@,$(libdir),g' \
1572                 -e 's,@includedir\@,$(includedir),g' \
1573                 < $< > $@ || rm $@
1574
1575 units/%: units/%.in Makefile
1576         $(SED_PROCESS)
1577
1578 man/%: man/%.in Makefile
1579         $(SED_PROCESS)
1580
1581 %.pc: %.pc.in Makefile
1582         $(SED_PROCESS)
1583
1584 src/%.policy.in: src/%.policy.in.in Makefile
1585         $(SED_PROCESS)
1586
1587 src/%.rules: src/%.rules.in Makefile
1588         $(SED_PROCESS)
1589
1590 src/%.c: src/%.gperf
1591         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1592         $(GPERF) < $< > $@
1593
1594 src/%: src/%.m4
1595         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1596         $(M4) -P $(M4_DEFINES) < $< > $@ || rm $@
1597
1598 src/load-fragment-gperf-nulstr.c: src/load-fragment-gperf.gperf
1599         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1600         $(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 ";" }' < $< > $@ || rm $@
1601
1602 M4_PROCESS_SYSTEM = \
1603         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1604         $(M4) -P $(M4_DEFINES) -DFOR_SYSTEM=1 < $< > $@ || rm $@
1605
1606 M4_PROCESS_USER = \
1607         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1608         $(M4) -P $(M4_DEFINES) -DFOR_USER=1 < $< > $@ || rm $@
1609
1610 units/%: units/%.m4 Makefile
1611         $(M4_PROCESS_SYSTEM)
1612
1613 units/user/%: units/%.m4 Makefile
1614         $(M4_PROCESS_USER)
1615
1616 CLEANFILES = \
1617         $(nodist_systemunit_DATA) \
1618         $(nodist_userunit_DATA) \
1619         $(nodist_man_MANS) \
1620         ${XML_IN_FILES:.xml.in=.html} \
1621         $(pkgconfigdata_DATA) \
1622         $(pkgconfiglib_DATA) \
1623         $(nodist_polkitpolicy_DATA) \
1624         src/73-seat-late.rules \
1625         src/99-systemd.rules \
1626         src/load-fragment-gperf.gperf \
1627         src/load-fragment-gperf.c \
1628         src/load-fragment-gperf-nulstr.c \
1629         src/logind-gperf.c
1630
1631 if HAVE_VALAC
1632 CLEANFILES += \
1633         ${systemadm_SOURCES:.vala=.c}
1634 endif
1635
1636 if HAVE_XSLTPROC
1637 XSLTPROC_FLAGS = \
1638         --nonet \
1639         --param funcsynopsis.style "'ansi'"
1640
1641 XSLTPROC_PROCESS_MAN = \
1642         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1643         $(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
1644
1645 XSLTPROC_PROCESS_MAN_IN = \
1646         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1647         $(XSLTPROC) -o ${@:.in=} $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $< && \
1648         mv ${@:.in=} $@
1649
1650 XSLTPROC_PROCESS_HTML = \
1651         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1652         $(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/xhtml-1_1/docbook.xsl $<
1653
1654 XSLTPROC_PROCESS_HTML_IN = \
1655         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1656         $(XSLTPROC) -o ${@:.in=} $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/xhtml-1_1/docbook.xsl $< && \
1657         mv ${@:.in=} $@
1658
1659 man/%.1: man/%.xml
1660         $(XSLTPROC_PROCESS_MAN)
1661
1662 man/%.1.in: man/%.xml.in
1663         $(XSLTPROC_PROCESS_MAN)
1664
1665 man/%.3: man/%.xml
1666         $(XSLTPROC_PROCESS_MAN)
1667
1668 man/%.3.in: man/%.xml.in
1669         $(XSLTPROC_PROCESS_MAN)
1670
1671 man/%.5: man/%.xml
1672         $(XSLTPROC_PROCESS_MAN)
1673
1674 man/%.5.in: man/%.xml.in
1675         $(XSLTPROC_PROCESS_MAN)
1676
1677 man/%.7: man/%.xml
1678         $(XSLTPROC_PROCESS_MAN)
1679
1680 man/%.7.in: man/%.xml.in
1681         $(XSLTPROC_PROCESS_MAN_IN)
1682
1683 man/%.8: man/%.xml
1684         $(XSLTPROC_PROCESS_MAN)
1685
1686 man/%.8.in: man/%.xml.in
1687         $(XSLTPROC_PROCESS_MAN_IN)
1688
1689 man/%.html: man/%.xml
1690         $(XSLTPROC_PROCESS_HTML)
1691
1692 man/%.html.in: man/%.xml.in
1693         $(XSLTPROC_PROCESS_HTML_IN)
1694
1695 CLEANFILES += \
1696         $(dist_man_MANS) \
1697         ${nodist_man_MANS:=.in} \
1698         ${XML_FILES:.xml=.html} \
1699         ${XML_IN_FILES:.xml.in=.html.in}
1700 endif
1701
1702 DBUS_PREPROCESS = $(CPP) -P $(DBUS_CFLAGS) -imacros dbus/dbus-protocol.h
1703
1704 org.freedesktop.systemd1.%.xml: systemd
1705         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.$* $< $@.tmp && \
1706                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
1707                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
1708
1709 org.freedesktop.hostname1.xml: systemd-hostnamed
1710         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.hostname1 $< $@.tmp && \
1711                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
1712                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
1713
1714 org.freedesktop.locale1.xml: systemd-localed
1715         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.locale1 $< $@.tmp && \
1716                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
1717                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
1718
1719 org.freedesktop.timedate1.xml: systemd-timedated
1720         $(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j introspect.timedate1 $< $@.tmp && \
1721                 $(STRINGS) $@.tmp | $(AWK) -f $(srcdir)/introspect.awk | \
1722                 $(DBUS_PREPROCESS) -o $@ - && rm $@.tmp
1723
1724 CLEANFILES += \
1725         $(dbusinterface_DATA)
1726
1727 install-data-hook:
1728         $(MKDIR_P) -m 0755 \
1729                 $(DESTDIR)$(tmpfilesdir) \
1730                 $(DESTDIR)$(sysconfdir)/tmpfiles.d \
1731                 $(DESTDIR)$(prefix)/lib/modules-load.d \
1732                 $(DESTDIR)$(sysconfdir)/modules-load.d \
1733                 $(DESTDIR)$(prefix)/lib/sysctl.d \
1734                 $(DESTDIR)$(sysconfdir)/sysctl.d \
1735                 $(DESTDIR)$(systemshutdowndir) \
1736                 $(DESTDIR)$(systemgeneratordir) \
1737                 $(DESTDIR)$(usergeneratordir)
1738 if ENABLE_BINFMT
1739         $(MKDIR_P) -m 0755 \
1740                 $(DESTDIR)$(prefix)/lib/binfmt.d \
1741                 $(DESTDIR)$(sysconfdir)/binfmt.d
1742 endif
1743         $(MKDIR_P) -m 0755 \
1744                 $(DESTDIR)$(systemunitdir) \
1745                 $(DESTDIR)$(userunitdir) \
1746                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants \
1747                 $(DESTDIR)$(systemunitdir)/sockets.target.wants \
1748                 $(DESTDIR)$(systemunitdir)/basic.target.wants \
1749                 $(DESTDIR)$(systemunitdir)/shutdown.target.wants \
1750                 $(DESTDIR)$(systemunitdir)/local-fs.target.wants \
1751                 $(DESTDIR)$(systemunitdir)/runlevel1.target.wants \
1752                 $(DESTDIR)$(systemunitdir)/runlevel2.target.wants \
1753                 $(DESTDIR)$(systemunitdir)/runlevel3.target.wants \
1754                 $(DESTDIR)$(systemunitdir)/runlevel4.target.wants \
1755                 $(DESTDIR)$(systemunitdir)/runlevel5.target.wants \
1756                 $(DESTDIR)$(systemunitdir)/multi-user.target.wants \
1757                 $(DESTDIR)$(systemunitdir)/graphical.target.wants \
1758                 $(DESTDIR)$(pkgsysconfdir)/system \
1759                 $(DESTDIR)$(pkgsysconfdir)/system/sysinit.target.wants \
1760                 $(DESTDIR)$(pkgsysconfdir)/system/local-fs.target.wants \
1761                 $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants \
1762                 $(DESTDIR)$(pkgsysconfdir)/system/getty.target.wants \
1763                 $(DESTDIR)$(pkgsysconfdir)/user \
1764                 $(DESTDIR)$(dbussessionservicedir) \
1765                 $(DESTDIR)$(sysconfdir)/xdg/systemd
1766         ( cd $(DESTDIR)$(sysconfdir)/xdg/systemd/ && \
1767                 rm -f user && \
1768                 $(LN_S) $(pkgsysconfdir)/user user )
1769         ( cd $(DESTDIR)$(systemunitdir)/sockets.target.wants && \
1770                 rm -f systemd-initctl.socket systemd-stdout-syslog-bridge.socket systemd-shutdownd.socket syslog.socket && \
1771                 $(LN_S) ../systemd-stdout-syslog-bridge.socket systemd-stdout-syslog-bridge.socket && \
1772                 $(LN_S) ../systemd-initctl.socket systemd-initctl.socket && \
1773                 $(LN_S) ../systemd-shutdownd.socket systemd-shutdownd.socket && \
1774                 $(LN_S) ../syslog.socket syslog.socket )
1775         ( cd $(DESTDIR)$(systemunitdir)/runlevel1.target.wants && \
1776                 rm -f systemd-update-utmp-runlevel.service && \
1777                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
1778         ( cd $(DESTDIR)$(systemunitdir)/runlevel2.target.wants && \
1779                 rm -f systemd-update-utmp-runlevel.service && \
1780                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
1781         ( cd $(DESTDIR)$(systemunitdir)/runlevel3.target.wants && \
1782                 rm -f systemd-update-utmp-runlevel.service && \
1783                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
1784         ( cd $(DESTDIR)$(systemunitdir)/runlevel4.target.wants && \
1785                 rm -f systemd-update-utmp-runlevel.service && \
1786                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
1787         ( cd $(DESTDIR)$(systemunitdir)/runlevel5.target.wants && \
1788                 rm -f systemd-update-utmp-runlevel.service && \
1789                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
1790         ( cd $(DESTDIR)$(systemunitdir)/shutdown.target.wants && \
1791                 rm -f systemd-update-utmp-shutdown.service \
1792                         systemd-random-seed-save.service && \
1793                 $(LN_S) ../systemd-update-utmp-shutdown.service systemd-update-utmp-shutdown.service && \
1794                 $(LN_S) ../systemd-random-seed-save.service systemd-random-seed-save.service )
1795         ( cd $(DESTDIR)$(systemunitdir)/local-fs.target.wants && \
1796                 rm -f systemd-remount-api-vfs.service \
1797                         fsck-root.service \
1798                         remount-rootfs.service \
1799                         var-run.mount \
1800                         media.mount && \
1801                 $(LN_S) ../systemd-remount-api-vfs.service systemd-remount-api-vfs.service && \
1802                 $(LN_S) ../fsck-root.service fsck-root.service && \
1803                 $(LN_S) ../remount-rootfs.service remount-rootfs.service && \
1804                 $(LN_S) ../var-run.mount var-run.mount && \
1805                 $(LN_S) ../media.mount media.mount )
1806         ( cd $(DESTDIR)$(userunitdir) && \
1807                 rm -f shutdown.target sockets.target bluetooth.target printer.target sound.target && \
1808                 $(LN_S) $(systemunitdir)/shutdown.target shutdown.target && \
1809                 $(LN_S) $(systemunitdir)/sockets.target sockets.target && \
1810                 $(LN_S) $(systemunitdir)/bluetooth.target bluetooth.target && \
1811                 $(LN_S) $(systemunitdir)/printer.target printer.target && \
1812                 $(LN_S) $(systemunitdir)/sound.target sound.target )
1813         ( cd $(DESTDIR)$(systemunitdir) && \
1814                 rm -f runlevel0.target runlevel1.target runlevel2.target runlevel3.target runlevel4.target runlevel5.target runlevel6.target && \
1815                 $(LN_S) poweroff.target runlevel0.target && \
1816                 $(LN_S) rescue.target runlevel1.target && \
1817                 $(LN_S) multi-user.target runlevel2.target && \
1818                 $(LN_S) multi-user.target runlevel3.target && \
1819                 $(LN_S) multi-user.target runlevel4.target && \
1820                 $(LN_S) graphical.target runlevel5.target && \
1821                 $(LN_S) reboot.target runlevel6.target )
1822         ( cd $(DESTDIR)$(systemunitdir) && \
1823                 rm -f default.target ctrl-alt-del.target dbus-org.freedesktop.login1.service autovt@.service && \
1824                 $(LN_S) graphical.target default.target && \
1825                 $(LN_S) reboot.target ctrl-alt-del.target && \
1826                 $(LN_S) systemd-logind.service dbus-org.freedesktop.login1.service && \
1827                 $(LN_S) getty@.service autovt@.service )
1828         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
1829                 rm -f getty.target systemd-user-sessions.service systemd-ask-password-wall.path systemd-logind.service && \
1830                 $(LN_S) ../getty.target getty.target && \
1831                 $(LN_S) ../systemd-user-sessions.service systemd-user-sessions.service && \
1832                 $(LN_S) ../systemd-ask-password-wall.path systemd-ask-password-wall.path && \
1833                 $(LN_S) ../systemd-logind.service systemd-logind.service )
1834         ( cd $(DESTDIR)$(pkgsysconfdir)/system/getty.target.wants && \
1835                 rm -f getty@tty1.service && \
1836                 $(LN_S) $(systemunitdir)/getty@.service getty@tty1.service )
1837         ( cd $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants && \
1838                 rm -f remote-fs.target && \
1839                 $(LN_S) $(systemunitdir)/remote-fs.target remote-fs.target )
1840         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
1841                 rm -f dev-hugepages.automount \
1842                         dev-mqueue.automount \
1843                         sys-kernel-debug.automount \
1844                         sys-kernel-security.automount \
1845                         systemd-vconsole-setup.service \
1846                         systemd-modules-load.service \
1847                         systemd-random-seed-load.service \
1848                         systemd-tmpfiles-setup.service \
1849                         systemd-sysctl.service \
1850                         systemd-ask-password-console.path \
1851                         systemd-kmsg-syslogd.service \
1852                         cryptsetup.target && \
1853                 $(LN_S) ../dev-hugepages.automount dev-hugepages.automount && \
1854                 $(LN_S) ../dev-mqueue.automount dev-mqueue.automount && \
1855                 $(LN_S) ../sys-kernel-debug.automount sys-kernel-debug.automount && \
1856                 $(LN_S) ../sys-kernel-security.automount sys-kernel-security.automount && \
1857                 $(LN_S) ../systemd-vconsole-setup.service systemd-vconsole-setup.service && \
1858                 $(LN_S) ../systemd-modules-load.service systemd-modules-load.service && \
1859                 $(LN_S) ../systemd-random-seed-load.service systemd-random-seed-load.service && \
1860                 $(LN_S) ../systemd-tmpfiles-setup.service systemd-tmpfiles-setup.service && \
1861                 $(LN_S) ../systemd-sysctl.service systemd-sysctl.service && \
1862                 $(LN_S) ../systemd-ask-password-console.path systemd-ask-password-console.path && \
1863                 $(LN_S) ../systemd-kmsg-syslogd.service && \
1864                 $(LN_S) ../cryptsetup.target cryptsetup.target )
1865 if ENABLE_BINFMT
1866         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
1867                 rm -f systemd-binfmt.service \
1868                         proc-sys-fs-binfmt_misc.automount && \
1869                 $(LN_S) ../systemd-binfmt.service systemd-binfmt.service && \
1870                 $(LN_S) ../proc-sys-fs-binfmt_misc.automount proc-sys-fs-binfmt_misc.automount )
1871 endif
1872 if ENABLE_HOSTNAMED
1873         ( cd $(DESTDIR)$(systemunitdir) && \
1874                 rm -f dbus-org.freedesktop.hostname1.service && \
1875                 $(LN_S) systemd-hostnamed.service dbus-org.freedesktop.hostname1.service )
1876 endif
1877 if ENABLE_TIMEDATED
1878         ( cd $(DESTDIR)$(systemunitdir) && \
1879                 rm -f dbus-org.freedesktop.timedate1.service  && \
1880                 $(LN_S) systemd-timedated.service dbus-org.freedesktop.timedate1.service )
1881 endif
1882 if ENABLE_LOCALED
1883         ( cd $(DESTDIR)$(systemunitdir) && \
1884                 rm -f dbus-org.freedesktop.locale1.service && \
1885                 $(LN_S) systemd-localed.service dbus-org.freedesktop.locale1.service )
1886 endif
1887         ( cd $(DESTDIR)$(systemunitdir)/basic.target.wants && \
1888                 rm -f systemd-tmpfiles-clean.timer && \
1889                 $(LN_S) ../systemd-tmpfiles-clean.timer systemd-tmpfiles-clean.timer )
1890         ( cd $(DESTDIR)$(dbussessionservicedir) && \
1891                 rm -f org.freedesktop.systemd1.service && \
1892                 $(LN_S) ../system-services/org.freedesktop.systemd1.service org.freedesktop.systemd1.service )
1893 if HAVE_PLYMOUTH
1894         $(MKDIR_P) -m 0755 \
1895                 $(DESTDIR)$(SYSTEM_SYSVINIT_PATH) \
1896                 $(DESTDIR)$(systemunitdir)/reboot.target.wants \
1897                 $(DESTDIR)$(systemunitdir)/kexec.target.wants \
1898                 $(DESTDIR)$(systemunitdir)/poweroff.target.wants \
1899                 $(DESTDIR)$(systemunitdir)/halt.target.wants
1900         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
1901                 rm -f plymouth-start.service plymouth-read-write.service && \
1902                 $(LN_S) ../plymouth-start.service plymouth-start.service && \
1903                 $(LN_S) ../plymouth-read-write.service plymouth-read-write.service )
1904         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
1905                 rm -f plymouth-quit.service plymouth-quit-wait.service && \
1906                 $(LN_S) ../plymouth-quit.service plymouth-quit.service && \
1907                 $(LN_S) ../plymouth-quit-wait.service plymouth-quit-wait.service )
1908         ( cd $(DESTDIR)$(systemunitdir)/reboot.target.wants && \
1909                 rm -f plymouth-reboot.service && \
1910                 $(LN_S) ../plymouth-reboot.service plymouth-reboot.service )
1911         ( cd $(DESTDIR)$(systemunitdir)/kexec.target.wants && \
1912                 rm -f plymouth-kexec.service && \
1913                 $(LN_S) ../plymouth-kexec.service plymouth-kexec.service )
1914         ( cd $(DESTDIR)$(systemunitdir)/poweroff.target.wants && \
1915                 rm -f plymouth-poweroff.service && \
1916                 $(LN_S) ../plymouth-poweroff.service plymouth-poweroff.service )
1917         ( cd $(DESTDIR)$(systemunitdir)/halt.target.wants && \
1918                 rm -f plymouth-halt.service && \
1919                 $(LN_S) ../plymouth-halt.service plymouth-halt.service )
1920 endif
1921 if TARGET_MEEGO
1922         $(MKDIR_P) -m 0755 $(DESTDIR)$(systemunitdir)/final.target.wants
1923         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
1924                 rm -f network.target && \
1925                 $(LN_S) $(systemunitdir)/network.target network.target )
1926         ( cd $(DESTDIR)$(pkgsysconfdir)/system/sysinit.target.wants && \
1927                 rm -f * )
1928         ( cd $(DESTDIR)$(pkgsysconfdir)/system/local-fs.target.wants && \
1929                 rm -f * )
1930         ( cd $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants && \
1931                 rm -f * )
1932         ( cd $(DESTDIR)$(pkgsysconfdir)/system/getty.target.wants && \
1933                 rm -f * )
1934 endif
1935
1936 if TARGET_FEDORA
1937         $(MKDIR_P) -m 0755 $(DESTDIR)$(systemunitdir)/final.target.wants
1938         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
1939                 rm -f rc-local.service && \
1940                 $(LN_S) $(systemunitdir)/rc-local.service rc-local.service )
1941         ( cd $(DESTDIR)$(systemunitdir)/final.target.wants && \
1942                 rm -f halt-local.service && \
1943                 $(LN_S) $(systemunitdir)/halt-local.service halt-local.service )
1944         ( cd $(DESTDIR)$(systemunitdir) && \
1945                 rm -f display-manager.service single.service && \
1946                 $(LN_S) prefdm.service display-manager.service && \
1947                 $(LN_S) rescue.service single.service )
1948         ( cd $(DESTDIR)$(systemunitdir)/graphical.target.wants && \
1949                 rm -f display-manager.service && \
1950                 $(LN_S) $(systemunitdir)/display-manager.service display-manager.service )
1951 endif
1952
1953 if TARGET_MANDRIVA
1954         $(MKDIR_P) -m 0755 $(DESTDIR)$(systemunitdir)/final.target.wants
1955         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
1956                 rm -f rc-local.service && \
1957                 $(LN_S) $(systemunitdir)/rc-local.service rc-local.service )
1958         ( cd $(DESTDIR)$(systemunitdir)/final.target.wants && \
1959                 rm -f halt-local.service && \
1960                 $(LN_S) $(systemunitdir)/halt-local.service halt-local.service )
1961         ( cd $(DESTDIR)$(systemunitdir) && \
1962                 rm -f display-manager.service dm.service single.service && \
1963                 $(LN_S) prefdm.service display-manager.service && \
1964                 $(LN_S) prefdm.service dm.service && \
1965                 $(LN_S) rescue.service single.service )
1966         ( cd $(DESTDIR)$(systemunitdir)/graphical.target.wants && \
1967                 rm -f display-manager.service && \
1968                 $(LN_S) $(systemunitdir)/display-manager.service display-manager.service )
1969 endif
1970
1971 if TARGET_DEBIAN_OR_UBUNTU
1972         ( cd $(DESTDIR)$(systemunitdir) && \
1973                 rm -f runlevel5.target && \
1974                 $(LN_S) multi-user.target runlevel5.target )
1975 endif
1976
1977 if TARGET_SUSE
1978         $(MKDIR_P) -m 0755 $(DESTDIR)$(systemunitdir)/final.target.wants
1979         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
1980                 rm -f rc-local.service && \
1981                 $(LN_S) $(systemunitdir)/rc-local.service rc-local.service )
1982         ( cd $(DESTDIR)$(systemunitdir) && \
1983                 rm -f local.service && \
1984                 $(LN_S) rc-local.service local.service )
1985         ( cd $(DESTDIR)$(systemunitdir)/final.target.wants && \
1986                 rm -f halt-local.service && \
1987                 $(LN_S) $(systemunitdir)/halt-local.service halt-local.service )
1988 endif
1989
1990 if HAVE_SYSV_COMPAT
1991         ( cd $(DESTDIR)$(systemunitdir)/local-fs.target.wants && \
1992                 rm -f var-lock.mount && \
1993                 $(LN_S) ../var-lock.mount var-lock.mount )
1994 endif
1995
1996 install-exec-hook: libsystemd-daemon-install-hook libsystemd-login-install-hook
1997
1998 uninstall-hook: libsystemd-daemon-uninstall-hook libsystemd-login-uninstall-hook
1999
2000 DISTCHECK_CONFIGURE_FLAGS = \
2001         --with-dbuspolicydir=$$dc_install_base/$(dbuspolicydir) \
2002         --with-dbussessionservicedir=$$dc_install_base/$(dbussessionservicedir) \
2003         --with-dbussystemservicedir=$$dc_install_base/$(dbussystemservicedir) \
2004         --with-dbusinterfacedir=$$dc_install_base/$(dbusinterfacedir) \
2005         --with-udevrulesdir=$$dc_install_base/$(udevrulesdir) \
2006         --with-pamlibdir=$$dc_install_base/$(pamlibdir) \
2007         --with-rootdir=$$dc_install_base/$(rootdir)
2008
2009 upload: all distcheck
2010         cp -v systemd-$(VERSION).tar.bz2 /home/lennart/git.fedora/systemd/
2011         scp systemd-$(VERSION).tar.bz2 fdo:/srv/www.freedesktop.org/www/software/systemd/
2012         scp man/*.html tango:public/systemd-man/
2013
2014 git-tag:
2015         git tag "v$(VERSION)" -m "systemd $(VERSION)"