Makefile.am 59.7 KB
Newer Older
1
2
#  This file is part of systemd.
#
3
4
#  Copyright 2011 Lennart Poettering
#  Copyright 2011 Kay Sievers
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#
#  systemd is free software; you can redistribute it and/or modify it
#  under the terms of the GNU General Public License as published by
#  the Free Software Foundation; either version 2 of the License, or
#  (at your option) any later version.
#
#  systemd is distributed in the hope that it will be useful, but
#  WITHOUT ANY WARRANTY; without even the implied warranty of
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
#  General Public License for more details.
#
#  You should have received a copy of the GNU General Public License
#  along with systemd; If not, see <http://www.gnu.org/licenses/>.

ACLOCAL_AMFLAGS = -I m4

21
22
SUBDIRS = po

23
LIBSYSTEMD_LOGIN_CURRENT=0
24
LIBSYSTEMD_LOGIN_REVISION=6
25
26
LIBSYSTEMD_LOGIN_AGE=0

27
28
29
30
LIBSYSTEMD_DAEMON_CURRENT=0
LIBSYSTEMD_DAEMON_REVISION=0
LIBSYSTEMD_DAEMON_AGE=0

31
32
33
34
35
36
37
38
LIBSYSTEMD_ID128_CURRENT=0
LIBSYSTEMD_ID128_REVISION=0
LIBSYSTEMD_ID128_AGE=0

LIBSYSTEMD_JOURNAL_CURRENT=0
LIBSYSTEMD_JOURNAL_REVISION=0
LIBSYSTEMD_JOURNAL_AGE=0

39
# Dirs of external packages
40
41
42
43
dbuspolicydir=@dbuspolicydir@
dbussessionservicedir=@dbussessionservicedir@
dbussystemservicedir=@dbussystemservicedir@
dbusinterfacedir=@dbusinterfacedir@
44
udevrulesdir=@udevrulesdir@
45
46
pamlibdir=@pamlibdir@
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
usergeneratordir=$(pkglibexecdir)/user-generators
56
pkgincludedir=$(includedir)/systemd
57
58
59
60
61

# And these are the special ones for /
rootdir=@rootdir@
rootbindir=$(rootdir)/bin
rootlibexecdir=$(rootdir)/lib/systemd
62
63
systemgeneratordir=$(rootlibexecdir)/system-generators
systemshutdowndir=$(rootlibexecdir)/system-shutdown
64
systemunitdir=$(rootdir)/lib/systemd/system
65

66
67
68
69
70
71
72
CLEANFILES =
EXTRA_DIST =
INSTALL_EXEC_HOOKS =
UNINSTALL_EXEC_HOOKS =
INSTALL_DATA_HOOKS =
polkitpolicy_in_files =

73
AM_CPPFLAGS = \
74
	-include $(top_builddir)/config.h \
75
	-DSYSTEM_CONFIG_FILE=\"$(pkgsysconfdir)/system.conf\" \
76
	-DSYSTEM_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/system\" \
77
	-DSYSTEM_DATA_UNIT_PATH=\"$(systemunitdir)\" \
78
	-DSYSTEM_SYSVINIT_PATH=\"$(SYSTEM_SYSVINIT_PATH)\" \
79
	-DSYSTEM_SYSVRCND_PATH=\"$(SYSTEM_SYSVRCND_PATH)\" \
80
81
82
	-DUSER_CONFIG_FILE=\"$(pkgsysconfdir)/user.conf\" \
	-DUSER_CONFIG_UNIT_PATH=\"$(pkgsysconfdir)/user\" \
	-DUSER_DATA_UNIT_PATH=\"$(userunitdir)\" \
83
	-DSYSTEMD_CGROUP_AGENT_PATH=\"$(rootlibexecdir)/systemd-cgroups-agent\" \
84
	-DSYSTEMD_BINARY_PATH=\"$(rootbindir)/systemd\" \
85
	-DSYSTEMD_SHUTDOWN_BINARY_PATH=\"$(rootlibexecdir)/systemd-shutdown\" \
86
	-DSYSTEMCTL_BINARY_PATH=\"$(rootbindir)/systemctl\" \
87
	-DSYSTEMD_TTY_ASK_PASSWORD_AGENT_BINARY_PATH=\"$(rootbindir)/systemd-tty-ask-password-agent\" \
88
	-DSYSTEMD_STDIO_BRIDGE_BINARY_PATH=\"$(bindir)/systemd-stdio-bridge\" \
89
	-DRUNTIME_DIR=\"/run\" \
90
	-DRANDOM_SEED=\"$(localstatedir)/lib/random-seed\" \
91
	-DSYSTEMD_CRYPTSETUP_PATH=\"$(rootlibexecdir)/systemd-cryptsetup\" \
92
	-DSYSTEM_GENERATOR_PATH=\"$(systemgeneratordir)\" \
93
	-DUSER_GENERATOR_PATH=\"$(usergeneratordir)\" \
94
	-DSYSTEM_SHUTDOWN_PATH=\"$(systemshutdowndir)\" \
95
	-DSYSTEMD_KBD_MODEL_MAP=\"$(pkgdatadir)/kbd-model-map\" \
96
	-I $(top_srcdir)/src
