summaryrefslogtreecommitdiff
path: root/src/udev/Makefile.am
diff options
context:
space:
mode:
authorAnthony G. Basile <blueness@gentoo.org>2013-04-07 20:56:21 -0400
committerAnthony G. Basile <blueness@gentoo.org>2013-04-07 20:56:21 -0400
commitf8209e1f4408278a46b4673044da60082a68997e (patch)
tree5ffba94bc94b97199a7060d221d6ee7d4ffe49df /src/udev/Makefile.am
parent060ec6fee036ce3d2ba2cf78b00a36dd9618b605 (diff)
src/udev/Makefile.am: fix symlink to udevadm
The installation was overwriting udevadm when building with --sbindir=/usr/bin and ignoring $bindir. Both situations lead to a symlink which points to nowhere. Thanks TZ86. Signed-off-by: Anthony G. Basile <blueness@gentoo.org>
Diffstat (limited to 'src/udev/Makefile.am')
-rw-r--r--src/udev/Makefile.am4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/udev/Makefile.am b/src/udev/Makefile.am
index 351d201768..a28607d565 100644
--- a/src/udev/Makefile.am
+++ b/src/udev/Makefile.am
@@ -119,7 +119,9 @@ CLEANFILES = \
# install udevadm symlink in sbindir
install-exec-hook:
- $(LN_S) -f ../bin/udevadm $(DESTDIR)$(sbindir)/udevadm
+ if test "$(bindir)" != "$(sbindir)"; then \
+ $(LN_S) -r $(DESTDIR)$(bindir)/udevadm $(DESTDIR)$(sbindir)/udevadm; \
+ fi
uninstall-hook:
rm -Rf $(DESTDIR)$(sbindir)/udevadm