summaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
authorMichal Schmidt <mschmidt@redhat.com>2011-12-02 10:18:46 +0100
committerMichal Schmidt <mschmidt@redhat.com>2011-12-02 11:29:48 +0100
commit156730831730701cada2750e826abbf7b113861f (patch)
tree398a1262c3a7aa2cd0039781ada8d97928d8c920 /Makefile.am
parent42e87475cfe20a5e79da882012629f9d3ae63648 (diff)
add a generator to pull rc-local.service in
rc-local.service acts as an ordering barrier even if its condition is false, because conditions are evaluated when the service is about to be started. To avoid the ordering barrier in a legacy-free system, add a generator to pull rc-local.service into the transaction only if the script is executable. If/when we rewrite SysV compatibility into a generator, this one can become a part of it.
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am29
1 files changed, 17 insertions, 12 deletions
diff --git a/Makefile.am b/Makefile.am
index d30d626ebf..170465a6c2 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -529,6 +529,8 @@ dist_systemunit_DATA += \
units/fedora/prefdm.service \
units/fedora/rc-local.service \
units/fedora/halt-local.service
+systemgenerator_PROGRAMS += \
+ systemd-rc-local-generator
endif
if TARGET_MANDRIVA
@@ -536,6 +538,8 @@ dist_systemunit_DATA += \
units/mandriva/prefdm.service \
units/fedora/rc-local.service \
units/fedora/halt-local.service
+systemgenerator_PROGRAMS += \
+ systemd-rc-local-generator
endif
if TARGET_FRUGALWARE
@@ -547,6 +551,8 @@ if TARGET_SUSE
dist_systemunit_DATA += \
units/suse/rc-local.service \
units/suse/halt-local.service
+systemgenerator_PROGRAMS += \
+ systemd-rc-local-generator
endif
if TARGET_MAGEIA
@@ -554,6 +560,8 @@ dist_systemunit_DATA += \
units/mageia/prefdm.service \
units/fedora/rc-local.service \
units/fedora/halt-local.service
+systemgenerator_PROGRAMS += \
+ systemd-rc-local-generator
endif
if HAVE_PLYMOUTH
@@ -1270,6 +1278,15 @@ systemd_getty_generator_CFLAGS = \
systemd_getty_generator_LDADD = \
libsystemd-basic.la
+systemd_rc_local_generator_SOURCES = \
+ src/rc-local-generator.c
+
+systemd_rc_local_generator_CFLAGS = \
+ $(AM_CFLAGS)
+
+systemd_rc_local_generator_LDADD = \
+ libsystemd-basic.la
+
systemd_user_sessions_SOURCES = \
src/user-sessions.c \
src/cgroup-util.c
@@ -1963,9 +1980,6 @@ endif
if TARGET_FEDORA
$(MKDIR_P) -m 0755 $(DESTDIR)$(systemunitdir)/final.target.wants
- ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
- rm -f rc-local.service && \
- $(LN_S) $(systemunitdir)/rc-local.service rc-local.service )
( cd $(DESTDIR)$(systemunitdir)/final.target.wants && \
rm -f halt-local.service && \
$(LN_S) $(systemunitdir)/halt-local.service halt-local.service )
@@ -1980,9 +1994,6 @@ endif
if TARGET_MANDRIVA
$(MKDIR_P) -m 0755 $(DESTDIR)$(systemunitdir)/final.target.wants
- ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
- rm -f rc-local.service && \
- $(LN_S) $(systemunitdir)/rc-local.service rc-local.service )
( cd $(DESTDIR)$(systemunitdir)/final.target.wants && \
rm -f halt-local.service && \
$(LN_S) $(systemunitdir)/halt-local.service halt-local.service )
@@ -2004,9 +2015,6 @@ endif
if TARGET_SUSE
$(MKDIR_P) -m 0755 $(DESTDIR)$(systemunitdir)/final.target.wants
- ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
- rm -f rc-local.service && \
- $(LN_S) $(systemunitdir)/rc-local.service rc-local.service )
( cd $(DESTDIR)$(systemunitdir) && \
rm -f local.service && \
$(LN_S) rc-local.service local.service )
@@ -2017,9 +2025,6 @@ endif
if TARGET_MAGEIA
$(MKDIR_P) -m 0755 $(DESTDIR)$(systemunitdir)/final.target.wants
- ( cd $(DESTDIR)$(systemunitdir)/multi-user.target.wants && \
- rm -f rc-local.service && \
- $(LN_S) $(systemunitdir)/rc-local.service rc-local.service )
( cd $(DESTDIR)$(systemunitdir)/final.target.wants && \
rm -f halt-local.service && \
$(LN_S) $(systemunitdir)/halt-local.service halt-local.service )