97

98
99
100
101
102
103
if TARGET_GENTOO
AM_CPPFLAGS += \
	-DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
	-DKBD_SETFONT=\"/usr/bin/setfont\" \
	-DDEFAULT_FONT=\"LatArCyrHeb-16\"
else
104
105
106
107
108
109
if TARGET_ARCH
AM_CPPFLAGS += \
	-DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
	-DKBD_SETFONT=\"/usr/bin/setfont\" \
	-DDEFAULT_FONT=\"LatArCyrHeb-16\"
else
110
111
112
113
114
115
if TARGET_FRUGALWARE
AM_CPPFLAGS += \
	-DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
	-DKBD_SETFONT=\"/usr/bin/setfont\" \
	-DDEFAULT_FONT=\"LatArCyrHeb-16\"
else
116
117
118
119
120
121
if TARGET_MANDRIVA
AM_CPPFLAGS += \
	-DKBD_LOADKEYS=\"/bin/loadkeys\" \
	-DKBD_SETFONT=\"/bin/setfont\" \
	-DDEFAULT_FONT=\"LatArCyrHeb-16\"
else
Chris E Ferron's avatar
Chris E Ferron committed
122
123
124
125
126
127
if TARGET_MEEGO
AM_CPPFLAGS += \
	-DKBD_LOADKEYS=\"/bin/loadkeys\" \
	-DKBD_SETFONT=\"/bin/setfont\" \
	-DDEFAULT_FONT=\"LatArCyrHeb-16\"
else
Koen Kooi's avatar
Koen Kooi committed
128
129
130
131
132
133
if TARGET_ANGSTROM
AM_CPPFLAGS += \
	-DKBD_LOADKEYS=\"/usr/bin/loadkeys\" \
	-DKBD_SETFONT=\"/usr/bin/setfont\" \
	-DDEFAULT_FONT=\"LatArCyrHeb-16\"
else
134
135
136
137
AM_CPPFLAGS += \
	-DKBD_LOADKEYS=\"/bin/loadkeys\" \
	-DKBD_SETFONT=\"/bin/setfont\" \
	-DDEFAULT_FONT=\"latarcyrheb-sun16\"
Dexter Morgan's avatar
Dexter Morgan committed
138
139
140
141
142
143
144
else
if TARGET_MAGEIA
AM_CPPFLAGS += \
	-DKBD_LOADKEYS=\"/bin/loadkeys\" \
	-DKBD_SETFONT=\"/bin/setfont\" \
	-DDEFAULT_FONT=\"LatArCyrHeb-16\"
endif
145
endif
146
endif
147
endif
148
endif
Chris E Ferron's avatar
Chris E Ferron committed
149
endif
Koen Kooi's avatar
Koen Kooi committed
150
endif
151

152
rootbin_PROGRAMS = \
153
	systemd \
154
	systemctl \
155
	systemd-notify \
156
	systemd-ask-password \
157
	systemd-tty-ask-password-agent \
158
	systemd-tmpfiles \
Kay Sievers's avatar
Kay Sievers committed
159
	systemd-machine-id-setup
160

161
bin_PROGRAMS = \
162
	systemd-cgls \
163
	systemd-stdio-bridge \
164
	systemd-nspawn
165

166
dist_bin_SCRIPTS = \
167
	src/systemd-analyze
168

169
170
if HAVE_GTK
bin_PROGRAMS += \
171
	systemadm \
172
	systemd-gnome-ask-password-agent
173
endif
174

175
rootlibexec_PROGRAMS = \
176
	systemd-stdout-syslog-bridge \
177
	systemd-cgroups-agent \
178
	systemd-initctl \
179
	systemd-update-utmp \
180
	systemd-random-seed \
181
	systemd-shutdownd \
182
	systemd-shutdown \
183
	systemd-modules-load \
184
	systemd-remount-api-vfs \
185
	systemd-kmsg-syslogd \
186
	systemd-vconsole-setup \
187
188
	systemd-reply-password \
	systemd-readahead-collect \
189
	systemd-readahead-replay \
190
191
	systemd-user-sessions \
	systemd-fsck \
192
	systemd-quotacheck \
193
	systemd-timestamp \
194
	systemd-ac-power \
195
	systemd-detect-virt \
Kay Sievers's avatar
Kay Sievers committed
196
	systemd-sysctl
197

198
systemgenerator_PROGRAMS = \
199
	systemd-getty-generator
200

201
202
203
204
if HAVE_LIBCRYPTSETUP
rootlibexec_PROGRAMS += \
	systemd-cryptsetup

205
systemgenerator_PROGRAMS += \
206
	systemd-cryptsetup-generator
