diff options
-rw-r--r-- | Makefile.am | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/Makefile.am b/Makefile.am index e7134a25c9..3eafcff4be 100644 --- a/Makefile.am +++ b/Makefile.am @@ -208,7 +208,7 @@ define move-to-rootlibdir $(MKDIR_P) $(DESTDIR)$(rootlibdir) && \ so_img_name=$$(readlink $(DESTDIR)$(libdir)/$$libname) && \ so_img_rel_target_prefix=$$(echo $(libdir) | sed 's,\(^/\|\)[^/][^/]*,..,g') && \ - $(LN_S) -f $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/$$libname && \ + $(LN_S) --relative -f $$so_img_rel_target_prefix$(rootlibdir)/$$so_img_name $(DESTDIR)$(libdir)/$$libname && \ mv $(DESTDIR)$(libdir)/$$libname.* $(DESTDIR)$(rootlibdir); \ fi endef @@ -232,7 +232,6 @@ USER_BUSNAMES_TARGET_WANTS = SYSTEM_UNIT_ALIASES = USER_UNIT_ALIASES = - GENERAL_ALIASES = install-target-wants-hook: @@ -268,9 +267,9 @@ install-aliases-hook: set -- $(SYSTEM_UNIT_ALIASES) && \ dir=$(systemunitdir) && $(install-aliases) set -- $(USER_UNIT_ALIASES) && \ - dir=$(userunitdir) && $(install-aliases) + dir=$(userunitdir) && $(install-relative-aliases) set -- $(GENERAL_ALIASES) && \ - dir= && $(install-aliases) + dir= && $(install-relative-aliases) define install-aliases while [ -n "$$1" ]; do \ @@ -281,6 +280,15 @@ define install-aliases done endef +define install-relative-aliases + while [ -n "$$1" ]; do \ + $(MKDIR_P) `dirname $(DESTDIR)$$dir/$$2` && \ + rm -f $(DESTDIR)$$dir/$$2 && \ + $(LN_S) --relative $(DESTDIR)$$1 $(DESTDIR)$$dir/$$2 && \ + shift 2 || exit $$?; \ + done +endef + INSTALL_EXEC_HOOKS += \ install-target-wants-hook \ install-directories-hook \ @@ -1848,7 +1856,7 @@ systemd_dbus1_generator_LDADD = \ dbus1-generator-install-hook: $(AM_V_at)$(MKDIR_P) $(DESTDIR)$(usergeneratordir) - $(AM_V_LN)$(LN_S) -f $(systemgeneratordir)/systemd-dbus1-generator $(DESTDIR)$(usergeneratordir)/systemd-dbus1-generator + $(AM_V_LN)$(LN_S) --relative -f $(DESTDIR)$(systemgeneratordir)/systemd-dbus1-generator $(DESTDIR)$(usergeneratordir)/systemd-dbus1-generator dbus1-generator-uninstall-hook: rm -f $(DESTDIR)$(usergeneratordir)/systemd-dbus1-generator @@ -1978,7 +1986,7 @@ systemd_bus_proxyd_LDADD = \ bus-proxyd-install-hook: $(AM_V_at)$(MKDIR_P) $(DESTDIR)$(bindir) - $(AM_V_LN)$(LN_S) -f $(rootlibexecdir)/systemd-bus-proxyd $(DESTDIR)$(bindir)/systemd-stdio-bridge + $(AM_V_LN)$(LN_S) --relative -f $(DESTDIR)$(rootlibexecdir)/systemd-bus-proxyd $(DESTDIR)$(bindir)/systemd-stdio-bridge bus-proxyd-uninstall-hook: rm -f $(DESTDIR)$(bindir)/systemd-stdio-bridge @@ -4842,7 +4850,7 @@ GENERAL_ALIASES += \ $(systemunitdir)/remote-fs.target $(pkgsysconfdir)/system/multi-user.target.wants/remote-fs.target \ $(systemunitdir)/getty@.service $(pkgsysconfdir)/system/getty.target.wants/getty@tty1.service \ $(pkgsysconfdir)/user $(sysconfdir)/xdg/systemd/user \ - ../system-services/org.freedesktop.systemd1.service $(dbussessionservicedir)/org.freedesktop.systemd1.service + $(dbussystemservicedir)/org.freedesktop.systemd1.service $(dbussessionservicedir)/org.freedesktop.systemd1.service if HAVE_SYSV_COMPAT INSTALL_DIRS += \ |