"make dist" can build a different tarball depending on the flags passed
to ./configure and the (optional) dependencies found on the system.
Move all append-to-EXTRA_DIST operations out of automake conditionals to
fix this.
Introduce a polkitpolicy_files so that the policy files built still
correctly depend on the automake conditionals, but the .in files that
get distributed do not.
Signed-Off-By: Bryan Kadzban <bryan.kadzban.is-a-geek.net>
diff --git a/Makefile.am b/Makefile.am
index f45fa27..6991391 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1714,9 +1714,6 @@ lib_LTLIBRARIES += libgudev-1.0.la
pkgconfiglib_DATA += \
src/gudev/gudev-1.0.pc
-EXTRA_DIST += \
- src/gudev/gudev-1.0.pc.in
-
CLEANFILES += \
src/gudev/gudev-1.0.pc
@@ -1767,14 +1764,6 @@ libgudev_1_0_la_LDFLAGS = \
-export-dynamic -no-undefined \
-export-symbols-regex '^g_udev_.*'
-EXTRA_DIST += \
- src/gudev/gudevmarshal.list \
- src/gudev/gudevenumtypes.h.template \
- src/gudev/gudevenumtypes.c.template \
- src/gudev/gjs-example.js \
- src/gudev/seed-example-enum.js \
- src/gudev/seed-example.js
-
CLEANFILES += \
$(nodist_libgudev_1_0_la_SOURCES)
@@ -1858,6 +1847,15 @@ INSTALL_EXEC_HOOKS += libgudev-install-move-hook
UNINSTALL_EXEC_HOOKS += libgudev-uninstall-move-hook
endif
+EXTRA_DIST += \
+ src/gudev/gudev-1.0.pc.in \
+ src/gudev/gudevmarshal.list \
+ src/gudev/gudevenumtypes.h.template \
+ src/gudev/gudevenumtypes.c.template \
+ src/gudev/gjs-example.js \
+ src/gudev/seed-example-enum.js \
+ src/gudev/seed-example.js
+
#
------------------------------------------------------------------------------
if ENABLE_KEYMAP
keymap_SOURCES = \
@@ -1893,10 +1891,6 @@ dist_udevhome_SCRIPTS = \
TESTS += \
src/udev/keymap/check-keymaps.sh
-EXTRA_DIST += \
- src/udev/keymap/check-keymaps.sh \
- src/udev/keymap/keyboard-force-release.sh.in
-
CLEANFILES += \
$(nodist_keymap_SOURCES) \
src/udev/keymap/keys.txt \
@@ -1987,6 +1981,10 @@ src/udev/keymap/keys-to-name.h: src/udev/keymap/keys.txt
Makefile
$(AM_V_GEN)$(AWK) 'BEGIN{ print "const char* const key_names[KEY_CNT] =
{ "} { print "[" $$1 "] = \"" $$1 "\"," } END{print "};"}' < $< > $@
endif
+EXTRA_DIST += \
+ src/udev/keymap/check-keymaps.sh \
+ src/udev/keymap/keyboard-force-release.sh.in
+
#
------------------------------------------------------------------------------
mtd_probe_SOURCES = \
src/udev/mtd_probe/mtd_probe.c \
@@ -2288,13 +2286,13 @@ rootlibexec_PROGRAMS += \
sysctl_DATA = \
sysctl.d/coredump.conf
-EXTRA_DIST += \
- sysctl.d/coredump.conf.in
-
CLEANFILES += \
sysctl.d/coredump.conf
endif
+EXTRA_DIST += \
+ sysctl.d/coredump.conf.in
+
#
------------------------------------------------------------------------------
if ENABLE_BINFMT
systemd_binfmt_SOURCES = \
@@ -2335,10 +2333,10 @@ MANPAGES_ALIAS += \
man/systemd-binfmt.8
man/systemd-binfmt.8: man/systemd-binfmt.service.8
+endif
EXTRA_DIST += \
units/systemd-binfmt.service.in
-endif
#
------------------------------------------------------------------------------
if ENABLE_VCONSOLE
@@ -2366,10 +2364,10 @@ INSTALL_DATA_HOOKS += \
MANPAGES += \
man/vconsole.conf.5
+endif
EXTRA_DIST += \
units/systemd-vconsole-setup.service.in
-endif
#
------------------------------------------------------------------------------
if ENABLE_READAHEAD
@@ -2416,16 +2414,16 @@ nodist_systemunit_DATA += \
units/systemd-readahead-replay.service \
units/systemd-readahead-done.service
-EXTRA_DIST += \
- units/systemd-readahead-collect.service.in \
- units/systemd-readahead-replay.service.in \
- units/systemd-readahead-done.service.in
-
MANPAGES += \
man/sd_readahead.3 \
man/sd-readahead.7
endif
+EXTRA_DIST += \
+ units/systemd-readahead-collect.service.in \
+ units/systemd-readahead-replay.service.in \
+ units/systemd-readahead-done.service.in
+
#
------------------------------------------------------------------------------
if ENABLE_QUOTACHECK
rootlibexec_PROGRAMS += \
@@ -2434,9 +2432,6 @@ rootlibexec_PROGRAMS += \
nodist_systemunit_DATA += \
units/quotacheck.service
-EXTRA_DIST += \
- units/quotacheck.service.in
-
systemd_quotacheck_SOURCES = \
src/quotacheck/quotacheck.c
@@ -2444,6 +2439,9 @@ systemd_quotacheck_LDADD = \
libsystemd-shared.la
endif
+EXTRA_DIST += \
+ units/quotacheck.service.in
+
#
------------------------------------------------------------------------------
if ENABLE_RANDOMSEED
rootlibexec_PROGRAMS += \
@@ -2453,10 +2451,6 @@ nodist_systemunit_DATA += \
units/systemd-random-seed-save.service \
units/systemd-random-seed-load.service
-EXTRA_DIST += \
- units/systemd-random-seed-save.service.in \
- units/systemd-random-seed-load.service.in
-
systemd_random_seed_SOURCES = \
src/random-seed/random-seed.c
@@ -2479,6 +2473,10 @@ INSTALL_DATA_HOOKS += \
randomseed-install-data-hook
endif
+EXTRA_DIST += \
+ units/systemd-random-seed-save.service.in \
+ units/systemd-random-seed-load.service.in
+
#
------------------------------------------------------------------------------
if HAVE_LIBCRYPTSETUP
rootlibexec_PROGRAMS += \
@@ -2547,8 +2545,8 @@ dist_dbuspolicy_DATA += \
dist_dbussystemservice_DATA += \
src/hostname/org.freedesktop.hostname1.service
-polkitpolicy_in_files += \
- src/hostname/org.freedesktop.hostname1.policy.in
+polkitpolicy_files += \
+ src/hostname/org.freedesktop.hostname1.policy
dbusinterface_DATA += \
org.freedesktop.hostname1.xml
@@ -2565,10 +2563,13 @@ hostnamed-install-data-hook:
INSTALL_DATA_HOOKS += \
hostnamed-install-data-hook
+endif
+
+polkitpolicy_in_files += \
+ src/hostname/org.freedesktop.hostname1.policy.in
EXTRA_DIST += \
units/systemd-hostnamed.service.in
-endif
#
------------------------------------------------------------------------------
if ENABLE_LOCALED
@@ -2597,8 +2598,8 @@ dist_dbuspolicy_DATA += \
dist_dbussystemservice_DATA += \
src/locale/org.freedesktop.locale1.service
-polkitpolicy_in_files += \
- src/locale/org.freedesktop.locale1.policy.in
+polkitpolicy_files += \
+ src/locale/org.freedesktop.locale1.policy
dbusinterface_DATA += \
org.freedesktop.locale1.xml
@@ -2616,9 +2617,6 @@ localed-install-data-hook:
INSTALL_DATA_HOOKS += \
localed-install-data-hook
-EXTRA_DIST += \
- units/systemd-localed.service.in
-
dist_pkgdata_DATA = \
src/locale/kbd-model-map
@@ -2630,6 +2628,12 @@ update-kbd-model-map:
endif
+polkitpolicy_in_files += \
+ src/locale/org.freedesktop.locale1.policy.in
+
+EXTRA_DIST += \
+ units/systemd-localed.service.in
+
#
------------------------------------------------------------------------------
if ENABLE_TIMEDATED
systemd_timedated_SOURCES = \
@@ -2656,8 +2660,8 @@ dist_dbuspolicy_DATA += \
nodist_systemunit_DATA += \
units/systemd-timedated.service
-polkitpolicy_in_files += \
- src/timedate/org.freedesktop.timedate1.policy.in
+polkitpolicy_files += \
+ src/timedate/org.freedesktop.timedate1.policy
org.freedesktop.timedate1.xml: systemd-timedated
$(AM_V_GEN)$(LIBTOOL) --mode=execute $(OBJCOPY) -O binary -j
introspect.timedate1 $< [email protected] && \
@@ -2674,10 +2678,13 @@ timedated-install-data-hook:
INSTALL_DATA_HOOKS += \
timedated-install-data-hook
+endif
+
+polkitpolicy_in_files += \
+ src/timedate/org.freedesktop.timedate1.policy.in
EXTRA_DIST += \
units/systemd-timedated.service.in
-endif
#
------------------------------------------------------------------------------
if ENABLE_LOGIND
@@ -2873,8 +2880,8 @@ lib_LTLIBRARIES += \
pkgconfiglib_DATA += \
src/login/libsystemd-login.pc
-polkitpolicy_in_files += \
- src/login/org.freedesktop.login1.policy.in
+polkitpolicy_files += \
+ src/login/org.freedesktop.login1.policy
logind-install-data-hook:
$(MKDIR_P) -m 0755 \
@@ -2963,6 +2970,15 @@ 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
+CLEANFILES += \
+ src/login/logind-gperf.c \
+ src/login/71-seat.rules \
+ src/login/73-seat-late.rules
+endif
+
+polkitpolicy_in_files += \
+ src/login/org.freedesktop.login1.policy.in
+
EXTRA_DIST += \
src/login/logind-gperf.gperf \
src/login/libsystemd-login.pc.in \
@@ -2972,11 +2988,6 @@ EXTRA_DIST += \
units/systemd-logind.service.in \
units/systemd-user-sessions.service.in
-CLEANFILES += \
- src/login/logind-gperf.c \
- src/login/71-seat.rules \
- src/login/73-seat-late.rules
-endif
#
------------------------------------------------------------------------------
SED_PROCESS = \
@@ -3050,7 +3061,7 @@ units/user/%: units/%.m4 Makefile
$(M4_PROCESS_USER)
nodist_polkitpolicy_DATA = \
- $(polkitpolicy_in_files:.policy.in=.policy) \
+ $(polkitpolicy_files) \
$(polkitpolicy_in_in_files:.policy.in.in=.policy)
EXTRA_DIST += \
_______________________________________________
systemd-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/systemd-devel