207
endif
208

209
lib_LTLIBRARIES = \
210
	libsystemd-daemon.la
211
212

pkginclude_HEADERS = \
213
	src/sd-daemon.h
214

215
216
noinst_PROGRAMS = \
	test-engine \
217
	test-job-type \
218
	test-ns \
219
	test-loopback \
220
	test-hostname \
221
	test-daemon \
222
	test-cgroup \
223
	test-env-replace \
224
	test-strv \
225
	test-install
226

227
dist_pkgsysconf_DATA = \
228
	src/system.conf \
229
	src/user.conf
230

231
dist_dbuspolicy_DATA = \
232
	src/org.freedesktop.systemd1.conf
233

234
dist_dbussystemservice_DATA = \
235
	src/org.freedesktop.systemd1.service
236

237
dist_udevrules_DATA = \
238
	src/71-seat.rules
239

240
nodist_udevrules_DATA = \
241
242
	src/73-seat-late.rules \
	src/99-systemd.rules
243

244
dbusinterface_DATA = \
245
246
247
248
249
	org.freedesktop.systemd1.Manager.xml \
	org.freedesktop.systemd1.Job.xml \
	org.freedesktop.systemd1.Unit.xml \
	org.freedesktop.systemd1.Service.xml \
	org.freedesktop.systemd1.Socket.xml \
250
	org.freedesktop.systemd1.Timer.xml \
251
252
253
254
255
	org.freedesktop.systemd1.Target.xml \
	org.freedesktop.systemd1.Device.xml \
	org.freedesktop.systemd1.Mount.xml \
	org.freedesktop.systemd1.Automount.xml \
	org.freedesktop.systemd1.Snapshot.xml \
256
	org.freedesktop.systemd1.Swap.xml \
257
	org.freedesktop.systemd1.Path.xml
258

259
dist_bashcompletion_DATA = \
260
	src/systemd-bash-completion.sh
261

262
263
dist_tmpfiles_DATA = \
	tmpfiles.d/systemd.conf \
264
	tmpfiles.d/tmp.conf \
265
266
	tmpfiles.d/x11.conf

267
268
if HAVE_SYSV_COMPAT
dist_tmpfiles_DATA += \
269
	tmpfiles.d/legacy.conf
270
271
endif

272
dist_systemunit_DATA = \
273
274
	units/graphical.target \
	units/multi-user.target \
275
	units/emergency.service \
276
	units/emergency.target \
277
	units/sysinit.target \
278
	units/basic.target \
279
280
	units/getty.target \
	units/halt.target \
281
	units/kexec.target \
282
	units/local-fs.target \
283
	units/local-fs-pre.target \
Lennart Poettering's avatar
Lennart Poettering committed
284
	units/remote-fs.target \
285
	units/remote-fs-pre.target \
286
	units/cryptsetup.target \
287
288
	units/network.target \
	units/nss-lookup.target \
289
	units/mail-transfer-agent.target \
290
	units/http-daemon.target \
291
292
293
	units/poweroff.target \
	units/reboot.target \
	units/rescue.target \
294
	units/rpcbind.target \
295
	units/time-sync.target \
296
	units/shutdown.target \
297
	units/final.target \
298
	units/umount.target \
299
300
301
	units/sigpwr.target \
	units/sockets.target \
	units/swap.target \
302
	units/systemd-initctl.socket \
303
	units/systemd-stdout-syslog-bridge.socket \
304
	units/systemd-shutdownd.socket \
305
	units/syslog.socket \
306
307
	units/dev-hugepages.mount \
	units/dev-mqueue.mount \
308
	units/sys-kernel-config.mount \
309
	units/sys-kernel-debug.mount \
310
	units/sys-kernel-security.mount \
311
	units/sys-fs-fuse-connections.mount \
312
	units/var-run.mount \
313
	units/media.mount \
314
	units/remount-rootfs.service \
315
	units/printer.target \
316
	units/sound.target \
317
	units/bluetooth.target \
Kay Sievers's avatar
Kay Sievers committed
318
	units/smartcard.target \
319
	units/systemd-readahead-done.timer \
320
	units/systemd-tmpfiles-clean.timer \
321
	units/quotaon.service \
322
	units/systemd-ask-password-wall.path \
323
	units/systemd-ask-password-console.path \
Kay Sievers's avatar
Kay Sievers committed
324
	units/syslog.target
325

326
327
328
329
330
if HAVE_SYSV_COMPAT
dist_systemunit_DATA += \
	units/var-lock.mount
endif

331
nodist_systemunit_DATA = \
332
	units/getty@.service \
333
	units/serial-getty@.service \
334
	units/console-shell.service \
335
	units/systemd-initctl.service \
336
	units/systemd-stdout-syslog-bridge.service \
337
	units/systemd-shutdownd.service \
338
	units/systemd-kmsg-syslogd.service \
339
	units/systemd-modules-load.service \
