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