chiark / gitweb /
tmpfiles: ignore files marked with the sticky bit
[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 # Dirs of external packages
21 dbuspolicydir=@dbuspolicydir@
22 dbussessionservicedir=@dbussessionservicedir@
23 dbussystemservicedir=@dbussystemservicedir@
24 dbusinterfacedir=@dbusinterfacedir@
25 udevrulesdir=@udevrulesdir@
26 pamlibdir=@pamlibdir@
27 pkgconfigdatadir=$(datadir)/pkgconfig
28 polkitpolicydir=$(datadir)/polkit-1/actions
29 bashcompletiondir=$(sysconfdir)/bash_completion.d
30
31 # Our own, non-special dirs
32 pkgsysconfdir=$(sysconfdir)/systemd
33 sessionunitdir=$(pkgdatadir)/session
34 tmpfilesdir=$(sysconfdir)/tmpfiles.d
35 sessiongeneratordir=$(pkglibexecdir)/session-generators
36
37 # And these are the special ones for /
38 rootdir=@rootdir@
39 rootbindir=$(rootdir)/bin
40 rootsbindir=$(rootdir)/sbin
41 rootlibexecdir=$(rootdir)/lib/systemd
42 systemunitdir=$(rootdir)/lib/systemd/system
43 systemgeneratordir=$(rootdir)/lib/systemd/system-generators
44
45 AM_CPPFLAGS = \
46         -include $(top_builddir)/config.h \
47         -DSYSTEM_CONFIG_FILE=\"$(pkgsysconfdir)/system.conf\" \
48         -DSYSTEM_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/system\" \
49         -DSYSTEM_DATA_UNIT_PATH=\"$(systemunitdir)\" \
50         -DSYSTEM_SYSVINIT_PATH=\"$(SYSTEM_SYSVINIT_PATH)\" \
51         -DSYSTEM_SYSVRCND_PATH=\"$(SYSTEM_SYSVRCND_PATH)\" \
52         -DSESSION_CONFIG_FILE=\"$(pkgsysconfdir)/session.conf\" \
53         -DSESSION_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/session\" \
54         -DSESSION_DATA_UNIT_PATH=\"$(sessionunitdir)\" \
55         -DSYSTEMD_CGROUP_AGENT_PATH=\"$(rootlibexecdir)/systemd-cgroups-agent\" \
56         -DSYSTEMD_BINARY_PATH=\"$(rootbindir)/systemd\" \
57         -DSYSTEMD_SHUTDOWN_BINARY_PATH=\"$(rootlibexecdir)/systemd-shutdown\" \
58         -DSYSTEMCTL_BINARY_PATH=\"$(rootbindir)/systemctl\" \
59         -DSYSTEMD_TTY_ASK_PASSWORD_AGENT_BINARY_PATH=\"$(rootbindir)/systemd-tty-ask-password-agent\" \
60         -DRUNTIME_DIR=\"$(localstatedir)/run\" \
61         -DRANDOM_SEED=\"$(localstatedir)/lib/random-seed\" \
62         -DSYSTEMD_CRYPTSETUP_PATH=\"$(rootlibexecdir)/systemd-cryptsetup\" \
63         -DSYSTEM_GENERATOR_PATH=\"$(systemgeneratordir)\" \
64         -DSESSION_GENERATOR_PATH=\"$(sessiongeneratordir)\" \
65         -I $(top_srcdir)/src
66
67 if TARGET_GENTOO
68 AM_CPPFLAGS += \
69         -DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
70         -DKBD_SETFONT=\"/usr/bin/setfont\" \
71         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
72 else
73 if TARGET_ARCH
74 AM_CPPFLAGS += \
75         -DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
76         -DKBD_SETFONT=\"/usr/bin/setfont\" \
77         -DDEFAULT_FONT=\"LatArCyrHeb-16\"
78 else
79 AM_CPPFLAGS += \
80         -DKBD_LOADKEYS=\"/bin/loadkeys\" \
81         -DKBD_SETFONT=\"/bin/setfont\" \
82         -DDEFAULT_FONT=\"latarcyrheb-sun16\"
83 endif
84 endif
85
86 rootbin_PROGRAMS = \
87         systemd \
88         systemctl \
89         systemd-notify \
90         systemd-ask-password \
91         systemd-tty-ask-password-agent
92
93 bin_PROGRAMS = \
94         systemd-cgls
95
96 if HAVE_GTK
97 bin_PROGRAMS += \
98         systemadm \
99         systemd-gnome-ask-password-agent
100 endif
101
102 rootlibexec_PROGRAMS = \
103         systemd-logger \
104         systemd-cgroups-agent \
105         systemd-initctl \
106         systemd-update-utmp \
107         systemd-random-seed \
108         systemd-shutdownd \
109         systemd-shutdown \
110         systemd-modules-load \
111         systemd-remount-api-vfs \
112         systemd-kmsg-syslogd \
113         systemd-vconsole-setup \
114         systemd-reply-password \
115         systemd-readahead-collect \
116         systemd-readahead-replay \
117         systemd-tmpfiles \
118         systemd-user-sessions \
119         systemd-fsck \
120         systemd-quotacheck \
121         systemd-timestamp \
122         systemd-ac-power
123
124 if HAVE_LIBCRYPTSETUP
125 rootlibexec_PROGRAMS += \
126         systemd-cryptsetup
127
128 systemgenerator_PROGRAMS = \
129         systemd-cryptsetup-generator
130 endif
131
132 noinst_PROGRAMS = \
133         test-engine \
134         test-job-type \
135         test-ns \
136         test-loopback \
137         test-hostname \
138         test-daemon \
139         test-cgroup \
140         test-env-replace \
141         test-strv
142
143 if HAVE_PAM
144 pamlib_LTLIBRARIES = \
145         pam_systemd.la
146 endif
147
148 dist_pkgsysconf_DATA = \
149         src/system.conf
150
151 dist_dbuspolicy_DATA = \
152         src/org.freedesktop.systemd1.conf
153
154 dist_dbussystemservice_DATA = \
155         src/org.freedesktop.systemd1.service
156
157 dist_udevrules_DATA = \
158         src/99-systemd.rules
159
160 dbusinterface_DATA = \
161         org.freedesktop.systemd1.Manager.xml \
162         org.freedesktop.systemd1.Job.xml \
163         org.freedesktop.systemd1.Unit.xml \
164         org.freedesktop.systemd1.Service.xml \
165         org.freedesktop.systemd1.Socket.xml \
166         org.freedesktop.systemd1.Timer.xml \
167         org.freedesktop.systemd1.Target.xml \
168         org.freedesktop.systemd1.Device.xml \
169         org.freedesktop.systemd1.Mount.xml \
170         org.freedesktop.systemd1.Automount.xml \
171         org.freedesktop.systemd1.Snapshot.xml \
172         org.freedesktop.systemd1.Swap.xml \
173         org.freedesktop.systemd1.Path.xml
174
175 dist_bashcompletion_DATA = \
176         src/systemctl-bash-completion.sh
177
178 dist_tmpfiles_DATA = \
179         tmpfiles.d/systemd.conf \
180         tmpfiles.d/x11.conf
181
182 dist_systemunit_DATA = \
183         units/emergency.service \
184         units/emergency.target \
185         units/sysinit.target \
186         units/basic.target \
187         units/getty.target \
188         units/halt.target \
189         units/kexec.target \
190         units/local-fs.target \
191         units/network.target \
192         units/nss-lookup.target \
193         units/mail-transfer-agent.target \
194         units/http-daemon.target \
195         units/poweroff.target \
196         units/reboot.target \
197         units/rescue.target \
198         units/rpcbind.target \
199         units/rtc-set.target \
200         units/shutdown.target \
201         units/final.target \
202         units/umount.target \
203         units/sigpwr.target \
204         units/sockets.target \
205         units/swap.target \
206         units/dbus.target \
207         units/systemd-initctl.socket \
208         units/systemd-logger.socket \
209         units/systemd-shutdownd.socket \
210         units/syslog.socket \
211         units/dev-hugepages.automount \
212         units/dev-hugepages.mount \
213         units/dev-mqueue.automount \
214         units/dev-mqueue.mount \
215         units/proc-sys-fs-binfmt_misc.automount \
216         units/proc-sys-fs-binfmt_misc.mount \
217         units/sys-kernel-debug.automount \
218         units/sys-kernel-debug.mount \
219         units/sys-kernel-security.automount \
220         units/sys-kernel-security.mount \
221         units/tmp.mount \
222         units/var-lock.mount \
223         units/var-run.mount \
224         units/hwclock-load.service \
225         units/hwclock-save.service \
226         units/sysctl.service \
227         units/remount-rootfs.service \
228         units/printer.target \
229         units/bluetooth.target \
230         units/smartcard.target \
231         units/systemd-readahead-done.timer \
232         units/systemd-tmpfiles-clean.timer \
233         units/quotaon.service \
234         units/systemd-ask-password-wall.path \
235         units/systemd-ask-password-plymouth.path
236
237 nodist_systemunit_DATA = \
238         units/getty@.service \
239         units/serial-getty@.service \
240         units/graphical.target \
241         units/remote-fs.target \
242         units/multi-user.target \
243         units/systemd-initctl.service \
244         units/systemd-logger.service \
245         units/systemd-shutdownd.service \
246         units/systemd-kmsg-syslogd.service \
247         units/systemd-modules-load.service \
248         units/systemd-vconsole-setup.service \
249         units/systemd-remount-api-vfs.service \
250         units/systemd-update-utmp-runlevel.service \
251         units/systemd-update-utmp-shutdown.service \
252         units/systemd-random-seed-save.service \
253         units/systemd-random-seed-load.service \
254         units/systemd-readahead-collect.service \
255         units/systemd-readahead-replay.service \
256         units/systemd-readahead-done.service \
257         units/systemd-tmpfiles-setup.service \
258         units/systemd-tmpfiles-clean.service \
259         units/systemd-user-sessions.service \
260         units/systemd-ask-password-wall.service \
261         units/systemd-ask-password-plymouth.service \
262         units/syslog.target \
263         units/halt.service \
264         units/poweroff.service \
265         units/reboot.service \
266         units/kexec.service \
267         units/fsck@.service \
268         units/fsck-root.service \
269         units/quotacheck.service \
270         units/rescue.service
271
272 dist_sessionunit_DATA = \
273         units/session/default.target \
274         units/session/exit.target
275
276 nodist_sessionunit_DATA = \
277         units/session/remote-fs.target \
278         units/session/exit.service
279
280 EXTRA_DIST = \
281         units/getty@.service.m4 \
282         units/serial-getty@.service.m4 \
283         units/graphical.target.m4 \
284         units/multi-user.target.m4 \
285         units/remote-fs.target.m4 \
286         units/rescue.service.m4 \
287         units/systemd-initctl.service.in \
288         units/systemd-logger.service.in \
289         units/systemd-shutdownd.service.in \
290         units/systemd-kmsg-syslogd.service.in \
291         units/systemd-modules-load.service.in \
292         units/systemd-vconsole-setup.service.in \
293         units/systemd-remount-api-vfs.service.in \
294         units/systemd-update-utmp-runlevel.service.in \
295         units/systemd-update-utmp-shutdown.service.in \
296         units/systemd-random-seed-save.service.in \
297         units/systemd-random-seed-load.service.in \
298         units/systemd-readahead-collect.service.in \
299         units/systemd-readahead-replay.service.in \
300         units/systemd-readahead-done.service.in \
301         units/systemd-tmpfiles-setup.service.in \
302         units/systemd-tmpfiles-clean.service.in \
303         units/systemd-user-sessions.service.in \
304         units/systemd-ask-password-wall.service.in \
305         units/systemd-ask-password-plymouth.service.in \
306         units/syslog.target.in \
307         units/halt.service.in \
308         units/poweroff.service.in \
309         units/reboot.service.in \
310         units/kexec.service.in \
311         units/session/exit.service.in \
312         units/fsck@.service.in \
313         units/fsck-root.service.in \
314         units/quotacheck.service.in \
315         systemd.pc.in
316
317 if TARGET_FEDORA
318 dist_systemunit_DATA += \
319         units/fedora/prefdm.service \
320         units/fedora/rc-local.service \
321         units/fedora/halt-local.service \
322         units/fedora/plymouth-start.service \
323         units/fedora/plymouth-read-write.service \
324         units/fedora/plymouth-quit.service \
325         units/fedora/plymouth-reboot.service \
326         units/fedora/plymouth-kexec.service \
327         units/fedora/plymouth-poweroff.service \
328         units/fedora/plymouth-halt.service
329 endif
330
331 if TARGET_DEBIAN_OR_UBUNTU
332 dist_systemunit_DATA += \
333         units/debian/umountfs.service \
334         units/debian/umountnfs.service \
335         units/debian/umountroot.service
336 endif
337
338 if TARGET_GENTOO
339 dist_systemunit_DATA += \
340         units/gentoo/xdm.service
341 endif
342
343 if TARGET_ARCH
344 dist_systemunit_DATA += \
345         units/arch/rc-local.service
346 endif
347
348 dist_doc_DATA = \
349         README \
350         LICENSE \
351         DISTRO_PORTING \
352         src/sd-daemon.h \
353         src/sd-daemon.c \
354         src/sd-readahead.h \
355         src/sd-readahead.c
356
357 pkgconfigdata_DATA = \
358         systemd.pc
359
360 dist_polkitpolicy_DATA = \
361         src/org.freedesktop.systemd1.policy
362
363 noinst_LTLIBRARIES = \
364         libsystemd-basic.la \
365         libsystemd-core.la
366
367 libsystemd_basic_la_SOURCES = \
368         src/util.c \
369         src/label.c \
370         src/hashmap.c \
371         src/set.c \
372         src/strv.c \
373         src/conf-parser.c \
374         src/socket-util.c \
375         src/log.c \
376         src/ratelimit.c
377
378 libsystemd_basic_la_CFLAGS = \
379         $(AM_CFLAGS) \
380         $(SELINUX_CFLAGS)
381
382 libsystemd_basic_la_LIBADD = \
383         $(SELINUX_LIBS)
384
385 libsystemd_core_la_SOURCES = \
386         src/unit.c \
387         src/job.c \
388         src/manager.c \
389         src/path-lookup.c \
390         src/load-fragment.c \
391         src/service.c \
392         src/automount.c \
393         src/mount.c \
394         src/swap.c \
395         src/device.c \
396         src/target.c \
397         src/snapshot.c \
398         src/socket.c \
399         src/timer.c \
400         src/path.c \
401         src/load-dropin.c \
402         src/execute.c \
403         src/utmp-wtmp.c \
404         src/exit-status.c \
405         src/dbus.c \
406         src/dbus-manager.c \
407         src/dbus-unit.c \
408         src/dbus-job.c \
409         src/dbus-service.c \
410         src/dbus-socket.c \
411         src/dbus-timer.c \
412         src/dbus-target.c \
413         src/dbus-mount.c \
414         src/dbus-automount.c \
415         src/dbus-swap.c \
416         src/dbus-snapshot.c \
417         src/dbus-device.c \
418         src/dbus-execute.c \
419         src/dbus-path.c \
420         src/cgroup.c \
421         src/mount-setup.c \
422         src/hostname-setup.c \
423         src/selinux-setup.c \
424         src/loopback-setup.c \
425         src/kmod-setup.c \
426         src/locale-setup.c \
427         src/specifier.c \
428         src/unit-name.c \
429         src/fdset.c \
430         src/namespace.c \
431         src/tcpwrap.c \
432         src/cgroup-util.c \
433         src/condition.c
434
435 libsystemd_core_la_CFLAGS = \
436         $(AM_CFLAGS) \
437         $(DBUS_CFLAGS) \
438         $(UDEV_CFLAGS) \
439         $(LIBWRAP_CFLAGS) \
440         $(PAM_CFLAGS) \
441         $(AUDIT_CFLAGS)
442
443 libsystemd_core_la_LIBADD = \
444         libsystemd-basic.la \
445         $(DBUS_LIBS) \
446         $(UDEV_LIBS) \
447         $(LIBWRAP_LIBS) \
448         $(PAM_LIBS) \
449         $(AUDIT_LIBS)
450
451 # This is needed because automake is buggy in how it generates the
452 # rules for C programs, but not Vala programs.  We therefore can't
453 # list the .h files as dependencies if we want make dist to work.
454
455 EXTRA_DIST += \
456         ${libsystemd_basic_la_SOURCES:.c=.h} \
457         ${libsystemd_core_la_SOURCES:.c=.h} \
458         src/macro.h \
459         src/ioprio.h \
460         src/missing.h \
461         src/list.h \
462         src/securebits.h \
463         src/linux/auto_dev-ioctl.h \
464         src/linux/fanotify.h \
465         src/initreq.h \
466         src/sd-daemon.h \
467         src/sd-readahead.h \
468         src/special.h \
469         src/dbus-common.h \
470         src/bus-errors.h \
471         src/cgroup-show.h \
472         src/build.h \
473         src/shutdownd.h \
474         src/umount.h \
475         src/readahead-common.h \
476         src/ask-password-api.h
477
478 MANPAGES = \
479         man/systemd.1 \
480         man/systemctl.1 \
481         man/systemadm.1 \
482         man/systemd-cgls.1 \
483         man/systemd-notify.1 \
484         man/sd_notify.3 \
485         man/sd_readahead.3 \
486         man/sd_booted.3 \
487         man/sd_listen_fds.3 \
488         man/sd_is_fifo.3 \
489         man/systemd.unit.5 \
490         man/systemd.service.5 \
491         man/systemd.socket.5 \
492         man/systemd.mount.5 \
493         man/systemd.automount.5 \
494         man/systemd.swap.5 \
495         man/systemd.timer.5 \
496         man/systemd.path.5 \
497         man/systemd.target.5 \
498         man/systemd.device.5 \
499         man/systemd.snapshot.5 \
500         man/systemd.exec.5 \
501         man/daemon.7 \
502         man/sd-daemon.7 \
503         man/sd-readahead.7 \
504         man/runlevel.8 \
505         man/telinit.8 \
506         man/halt.8 \
507         man/shutdown.8 \
508         man/pam_systemd.8 \
509         man/systemd.conf.5 \
510         man/tmpfiles.d.5
511
512 MANPAGES_ALIAS = \
513         man/reboot.8 \
514         man/poweroff.8 \
515         man/sd_is_socket.3 \
516         man/sd_is_socket_unix.3 \
517         man/sd_is_socket_inet.3 \
518         man/sd_notifyf.3 \
519         man/init.1
520
521 man/reboot.8: man/halt.8
522 man/poweroff.8: man/halt.8
523 man/sd_is_socket.3: man/sd_is_fifo.3
524 man/sd_is_socket_unix.3: man/sd_is_fifo.3
525 man/sd_is_socket_inet.3: man/sd_is_fifo.3
526 man/sd_notifyf.3: man/sd_notify.3
527 man/init.1: man/systemd.1
528
529 dist_man_MANS = \
530         $(MANPAGES) \
531         $(MANPAGES_ALIAS)
532
533 nodist_man_MANS = \
534         man/systemd.special.7
535
536 XML_FILES = \
537         ${patsubst %.1,%.xml,${patsubst %.3,%.xml,${patsubst %.5,%.xml,${patsubst %.7,%.xml,${patsubst %.8,%.xml,$(MANPAGES)}}}}}
538
539 XML_IN_FILES = \
540         ${patsubst %.1,%.xml.in,${patsubst %.3,%.xml.in,${patsubst %.5,%.xml.in,${patsubst %.7,%.xml.in,${patsubst %.8,%.xml.in,$(nodist_man_MANS)}}}}}
541
542 dist_noinst_DATA = \
543         ${XML_FILES:.xml=.html}
544
545 nodist_noinst_DATA = \
546         ${XML_IN_FILES:.xml.in=.html}
547
548 EXTRA_DIST += \
549         $(XML_FILES) \
550         $(XML_IN_FILES) \
551         ${nodist_man_MANS:=.in} \
552         ${XML_IN_FILES:.xml.in=.html.in}
553
554 systemd_SOURCES = \
555         src/main.c
556
557 systemd_CFLAGS = \
558         $(AM_CFLAGS) \
559         $(DBUS_CFLAGS) \
560         $(UDEV_CFLAGS)
561
562 systemd_LDADD = \
563         libsystemd-core.la
564
565 test_engine_SOURCES = \
566         src/test-engine.c
567
568 test_engine_CFLAGS = $(systemd_CFLAGS)
569 test_engine_LDADD = $(systemd_LDADD)
570
571 test_job_type_SOURCES = \
572         src/test-job-type.c
573
574 test_job_type_CFLAGS = $(systemd_CFLAGS)
575 test_job_type_LDADD = $(systemd_LDADD)
576
577 test_ns_SOURCES = \
578         src/test-ns.c
579
580 test_ns_CFLAGS = $(systemd_CFLAGS)
581 test_ns_LDADD = $(systemd_LDADD)
582
583 test_loopback_SOURCES = \
584         src/test-loopback.c \
585         src/loopback-setup.c
586
587 test_loopback_LDADD = \
588         libsystemd-basic.la
589
590 test_hostname_SOURCES = \
591         src/test-hostname.c \
592         src/hostname-setup.c
593
594 test_hostname_LDADD = \
595         libsystemd-basic.la
596
597 test_daemon_SOURCES = \
598         src/test-daemon.c \
599         src/sd-daemon.c
600
601 test_daemon_LDADD = \
602         libsystemd-basic.la
603
604 test_cgroup_SOURCES = \
605         src/test-cgroup.c \
606         src/cgroup-util.c
607
608 test_cgroup_CFLAGS = \
609         $(AM_CFLAGS)
610
611 test_cgroup_LDADD = \
612         libsystemd-basic.la
613
614 test_env_replace_SOURCES = \
615         src/test-env-replace.c
616
617 test_env_replace_CFLAGS = \
618         $(AM_CFLAGS)
619
620 test_env_replace_LDADD = \
621         libsystemd-basic.la
622
623 test_strv_SOURCES = \
624         src/test-strv.c
625
626 test_strv_CFLAGS = \
627         $(AM_CFLAGS)
628
629 test_strv_LDADD = \
630         libsystemd-basic.la
631
632 systemd_logger_SOURCES = \
633         src/logger.c \
634         src/sd-daemon.c \
635         src/tcpwrap.c
636
637 systemd_logger_LDADD = \
638         libsystemd-basic.la \
639         $(LIBWRAP_LIBS)
640
641 systemd_initctl_SOURCES = \
642         src/initctl.c \
643         src/sd-daemon.c \
644         src/dbus-common.c
645
646 systemd_initctl_CFLAGS = \
647         $(AM_CFLAGS) \
648         $(DBUS_CFLAGS)
649
650 systemd_initctl_LDADD = \
651         libsystemd-basic.la \
652         $(DBUS_LIBS)
653
654 systemd_update_utmp_SOURCES = \
655         src/update-utmp.c \
656         src/dbus-common.c \
657         src/utmp-wtmp.c
658
659 systemd_update_utmp_CFLAGS = \
660         $(AM_CFLAGS) \
661         $(DBUS_CFLAGS) \
662         $(AUDIT_CFLAGS)
663
664 systemd_update_utmp_LDADD = \
665         libsystemd-basic.la \
666         $(DBUS_LIBS) \
667         $(AUDIT_LIBS)
668
669 systemd_random_seed_SOURCES = \
670         src/random-seed.c
671
672 systemd_random_seed_CFLAGS = \
673         $(AM_CFLAGS)
674
675 systemd_random_seed_LDADD = \
676         libsystemd-basic.la
677
678 systemd_shutdownd_SOURCES = \
679         src/utmp-wtmp.c \
680         src/sd-daemon.c \
681         src/shutdownd.c
682
683 systemd_shutdownd_CFLAGS = \
684         $(AM_CFLAGS)
685
686 systemd_shutdownd_LDADD = \
687         libsystemd-basic.la
688
689 systemd_shutdown_SOURCES = \
690         src/mount-setup.c \
691         src/umount.c \
692         src/shutdown.c
693
694 systemd_shutdown_CFLAGS = \
695         $(AM_CFLAGS) \
696         $(UDEV_CFLAGS)
697
698 systemd_shutdown_LDADD = \
699         libsystemd-basic.la \
700         $(UDEV_LIBS)
701
702 systemd_modules_load_SOURCES = \
703         src/modules-load.c
704
705 systemd_modules_load_CFLAGS = \
706         $(AM_CFLAGS)
707
708 systemd_modules_load_LDADD = \
709         libsystemd-basic.la
710
711 systemd_tmpfiles_SOURCES = \
712         src/tmpfiles.c
713
714 systemd_tmpfiles_CFLAGS = \
715         $(AM_CFLAGS)
716
717 systemd_tmpfiles_LDADD = \
718         libsystemd-basic.la
719
720 systemd_fsck_SOURCES = \
721         src/fsck.c \
722         src/dbus-common.c
723
724 systemd_fsck_CFLAGS = \
725         $(AM_CFLAGS) \
726         $(UDEV_CFLAGS) \
727         $(DBUS_CFLAGS)
728
729 systemd_fsck_LDADD = \
730         libsystemd-basic.la \
731         $(UDEV_LIBS) \
732         $(DBUS_LIBS)
733
734 systemd_quotacheck_SOURCES = \
735         src/quotacheck.c
736
737 systemd_quotacheck_CFLAGS = \
738         $(AM_CFLAGS)
739
740 systemd_quotacheck_LDADD = \
741         libsystemd-basic.la
742
743 systemd_timestamp_SOURCES = \
744         src/timestamp.c
745
746 systemd_timestamp_CFLAGS = \
747         $(AM_CFLAGS)
748
749 systemd_timestamp_LDADD = \
750         libsystemd-basic.la
751
752 systemd_ac_power_SOURCES = \
753         src/ac-power.c
754
755 systemd_ac_power_CFLAGS = \
756         $(AM_CFLAGS) \
757         $(UDEV_CFLAGS)
758
759 systemd_ac_power_LDADD = \
760         libsystemd-basic.la \
761         $(UDEV_LIBS)
762
763 systemd_cryptsetup_SOURCES = \
764         src/cryptsetup.c \
765         src/ask-password-api.c
766
767 systemd_cryptsetup_CFLAGS = \
768         $(LIBCRYPTSETUP_CFLAGS) \
769         $(AM_CFLAGS)
770
771 systemd_cryptsetup_LDADD = \
772         $(LIBCRYPTSETUP_LIBS) \
773         libsystemd-basic.la
774
775 systemd_cryptsetup_generator_SOURCES = \
776         src/cryptsetup-generator.c \
777         src/unit-name.c
778
779 systemd_cryptsetup_generator_CFLAGS = \
780         $(AM_CFLAGS)
781
782 systemd_cryptsetup_generator_LDADD = \
783         libsystemd-basic.la
784
785 systemd_user_sessions_SOURCES = \
786         src/user-sessions.c \
787         src/cgroup-util.c
788
789 systemd_user_sessions_CFLAGS = \
790         $(AM_CFLAGS)
791
792 systemd_user_sessions_LDADD = \
793         libsystemd-basic.la
794
795 systemd_vconsole_setup_SOURCES = \
796         src/vconsole-setup.c
797
798 systemd_vconsole_setup_CFLAGS = \
799         $(AM_CFLAGS)
800
801 systemd_vconsole_setup_LDADD = \
802         libsystemd-basic.la
803
804 systemd_remount_api_vfs_SOURCES = \
805         src/remount-api-vfs.c \
806         src/mount-setup.c
807
808 systemd_remount_api_vfs_CFLAGS = \
809         $(AM_CFLAGS)
810
811 systemd_remount_api_vfs_LDADD = \
812         libsystemd-basic.la
813
814 systemd_cgroups_agent_SOURCES = \
815         src/cgroups-agent.c \
816         src/dbus-common.c
817
818 systemd_cgroups_agent_CFLAGS = \
819         $(AM_CFLAGS) \
820         $(DBUS_CFLAGS)
821
822 systemd_cgroups_agent_LDADD = \
823         libsystemd-basic.la \
824         $(DBUS_LIBS)
825
826 systemd_kmsg_syslogd_SOURCES = \
827         src/kmsg-syslogd.c \
828         src/sd-daemon.c \
829         src/fdset.c
830
831 systemd_kmsg_syslogd_CFLAGS = \
832         $(AM_CFLAGS)
833
834 systemd_kmsg_syslogd_LDADD = \
835         libsystemd-basic.la
836
837 systemctl_SOURCES = \
838         src/systemctl.c \
839         src/utmp-wtmp.c \
840         src/dbus-common.c \
841         src/path-lookup.c \
842         src/sd-daemon.c \
843         src/cgroup-show.c \
844         src/cgroup-util.c \
845         src/exit-status.c \
846         src/unit-name.c
847
848 systemctl_CFLAGS = \
849         $(AM_CFLAGS) \
850         $(DBUS_CFLAGS)
851
852 systemctl_LDADD = \
853         libsystemd-basic.la \
854         $(DBUS_LIBS)
855
856 systemd_notify_SOURCES = \
857         src/notify.c \
858         src/sd-daemon.c \
859         src/sd-readahead.c
860
861 systemd_notify_LDADD = \
862         libsystemd-basic.la
863
864 systemd_ask_password_SOURCES = \
865         src/ask-password.c \
866         src/ask-password-api.c
867
868 systemd_ask_password_LDADD = \
869         libsystemd-basic.la
870
871 systemd_reply_password_SOURCES = \
872         src/reply-password.c
873
874 systemd_reply_password_LDADD = \
875         libsystemd-basic.la
876
877 systemd_readahead_collect_SOURCES = \
878         src/readahead-collect.c \
879         src/sd-daemon.c \
880         src/readahead-common.c
881
882 systemd_readahead_collect_CFLAGS = \
883         $(UDEV_CFLAGS)
884
885 systemd_readahead_collect_LDADD = \
886         libsystemd-basic.la \
887         $(UDEV_LIBS)
888
889 systemd_readahead_replay_SOURCES = \
890         src/readahead-replay.c \
891         src/sd-daemon.c \
892         src/readahead-common.c
893
894 systemd_readahead_replay_CFLAGS = \
895         $(UDEV_CFLAGS)
896
897 systemd_readahead_replay_LDADD = \
898         libsystemd-basic.la \
899         $(UDEV_LIBS)
900
901 systemd_cgls_SOURCES = \
902         src/cgls.c \
903         src/cgroup-show.c \
904         src/cgroup-util.c
905
906 systemd_cgls_CFLAGS = \
907         $(AM_CFLAGS)
908
909 systemd_cgls_LDADD = \
910         libsystemd-basic.la
911
912 systemadm_SOURCES = \
913         src/systemadm.vala \
914         src/systemd-interfaces.vala
915
916 systemadm_CFLAGS = \
917         $(AM_CFLAGS) \
918         $(DBUSGLIB_CFLAGS) \
919         $(GTK_CFLAGS) \
920         -Wno-unused-variable \
921         -Wno-unused-function \
922         -Wno-shadow \
923         -Wno-format-nonliteral
924
925 systemadm_VALAFLAGS = \
926         --pkg=dbus-glib-1 \
927         --pkg=posix \
928         --pkg=gtk+-2.0 \
929         -g
930
931 systemadm_LDADD = \
932         $(DBUSGLIB_LIBS) \
933         $(GTK_LIBS)
934
935 systemd_gnome_ask_password_agent_SOURCES = \
936         src/gnome-ask-password-agent.vala
937
938 systemd_gnome_ask_password_agent_CFLAGS = \
939         $(AM_CFLAGS) \
940         $(DBUSGLIB_CFLAGS) \
941         $(GTK_CFLAGS) \
942         -Wno-unused-variable \
943         -Wno-unused-function \
944         -Wno-shadow \
945         -Wno-format-nonliteral
946
947 systemd_gnome_ask_password_agent_VALAFLAGS = \
948         --pkg=dbus-glib-1 \
949         --pkg=posix \
950         --pkg=gtk+-2.0 \
951         --pkg=linux \
952         --pkg=gio-unix-2.0 \
953         --pkg=libnotify \
954         -g
955
956 systemd_gnome_ask_password_agent_LDADD = \
957         $(DBUSGLIB_LIBS) \
958         $(GTK_LIBS)
959
960 systemd_tty_ask_password_agent_SOURCES = \
961         src/tty-ask-password-agent.c \
962         src/ask-password-api.c \
963         src/utmp-wtmp.c
964
965 systemd_tty_ask_password_agent_LDADD = \
966         libsystemd-basic.la
967
968 pam_systemd_la_SOURCES = \
969         src/pam-module.c \
970         src/cgroup-util.c \
971         src/sd-daemon.c
972
973 pam_systemd_la_CFLAGS = \
974         $(AM_CFLAGS)
975         -fvisibility=hidden
976
977 pam_systemd_la_LDFLAGS = \
978         -module \
979         -export-dynamic \
980         -avoid-version \
981         -shared \
982         -export-symbols-regex '^pam_sm_.*'
983
984 pam_systemd_la_LIBADD = \
985         libsystemd-basic.la \
986         $(PAM_LIBS)
987
988 SED_PROCESS = \
989         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
990         $(SED)  -e 's,@rootlibexecdir\@,$(rootlibexecdir),g' \
991                 -e 's,@rootbindir\@,$(rootbindir),g' \
992                 -e 's,@SPECIAL_SYSLOG_SERVICE\@,$(SPECIAL_SYSLOG_SERVICE),g' \
993                 -e 's,@SYSTEMCTL\@,$(rootbindir)/systemctl,g' \
994                 -e 's,@SYSTEMD_NOTIFY\@,$(rootbindir)/systemd-notify,g' \
995                 -e 's,@pkgsysconfdir\@,$(pkgsysconfdir),g' \
996                 -e 's,@pkgdatadir\@,$(pkgdatadir),g' \
997                 -e 's,@systemunitdir\@,$(systemunitdir),g' \
998                 -e 's,@PACKAGE_VERSION\@,$(PACKAGE_VERSION),g' \
999                 -e 's,@PACKAGE_NAME\@,$(PACKAGE_NAME),g' \
1000                 -e 's,@PACKAGE_URL\@,$(PACKAGE_URL),g' \
1001                 -e 's,@prefix\@,$(prefix),g' \
1002                 < $< > $@ || rm $@
1003
1004 units/%: units/%.in Makefile
1005         $(SED_PROCESS)
1006
1007 man/%: man/%.in Makefile
1008         $(SED_PROCESS)
1009
1010 %.pc: %.pc.in Makefile
1011         $(SED_PROCESS)
1012
1013 M4_PROCESS_SYSTEM = \
1014         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1015         $(M4) -P $(M4_DISTRO_FLAG) -DFOR_SYSTEM=1 < $< > $@ || rm $@
1016
1017 M4_PROCESS_SESSION = \
1018         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1019         $(M4) -P $(M4_DISTRO_FLAG) -DFOR_SESSION=1 < $< > $@ || rm $@
1020
1021 units/%: units/%.m4 Makefile
1022         $(M4_PROCESS_SYSTEM)
1023
1024 units/session/%: units/%.m4 Makefile
1025         $(M4_PROCESS_SESSION)
1026
1027 CLEANFILES = \
1028         $(nodist_systemunit_DATA) \
1029         $(nodist_sessionunit_DATA) \
1030         $(nodist_man_MANS) \
1031         ${XML_IN_FILES:.xml.in=.html} \
1032         $(pkgconfigdata_DATA)
1033
1034 if HAVE_VALAC
1035 CLEANFILES += \
1036         ${systemadm_SOURCES:.vala=.c}
1037 endif
1038
1039 if HAVE_XSLTPROC
1040 XSLTPROC_FLAGS = \
1041         --nonet \
1042         --param funcsynopsis.style "'ansi'"
1043
1044 XSLTPROC_PROCESS_MAN = \
1045         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1046         $(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
1047
1048 XSLTPROC_PROCESS_MAN_IN = \
1049         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1050         $(XSLTPROC) -o ${@:.in=} $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $< && \
1051         mv ${@:.in=} $@
1052
1053 XSLTPROC_PROCESS_HTML = \
1054         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1055         $(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/xhtml-1_1/docbook.xsl $<
1056
1057 XSLTPROC_PROCESS_HTML_IN = \
1058         $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
1059         $(XSLTPROC) -o ${@:.in=} $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/xhtml-1_1/docbook.xsl $< && \
1060         mv ${@:.in=} $@
1061
1062 man/%.1: man/%.xml
1063         $(XSLTPROC_PROCESS_MAN)
1064
1065 man/%.1.in: man/%.xml.in
1066         $(XSLTPROC_PROCESS_MAN)
1067
1068 man/%.3: man/%.xml
1069         $(XSLTPROC_PROCESS_MAN)
1070
1071 man/%.3.in: man/%.xml.in
1072         $(XSLTPROC_PROCESS_MAN)
1073
1074 man/%.5: man/%.xml
1075         $(XSLTPROC_PROCESS_MAN)
1076
1077 man/%.5.in: man/%.xml.in
1078         $(XSLTPROC_PROCESS_MAN)
1079
1080 man/%.7: man/%.xml
1081         $(XSLTPROC_PROCESS_MAN)
1082
1083 man/%.7.in: man/%.xml.in
1084         $(XSLTPROC_PROCESS_MAN_IN)
1085
1086 man/%.8: man/%.xml
1087         $(XSLTPROC_PROCESS_MAN)
1088
1089 man/%.8.in: man/%.xml.in
1090         $(XSLTPROC_PROCESS_MAN_IN)
1091
1092 man/%.html: man/%.xml
1093         $(XSLTPROC_PROCESS_HTML)
1094
1095 man/%.html.in: man/%.xml.in
1096         $(XSLTPROC_PROCESS_HTML_IN)
1097
1098 CLEANFILES += \
1099         $(dist_man_MANS) \
1100         ${nodist_man_MANS:=.in} \
1101         ${XML_FILES:.xml=.html} \
1102         ${XML_IN_FILES:.xml.in=.html.in}
1103 endif
1104
1105 org.freedesktop.systemd1.%.xml: systemd
1106         $(AM_V_GEN)SYSTEMD_SKIP_API_MOUNTS=1 ./systemd --introspect=${@:.xml=} > $@
1107
1108 CLEANFILES += \
1109         $(dbusinterface_DATA)
1110
1111 install-data-hook:
1112         $(MKDIR_P) -m 0755 \
1113                 $(DESTDIR)$(systemunitdir) \
1114                 $(DESTDIR)$(sessionunitdir) \
1115                 $(DESTDIR)$(systemunitdir)/sysinit.target.wants \
1116                 $(DESTDIR)$(systemunitdir)/sockets.target.wants \
1117                 $(DESTDIR)$(systemunitdir)/basic.target.wants \
1118                 $(DESTDIR)$(systemunitdir)/shutdown.target.wants \
1119                 $(DESTDIR)$(systemunitdir)/local-fs.target.wants \
1120                 $(DESTDIR)$(systemunitdir)/runlevel1.target.wants \
1121                 $(DESTDIR)$(systemunitdir)/runlevel2.target.wants \
1122                 $(DESTDIR)$(systemunitdir)/runlevel3.target.wants \
1123                 $(DESTDIR)$(systemunitdir)/runlevel4.target.wants \
1124                 $(DESTDIR)$(systemunitdir)/runlevel5.target.wants \
1125                 $(DESTDIR)$(systemunitdir)/multi-user.target.wants \
1126                 $(DESTDIR)$(systemunitdir)/graphical.target.wants \
1127                 $(DESTDIR)$(pkgsysconfdir)/system \
1128                 $(DESTDIR)$(pkgsysconfdir)/system/sysinit.target.wants \
1129                 $(DESTDIR)$(pkgsysconfdir)/system/local-fs.target.wants \
1130                 $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants \
1131                 $(DESTDIR)$(pkgsysconfdir)/system/getty.target.wants \
1132                 $(DESTDIR)$(pkgsysconfdir)/session \
1133                 $(DESTDIR)$(sysconfdir)/xdg/systemd
1134         ( cd $(DESTDIR)$(sysconfdir)/xdg/systemd/ && \
1135                 rm -f session && \
1136                 $(LN_S) $(pkgsysconfdir)/session session )
1137         ( cd $(DESTDIR)$(systemunitdir)/sockets.target.wants && \
1138                 rm -f systemd-initctl.socket systemd-logger.socket systemd-shutdownd.socket syslog.socket && \
1139                 $(LN_S) ../systemd-logger.socket systemd-logger.socket && \
1140                 $(LN_S) ../systemd-initctl.socket systemd-initctl.socket && \
1141                 $(LN_S) ../systemd-shutdownd.socket systemd-shutdownd.socket && \
1142                 $(LN_S) ../syslog.socket syslog.socket )
1143         ( cd $(DESTDIR)$(systemunitdir)/runlevel1.target.wants && \
1144                 rm -f systemd-update-utmp-runlevel.service && \
1145                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
1146         ( cd $(DESTDIR)$(systemunitdir)/runlevel2.target.wants && \
1147                 rm -f systemd-update-utmp-runlevel.service && \
1148                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
1149         ( cd $(DESTDIR)$(systemunitdir)/runlevel3.target.wants && \
1150                 rm -f systemd-update-utmp-runlevel.service && \
1151                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
1152         ( cd $(DESTDIR)$(systemunitdir)/runlevel4.target.wants && \
1153                 rm -f systemd-update-utmp-runlevel.service && \
1154                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
1155         ( cd $(DESTDIR)$(systemunitdir)/runlevel5.target.wants && \
1156                 rm -f systemd-update-utmp-runlevel.service && \
1157                 $(LN_S) ../systemd-update-utmp-runlevel.service systemd-update-utmp-runlevel.service )
1158         ( cd $(DESTDIR)$(systemunitdir)/shutdown.target.wants && \
1159                 rm -f systemd-update-utmp-shutdown.service \
1160                         hwclock-save.service \
1161                         systemd-random-seed-save.service && \
1162                 $(LN_S) ../systemd-update-utmp-shutdown.service systemd-update-utmp-shutdown.service && \
1163                 $(LN_S) ../hwclock-save.service hwclock-save.service && \
1164                 $(LN_S) ../systemd-random-seed-save.service systemd-random-seed-save.service )
1165         ( cd $(DESTDIR)$(systemunitdir)/local-fs.target.wants && \
1166                 rm -f systemd-remount-api-vfs.service \
1167                         fsck-root.service \
1168                         remount-rootfs.service \
1169                         var-run.mount \
1170                         var-lock.mount && \
1171                 $(LN_S) ../systemd-remount-api-vfs.service systemd-remount-api-vfs.service && \
1172                 $(LN_S) ../fsck-root.service fsck-root.service && \
1173                 $(LN_S) ../remount-rootfs.service remount-rootfs.service && \
1174                 $(LN_S) ../var-run.mount var-run.mount && \
1175                 $(LN_S) ../var-lock.mount var-lock.mount )
1176         ( cd $(DESTDIR)$(sessionunitdir) && \
1177                 rm -f shutdown.target sockets.target local-fs.target swap.target bluetooth.target printer.target && \
1178                 $(LN_S) $(systemunitdir)/shutdown.target shutdown.target && \
1179                 $(LN_S) $(systemunitdir)/sockets.target sockets.target && \
1180                 $(LN_S) $(systemunitdir)/local-fs.target local-fs.target && \
1181                 $(LN_S) $(systemunitdir)/swap.target swap.target && \
1182                 $(LN_S) $(systemunitdir)/bluetooth.target bluetooth.target && \
1183                 $(LN_S) $(systemunitdir)/printer.target printer.target)
1184         ( cd $(DESTDIR)$(systemunitdir) && \
1185                 rm -f runlevel0.target runlevel1.target runlevel2.target runlevel3.target runlevel4.target runlevel5.target runlevel6.target && \
1186                 $(LN_S) poweroff.target runlevel0.target && \
1187                 $(LN_S) rescue.target runlevel1.target && \
1188                 $(LN_S) multi-user.target runlevel2.target && \
1189                 $(LN_S) multi-user.target runlevel3.target && \
1190                 $(LN_S) multi-user.target runlevel4.target && \
1191                 $(LN_S) graphical.target runlevel5.target && \
1192                 $(LN_S) reboot.target runlevel6.target )
1193         ( cd $(DESTDIR)$(systemunitdir) && \
1194                 rm -f default.target ctrl-alt-del.target && \
1195                 $(LN_S) graphical.target default.target && \
1196                 $(LN_S) reboot.target ctrl-alt-del.target )
1197         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
1198                 rm -f getty.target systemd-user-sessions.service systemd-ask-password-wall.path && \
1199                 $(LN_S) ../getty.target getty.target && \
1200                 $(LN_S) ../systemd-user-sessions.service systemd-user-sessions.service && \
1201                 $(LN_S) ../systemd-ask-password-wall.path systemd-ask-password-wall.path )
1202         ( cd $(DESTDIR)$(pkgsysconfdir)/system/getty.target.wants && \
1203                 rm -f getty@tty1.service getty@tty2.service getty@tty3.service getty@tty4.service getty@tty5.service getty@tty6.service && \
1204                 $(LN_S) $(systemunitdir)/getty@.service getty@tty1.service && \
1205                 $(LN_S) $(systemunitdir)/getty@.service getty@tty2.service && \
1206                 $(LN_S) $(systemunitdir)/getty@.service getty@tty3.service && \
1207                 $(LN_S) $(systemunitdir)/getty@.service getty@tty4.service && \
1208                 $(LN_S) $(systemunitdir)/getty@.service getty@tty5.service && \
1209                 $(LN_S) $(systemunitdir)/getty@.service getty@tty6.service )
1210         ( cd $(DESTDIR)$(pkgsysconfdir)/system/local-fs.target.wants && \
1211                 rm -f quotaon.service quotacheck.service && \
1212                 $(LN_S) $(systemunitdir)/quotacheck.service quotacheck.service && \
1213                 $(LN_S) $(systemunitdir)/quotaon.service quotaon.service )
1214         ( cd $(DESTDIR)$(pkgsysconfdir)/system/multi-user.target.wants && \
1215                 rm -f remote-fs.target && \
1216                 $(LN_S) $(systemunitdir)/remote-fs.target remote-fs.target )
1217         ( cd $(DESTDIR)$(pkgsysconfdir)/system/sysinit.target.wants && \
1218                 rm -f hwclock-load.service && \
1219                 $(LN_S) $(systemunitdir)/hwclock-load.service hwclock-load.service )
1220         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
1221                 rm -f dev-hugepages.automount \
1222                         dev-mqueue.automount \
1223                         proc-sys-fs-binfmt_misc.automount \
1224                         sys-kernel-debug.automount \
1225                         sys-kernel-security.automount \
1226                         systemd-vconsole-setup.service \
1227                         systemd-modules-load.service \
1228                         systemd-random-seed-load.service \
1229                         systemd-tmpfiles-setup.service \
1230                         sysctl.service && \
1231                 $(LN_S) ../dev-hugepages.automount dev-hugepages.automount && \
1232                 $(LN_S) ../dev-mqueue.automount dev-mqueue.automount && \
1233                 $(LN_S) ../proc-sys-fs-binfmt_misc.automount proc-sys-fs-binfmt_misc.automount && \
1234                 $(LN_S) ../sys-kernel-debug.automount sys-kernel-debug.automount && \
1235                 $(LN_S) ../sys-kernel-security.automount sys-kernel-security.automount && \
1236                 $(LN_S) ../systemd-vconsole-setup.service systemd-vconsole-setup.service && \
1237                 $(LN_S) ../systemd-modules-load.service systemd-modules-load.service && \
1238                 $(LN_S) ../systemd-random-seed-load.service systemd-random-seed-load.service && \
1239                 $(LN_S) ../systemd-tmpfiles-setup.service systemd-tmpfiles-setup.service && \
1240                 $(LN_S) ../sysctl.service sysctl.service )
1241         ( cd $(DESTDIR)$(systemunitdir)/basic.target.wants && \
1242                 rm -f systemd-tmpfiles-clean.timer && \
1243                 $(LN_S) ../systemd-tmpfiles-clean.timer systemd-tmpfiles-clean.timer )
1244         ( cd $(DESTDIR)$(dbussessionservicedir) && \
1245                 rm -f org.freedesktop.systemd1.service && \
1246                 $(LN_S) ../system-services/org.freedesktop.systemd1.service org.freedesktop.systemd1.service )
1247 if TARGET_FEDORA
1248         $(MKDIR_P) -m 0755 \
1249                 $(DESTDIR)$(SYSTEM_SYSVINIT_PATH) \
1250                 $(DESTDIR)$(systemunitdir)/reboot.target.wants \
1251                 $(DESTDIR)$(systemunitdir)/kexec.target.wants \
1252                 $(DESTDIR)$(systemunitdir)/poweroff.target.wants \
1253                 $(DESTDIR)$(systemunitdir)/halt.target.wants \
1254                 $(DESTDIR)$(systemunitdir)/final.target.wants
1255         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
1256                 rm -f rc-local.service && \
1257                 $(LN_S) $(systemunitdir)/rc-local.service rc-local.service )
1258         ( cd $(DESTDIR)$(systemunitdir)/final.target.wants && \
1259                 rm -f halt-local.service && \
1260                 $(LN_S) $(systemunitdir)/halt-local.service halt-local.service )
1261         ( cd $(DESTDIR)$(systemunitdir)/sysinit.target.wants && \
1262                 rm -f plymouth-start.service systemd-ask-password-plymouth.path plymouth-read-write.service && \
1263                 $(LN_S) ../plymouth-start.service plymouth-start.service && \
1264                 $(LN_S) ../plymouth-read-write.service plymouth-read-write.service && \
1265                 $(LN_S) ../systemd-ask-password-plymouth.path systemd-ask-password-plymouth.path )
1266         ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
1267                 rm -f plymouth-quit.service  && \
1268                 $(LN_S) ../plymouth-quit.service plymouth-quit.service )
1269         ( cd $(DESTDIR)$(systemunitdir)/reboot.target.wants && \
1270                 rm -f plymouth-reboot.service && \
1271                 $(LN_S) ../plymouth-reboot.service plymouth-reboot.service )
1272         ( cd $(DESTDIR)$(systemunitdir)/kexec.target.wants && \
1273                 rm -f plymouth-kexec.service && \
1274                 $(LN_S) ../plymouth-kexec.service plymouth-kexec.service )
1275         ( cd $(DESTDIR)$(systemunitdir)/poweroff.target.wants && \
1276                 rm -f plymouth-poweroff.service && \
1277                 $(LN_S) ../plymouth-poweroff.service plymouth-poweroff.service )
1278         ( cd $(DESTDIR)$(systemunitdir)/halt.target.wants && \
1279                 rm -f plymouth-halt.service && \
1280                 $(LN_S) ../plymouth-halt.service plymouth-halt.service )
1281         ( cd $(DESTDIR)$(systemunitdir) && \
1282                 rm -f display-manager.service && \
1283                 $(LN_S) prefdm.service display-manager.service )
1284         ( cd $(DESTDIR)$(systemunitdir)/graphical.target.wants && \
1285                 rm -f display-manager.service && \
1286                 $(LN_S) $(systemunitdir)/display-manager.service display-manager.service )
1287 endif
1288 if TARGET_GENTOO
1289         ( cd $(DESTDIR)$(systemunitdir) && \
1290                 rm -f display-manager.service && \
1291                 $(LN_S) xdm.service display-manager.service )
1292         ( cd $(DESTDIR)$(systemunitdir)/graphical.target.wants && \
1293                 rm -f display-manager.service && \
1294                 $(LN_S) $(systemunitdir)/display-manager.service display-manager.service )
1295 endif
1296 if TARGET_DEBIAN_OR_UBUNTU
1297         $(MKDIR_P) -m 0755 \
1298                 $(DESTDIR)$(systemunitdir)/umount.target.wants
1299         ( cd $(DESTDIR)$(systemunitdir)/umount.target.wants && \
1300                 rm -f umountfs.service umountnfs.service umountroot.service && \
1301                 $(LN_S) ../umountfs.service umountfs.service && \
1302                 $(LN_S) ../umountnfs.service umountnfs.service && \
1303                 $(LN_S) ../umountroot.service umountroot.service )
1304         ( cd $(DESTDIR)$(systemunitdir) && \
1305                 rm -f runlevel5.target && \
1306                 $(LN_S) multi-user.target runlevel5.target )
1307 endif
1308
1309 DISTCHECK_CONFIGURE_FLAGS = \
1310         --with-dbuspolicydir=$$dc_install_base/$(dbuspolicydir) \
1311         --with-dbussessionservicedir=$$dc_install_base/$(dbussessionservicedir) \
1312         --with-dbussystemservicedir=$$dc_install_base/$(dbussystemservicedir) \
1313         --with-dbusinterfacedir=$$dc_install_base/$(dbusinterfacedir) \
1314         --with-udevrulesdir=$$dc_install_base/$(udevrulesdir) \
1315         --with-pamlibdir=$$dc_install_base/$(pamlibdir) \
1316         --with-rootdir=$$dc_install_base/$(rootdir)
1317
1318 upload: all distcheck
1319         cp -v systemd-$(VERSION).tar.bz2 /home/lennart/git.fedora/systemd/
1320         scp systemd-$(VERSION).tar.bz2 fdo:/srv/www.freedesktop.org/www/software/systemd/
1321         scp man/*.html tango:public/systemd-man/
1322
1323 git-tag:
1324         git tag "v$(VERSION)" -m "systemd $(VERSION)"
1325
1326 # Opt out from a few services on Fedora for now, as long as rc.sysinit does this job
1327 fedora: install
1328         rm $(DESTDIR)/lib/systemd/system/local-fs.target.wants/var-run.mount
1329         rm $(DESTDIR)/lib/systemd/system/local-fs.target.wants/var-lock.mount