340
	units/systemd-vconsole-setup.service \
341
	units/systemd-remount-api-vfs.service \
342
343
	units/systemd-update-utmp-runlevel.service \
	units/systemd-update-utmp-shutdown.service \
344
345
	units/systemd-random-seed-save.service \
	units/systemd-random-seed-load.service \
346
347
	units/systemd-readahead-collect.service \
	units/systemd-readahead-replay.service \
348
	units/systemd-readahead-done.service \
349
350
	units/systemd-tmpfiles-setup.service \
	units/systemd-tmpfiles-clean.service \
351
	units/systemd-user-sessions.service \
352
	units/systemd-ask-password-wall.service \
353
	units/systemd-ask-password-console.service \
354
	units/systemd-sysctl.service \
355
356
357
	units/halt.service \
	units/poweroff.service \
	units/reboot.service \
358
359
	units/kexec.service \
	units/fsck@.service \
360
	units/fsck-root.service \
361
	units/quotacheck.service \
362
	units/rescue.service \
363
	units/user@.service
364

365
366
367
dist_userunit_DATA = \
	units/user/default.target \
	units/user/exit.target
368

369
370
nodist_userunit_DATA = \
	units/user/exit.service
371

372
EXTRA_DIST += \
373
	units/getty@.service.m4 \
374
	units/serial-getty@.service.m4 \
375
	units/console-shell.service.m4 \
376
	units/rescue.service.m4 \
377
	units/systemd-initctl.service.in \
378
	units/systemd-stdout-syslog-bridge.service.in \
379
	units/systemd-shutdownd.service.in \
380
	units/systemd-kmsg-syslogd.service.in \
381
	units/systemd-modules-load.service.in \
382
	units/systemd-vconsole-setup.service.in \
383
	units/systemd-remount-api-vfs.service.in \
384
385
	units/systemd-update-utmp-runlevel.service.in \
	units/systemd-update-utmp-shutdown.service.in \
386
387
	units/systemd-random-seed-save.service.in \
	units/systemd-random-seed-load.service.in \
388
389
	units/systemd-readahead-collect.service.in \
	units/systemd-readahead-replay.service.in \
390
	units/systemd-readahead-done.service.in \
391
392
	units/systemd-tmpfiles-setup.service.in \
	units/systemd-tmpfiles-clean.service.in \
393
	units/systemd-user-sessions.service.in \
394
	units/systemd-ask-password-wall.service.in \
395
	units/systemd-ask-password-console.service.in \
396
	units/systemd-sysctl.service.in \
397
398
399
	units/halt.service.in \
	units/poweroff.service.in \
	units/reboot.service.in \
400
	units/kexec.service.in \
401
	units/user/exit.service.in \
402
403
	units/fsck@.service.in \
	units/fsck-root.service.in \
404
	units/quotacheck.service.in \
Kay Sievers's avatar
Kay Sievers committed
405
	units/user@.service.in \
406
	systemd.pc.in \
Kay Sievers's avatar
Kay Sievers committed
407
408
	libsystemd-daemon.pc.in \
	src/libsystemd-daemon.sym \
409
	introspect.awk \
410
	src/73-seat-late.rules.in \
411
412
	src/99-systemd.rules.in \
	man/custom-html.xsl
413

414
415
416
417
if TARGET_FEDORA
dist_systemunit_DATA += \
	units/fedora/prefdm.service \
	units/fedora/rc-local.service \
418
	units/fedora/halt-local.service
419
420
systemgenerator_PROGRAMS += \
	systemd-rc-local-generator
421
422
endif

423
424
425
426
427
if TARGET_MANDRIVA
dist_systemunit_DATA += \
	units/mandriva/prefdm.service \
	units/fedora/rc-local.service \
	units/fedora/halt-local.service
428
429
systemgenerator_PROGRAMS += \
	systemd-rc-local-generator
430
431
endif

432
433
434
435
436
if TARGET_FRUGALWARE
dist_systemunit_DATA += \
	units/frugalware/display-manager.service
endif

437
438
439
440
if TARGET_SUSE
dist_systemunit_DATA += \
	units/suse/rc-local.service \
	units/suse/halt-local.service
441
442
systemgenerator_PROGRAMS += \
	systemd-rc-local-generator
443
444
endif

Dexter Morgan's avatar
Dexter Morgan committed
445
446
447
448
449
if TARGET_MAGEIA
dist_systemunit_DATA += \
	units/mageia/prefdm.service \
	units/fedora/rc-local.service \
	units/fedora/halt-local.service
450
451
systemgenerator_PROGRAMS += \
	systemd-rc-local-generator
Dexter Morgan's avatar
Dexter Morgan committed
452
453
endif

454
455
456
457
458
if HAVE_PLYMOUTH
dist_systemunit_DATA += \
	units/plymouth-start.service \
	units/plymouth-read-write.service \
	units/plymouth-quit.service \
459
	units/plymouth-quit-wait.service \
460
461
462
	units/plymouth-reboot.service \
	units/plymouth-kexec.service \
	units/plymouth-poweroff.service \
463
464
465
466
467
468
469
470
	units/plymouth-halt.service \
	units/systemd-ask-password-plymouth.path

nodist_systemunit_DATA += \
	units/systemd-ask-password-plymouth.service

EXTRA_DIST += \
	units/systemd-ask-password-plymouth.service.in
471
472
endif

473
474
dist_doc_DATA = \
	README \
475
476
	LICENSE \
	DISTRO_PORTING \
477
	src/sd-daemon.h \
478
479
480
	src/sd-daemon.c \
	src/sd-readahead.h \
	src/sd-readahead.c
481

482
pkgconfigdata_DATA = \
483
484
485
	systemd.pc

pkgconfiglib_DATA = \
486
	libsystemd-daemon.pc
487

488
489
490
491
492
# First passed through sed, followed by intltool
polkitpolicy_in_in_files = \
	src/org.freedesktop.systemd1.policy.in.in

nodist_polkitpolicy_DATA = \
493
494
	$(polkitpolicy_in_files:.policy.in=.policy) \
	$(polkitpolicy_in_in_files:.policy.in.in=.policy)
495
496

EXTRA_DIST += \
497
498
	$(polkitpolicy_in_files) \
	$(polkitpolicy_in_in_files)
499

500
@INTLTOOL_POLICY_RULE@
501

502
503
noinst_LTLIBRARIES = \
	libsystemd-basic.la \
504
	libsystemd-core.la
505
506

libsystemd_basic_la_SOURCES = \
507
	src/util.c \
508
	src/virt.c \
509
	src/label.c \
510
511
512
513
514
515
	src/hashmap.c \
	src/set.c \
	src/strv.c \
	src/conf-parser.c \
	src/socket-util.c \
	src/log.c \
516
517
	src/ratelimit.c \
	src/exit-status.c
518

519
520
521
522
523
libsystemd_basic_la_CFLAGS = \
	$(AM_CFLAGS) \
	$(SELINUX_CFLAGS)

libsystemd_basic_la_LIBADD = \
524
525
	$(SELINUX_LIBS) \
	$(CAP_LIBS)
526

527
libsystemd_core_la_SOURCES = \
528
	src/unit.c \
529
530
	src/job.c \
	src/manager.c \
531
	src/path-lookup.c \
532
533
534
535
536
537
538
539
540
541
	src/load-fragment.c \
	src/service.c \
	src/automount.c \
	src/mount.c \
	src/swap.c \
	src/device.c \
	src/target.c \
	src/snapshot.c \
	src/socket.c \
	src/timer.c \
542
	src/path.c \
543
544
	src/load-dropin.c \
	src/execute.c \
545
	src/utmp-wtmp.c \
546
547
548
549
	src/dbus.c \
	src/dbus-manager.c \
	src/dbus-unit.c \
	src/dbus-job.c \
550
551
	src/dbus-service.c \
	src/dbus-socket.c \
552
	src/dbus-timer.c \
553
554
555
556
557
558
559
	src/dbus-target.c \
	src/dbus-mount.c \
	src/dbus-automount.c \
	src/dbus-swap.c \
	src/dbus-snapshot.c \
	src/dbus-device.c \
	src/dbus-execute.c \
560
	src/dbus-path.c \
561
562
563
	src/cgroup.c \
	src/mount-setup.c \
	src/hostname-setup.c \
564
	src/selinux-setup.c \
565
	src/loopback-setup.c \
566
	src/kmod-setup.c \
567
	src/locale-setup.c \
568
	src/machine-id-setup.c \
569
570
571
	src/specifier.c \
	src/unit-name.c \
	src/fdset.c \
572
	src/namespace.c \
573
	src/tcpwrap.c \
574
	src/cgroup-util.c \
575
	src/condition.c \
576
577
578
579
580
	src/dbus-common.c \
	src/sd-daemon.c \
	src/install.c \
	src/cgroup-attr.c \
	src/sd-id128.c
581

582
nodist_libsystemd_core_la_SOURCES = \
583
584
	src/load-fragment-gperf.c \
	src/load-fragment-gperf-nulstr.c
585

586
EXTRA_DIST += \
587
	src/load-fragment-gperf.gperf.m4
588

589
590
591
libsystemd_core_la_CFLAGS = \
	$(AM_CFLAGS) \
	$(DBUS_CFLAGS) \
592
593
594
595
	$(UDEV_CFLAGS) \
	$(LIBWRAP_CFLAGS) \
	$(PAM_CFLAGS) \
	$(AUDIT_CFLAGS)
596
597
598
599
600
601

libsystemd_core_la_LIBADD = \
	libsystemd-basic.la \
	$(DBUS_LIBS) \
	$(UDEV_LIBS) \
	$(LIBWRAP_LIBS) \
602
	$(PAM_LIBS) \
603
604
	$(AUDIT_LIBS) \
	$(CAP_LIBS)
605

606
607
608
609
# This is needed because automake is buggy in how it generates the
# rules for C programs, but not Vala programs.  We therefore can't
# list the .h files as dependencies if we want make dist to work.

610
EXTRA_DIST += \
611
612
	${libsystemd_basic_la_SOURCES:.c=.h} \
	${libsystemd_core_la_SOURCES:.c=.h} \
613
	${libsystemd_daemon_la_SOURCES:.c=.h} \
614
	src/macro.h \
615
	src/def.h \
616
617
618
619
620
	src/ioprio.h \
	src/missing.h \
	src/list.h \
	src/securebits.h \
	src/linux/auto_dev-ioctl.h \
621
	src/linux/fanotify.h \
622
	src/initreq.h \
623
	src/sd-readahead.h \
624
	src/special.h \
625
	src/dbus-common.h \
626
	src/bus-errors.h \
627
	src/cgroup-show.h \
628
	src/build.h \
629
	src/shutdownd.h \
630
	src/umount.h \
631
	src/readahead-common.h \
632
	src/ask-password-api.h \
633
634
635
636
637
638
	src/pager.h \
	src/sysfs-show.h \
	src/polkit.h \
	src/dbus-loop.h \
	src/spawn-agent.h \
	src/acl-util.h
639
640

MANPAGES = \
Lennart Poettering's avatar
Lennart Poettering committed
641
	man/systemd.1 \
642
643
	man/systemctl.1 \
	man/systemadm.1 \
644
	man/systemd-cgls.1 \
645
	man/systemd-nspawn.1 \
646
	man/systemd-tmpfiles.8 \
647
	man/systemd-notify.1 \
648
	man/sd_notify.3 \
649
	man/sd_readahead.3 \
650
651
652
	man/sd_booted.3 \
	man/sd_listen_fds.3 \
	man/sd_is_fifo.3 \
653
654
	man/systemd.unit.5 \
	man/systemd.service.5 \
655
	man/systemd.socket.5 \
Lennart Poettering's avatar
Lennart Poettering committed
656
	man/systemd.mount.5 \
657
	man/systemd.automount.5 \
Lennart Poettering's avatar
Lennart Poettering committed
658
	man/systemd.swap.5 \
Lennart Poettering's avatar
Lennart Poettering committed
659
	man/systemd.timer.5 \
Lennart Poettering's avatar
Lennart Poettering committed
660
	man/systemd.path.5 \
661
	man/systemd.target.5 \
662
	man/systemd.device.5 \
663
	man/systemd.snapshot.5 \
664
	man/systemd.exec.5 \
665
	man/daemon.7 \
666
	man/sd-daemon.7 \
667
	man/sd-readahead.7 \
668
	man/runlevel.8 \
Lennart Poettering's avatar
Lennart Poettering committed
669
670
671
	man/telinit.8 \
	man/halt.8 \
	man/shutdown.8 \
672
	man/pam_systemd.8 \
673
	man/systemd.conf.5 \
674
	man/tmpfiles.d.5 \
675
	man/hostname.5 \
676
	man/timezone.5 \
677
	man/machine-id.5 \
Lennart Poettering's avatar
Lennart Poettering committed
678
	man/vconsole.conf.5 \
679
	man/locale.conf.5 \
680
	man/os-release.5 \
681
	man/machine-info.5 \
682
	man/modules-load.d.5 \
683
	man/sysctl.d.5 \
684
685
686
687
688
	man/systemd-ask-password.1 \
	man/sd_pid_get_session.3 \
	man/sd_uid_get_state.3 \
	man/sd_session_is_active.3 \
	man/sd_seat_get_active.3 \
689
	man/sd_get_seats.3
690
691
692
693
694
695
696

MANPAGES_ALIAS = \
	man/reboot.8 \
	man/poweroff.8 \
	man/sd_is_socket.3 \
	man/sd_is_socket_unix.3 \
	man/sd_is_socket_inet.3 \
Lennart Poettering's avatar
Lennart Poettering committed
697
	man/sd_is_mq.3 \
698
	man/sd_notifyf.3 \
Lennart Poettering's avatar
Lennart Poettering committed
699
	man/init.1 \
700
701
702
703
704
705
706
707
708
	man/sd_session_get_uid.3 \
	man/sd_session_get_seat.3 \
	man/sd_pid_get_owner_uid.3 \
	man/sd_uid_is_on_seat.3 \
	man/sd_uid_get_sessions.3 \
	man/sd_uid_get_seats.3 \
	man/sd_seat_get_sessions.3 \
	man/sd_seat_can_multi_session.3 \
	man/sd_get_sessions.3 \
709
	man/sd_get_uids.3
710
711
712
713
714
715

man/reboot.8: man/halt.8
man/poweroff.8: man/halt.8
man/sd_is_socket.3: man/sd_is_fifo.3
man/sd_is_socket_unix.3: man/sd_is_fifo.3
man/sd_is_socket_inet.3: man/sd_is_fifo.3
716
man/sd_is_mq.3: man/sd_is_fifo.3
717
718
man/sd_notifyf.3: man/sd_notify.3
man/init.1: man/systemd.1
719
720
721
722
723
724
725
726
727
728
man/sd_session_get_uid.3: man/sd_session_is_active.3
man/sd_session_get_seat.3: man/sd_session_is_active.3
man/sd_pid_get_owner_uid.3: man/sd_pid_get_session.3
man/sd_uid_is_on_seat.3: man/sd_uid_get_state.3
man/sd_uid_get_sessions.3: man/sd_uid_get_state.3
man/sd_uid_get_seats.3: man/sd_uid_get_state.3
man/sd_seat_get_sessions.3: man/sd_seat_get_active.3
man/sd_seat_can_multi_session.3: man/sd_seat_get_active.3
man/sd_get_sessions.3: man/sd_get_seats.3
man/sd_get_uids.3: man/sd_get_seats.3
729
730
731
732

dist_man_MANS = \
	$(MANPAGES) \
	$(MANPAGES_ALIAS)
733
734

nodist_man_MANS = \
735
	man/systemd.special.7
736

737
738
739
740
741
742
XML_FILES = \
	${patsubst %.1,%.xml,${patsubst %.3,%.xml,${patsubst %.5,%.xml,${patsubst %.7,%.xml,${patsubst %.8,%.xml,$(MANPAGES)}}}}}

XML_IN_FILES = \
	${patsubst %.1,%.xml.in,${patsubst %.3,%.xml.in,${patsubst %.5,%.xml.in,${patsubst %.7,%.xml.in,${patsubst %.8,%.xml.in,$(nodist_man_MANS)}}}}}

743
dist_noinst_DATA = \
744
	${XML_FILES:.xml=.html}
745

746
nodist_noinst_DATA = \
747
	${XML_IN_FILES:.xml.in=.html}
748
749

EXTRA_DIST += \
750
751
752
753
	$(XML_FILES) \
	$(XML_IN_FILES) \
	${nodist_man_MANS:=.in} \
	${XML_IN_FILES:.xml.in=.html.in}
754

755
systemd_SOURCES = \
756
	src/main.c
757

758
759
systemd_CFLAGS = \
	$(AM_CFLAGS) \
760
	$(DBUS_CFLAGS) \
761
	$(UDEV_CFLAGS)
762
763

systemd_LDADD = \
764
	libsystemd-core.la
765
766

test_engine_SOURCES = \
767
	src/test-engine.c
768

769
test_engine_CFLAGS = $(systemd_CFLAGS)
770
771
772
test_engine_LDADD = $(systemd_LDADD)

test_job_type_SOURCES = \
773
	src/test-job-type.c
774

775
test_job_type_CFLAGS = $(systemd_CFLAGS)
776
777
test_job_type_LDADD = $(systemd_LDADD)

778
test_ns_SOURCES = \
779
	src/test-ns.c
780

781
test_ns_CFLAGS = $(systemd_CFLAGS)
782
783
test_ns_LDADD = $(systemd_LDADD)

784
test_loopback_SOURCES = \
785
786
	src/test-loopback.c \
	src/loopback-setup.c
787

788
789
790
test_loopback_LDADD = \
	libsystemd-basic.la

791
792
793
794
795
796
797
test_hostname_SOURCES = \
	src/test-hostname.c \
	src/hostname-setup.c

test_hostname_LDADD = \
	libsystemd-basic.la

798
test_daemon_SOURCES = \
799
	src/test-daemon.c
800

801
test_daemon_LDADD = \
802
803
	libsystemd-basic.la \
	libsystemd-daemon.la
804

805
806
807
808
809
test_cgroup_SOURCES = \
	src/test-cgroup.c \
	src/cgroup-util.c

test_cgroup_CFLAGS = \
810
	$(AM_CFLAGS)
811
812

test_cgroup_LDADD = \
813
	libsystemd-basic.la
814

815
816
817
818
819
820
821
822
823
test_env_replace_SOURCES = \
	src/test-env-replace.c

test_env_replace_CFLAGS = \
	$(AM_CFLAGS)

test_env_replace_LDADD = \
	libsystemd-basic.la

824
test_strv_SOURCES = \
825
	src/test-strv.c \
Lennart Poettering's avatar
Lennart Poettering committed
826
	src/specifier.c
827
828
829
830
831
832
833

test_strv_CFLAGS = \
	$(AM_CFLAGS)

test_strv_LDADD = \
	libsystemd-basic.la

834
835
test_install_SOURCES = \
	src/test-install.c \
836
837
838
	src/install.c \
	src/path-lookup.c \
	src/unit-name.c
839
840
841

test_install_CFLAGS = \
	$(AM_CFLAGS) \
842
	$(DBUS_CFLAGS)
843
844
845
846

test_install_LDADD = \
	libsystemd-basic.la

Kay Sievers's avatar
Kay Sievers committed
847
848
849
systemd_stdout_syslog_bridge_SOURCES = \
	src/stdout-syslog-bridge.c \
	src/tcpwrap.c
850

Kay Sievers's avatar
Kay Sievers committed
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
systemd_stdout_syslog_bridge_LDADD = \
	libsystemd-basic.la \
	libsystemd-daemon.la \
	$(LIBWRAP_LIBS)

systemd_initctl_SOURCES = \
	src/initctl.c \
	src/dbus-common.c

systemd_initctl_CFLAGS = \
	$(AM_CFLAGS) \
	$(DBUS_CFLAGS)

systemd_initctl_LDADD = \
	libsystemd-basic.la \
	libsystemd-daemon.la \
	$(DBUS_LIBS)

systemd_update_utmp_SOURCES = \
	src/update-utmp.c \
	src/dbus-common.c \
	src/utmp-wtmp.c

systemd_update_utmp_CFLAGS = \
	$(AM_CFLAGS) \
	$(DBUS_CFLAGS) \
	$(AUDIT_CFLAGS)

systemd_update_utmp_LDADD = \
	libsystemd-basic.la \
	$(DBUS_LIBS) \
	$(AUDIT_LIBS)

systemd_random_seed_SOURCES = \
	src/random-seed.c

systemd_random_seed_CFLAGS = \
888
889
	$(AM_CFLAGS)

Kay Sievers's avatar
Kay Sievers committed
890
systemd_random_seed_LDADD = \
891
892
	libsystemd-basic.la

Kay Sievers's avatar
Kay Sievers committed
893
894
895
systemd_shutdownd_SOURCES = \
	src/utmp-wtmp.c \
	src/shutdownd.c
896

Kay Sievers's avatar
Kay Sievers committed
897
898
899
900
901
902
903
904
905
906
907
908
909
systemd_shutdownd_CFLAGS = \
	$(AM_CFLAGS)

systemd_shutdownd_LDADD = \
	libsystemd-basic.la \
	libsystemd-daemon.la

dist_pkgdata_DATA = \
	src/kbd-model-map

dist_noinst_SCRIPT = \
	src/generate-kbd-model-map

910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
# ------------------------------------------------------------------------------
libsystemd_id128_la_SOURCES = \
	src/sd-id128.c

libsystemd_id128_la_CFLAGS = \
	$(AM_CFLAGS) \
	-fvisibility=hidden

libsystemd_id128_la_LDFLAGS = \
	-shared \
	-version-info $(LIBSYSTEMD_ID128_CURRENT):$(LIBSYSTEMD_ID128_REVISION):$(LIBSYSTEMD_ID128_AGE) \
	-Wl,--version-script=$(top_srcdir)/src/libsystemd-id128.sym

libsystemd_id128_la_LIBADD = \
	libsystemd-basic.la

test_id128_SOURCES = \
	src/test-id128.c \
	src/sd-id128.c

test_id128_CFLAGS = \
	$(AM_CFLAGS)

test_id128_LDADD = \
	libsystemd-basic.la

noinst_PROGRAMS += \
	test-id128

pkginclude_HEADERS += \
	src/sd-id128.h

lib_LTLIBRARIES += \
	libsystemd-id128.la

pkgconfiglib_DATA += \
	libsystemd-id128.pc

# move lib from $(libdir) to $(rootlibdir) and update devel link, if needed
libsystemd-id128-install-hook:
	if test "$(libdir)" != "$(rootlibdir)"; then \
		mkdir -p $(DESTDIR)$(rootlibdir) && \
		so_img_name=$$(readlink $(DESTDIR)$(libdir)/libsystemd-id128.so) && \
		so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \
		ln -sf $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/libsystemd-id128.so && \
		mv $(DESTDIR)$(libdir)/libsystemd-id128.so.* $(DESTDIR)$(rootlibdir); \
	fi

INSTALL_EXEC_HOOKS += \
	libsystemd-id128-install-hook

libsystemd-id128-uninstall-hook:
	rm -f $(DESTDIR)$(rootlibdir)/libsystemd-id128.so*

UNINSTALL_EXEC_HOOKS += \
	libsystemd-id128-uninstall-hook

EXTRA_DIST += \
	libsystemd-id128.pc.in \
	src/libsystemd-id128.sym

Kay Sievers's avatar
Kay Sievers committed
971
# ------------------------------------------------------------------------------
972
973
974
systemd_journald_SOURCES = \
	src/journal/journald.c \
	src/journal/sd-journal.c \
975
976
977
978
979
980
	src/journal/journal-file.c \
	src/journal/lookup3.c \
	src/journal/journal-rate-limit.c \
	src/sd-id128.c \
	src/acl-util.c \
	src/cgroup-util.c