summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sys-apps/util-linux/files/util-linux-2.25.2-runuser-bash-completion.patch')
-rw-r--r--sys-apps/util-linux/files/util-linux-2.25.2-runuser-bash-completion.patch33
1 files changed, 33 insertions, 0 deletions
diff --git a/sys-apps/util-linux/files/util-linux-2.25.2-runuser-bash-completion.patch b/sys-apps/util-linux/files/util-linux-2.25.2-runuser-bash-completion.patch
new file mode 100644
index 000000000000..85c48114dbd2
--- /dev/null
+++ b/sys-apps/util-linux/files/util-linux-2.25.2-runuser-bash-completion.patch
@@ -0,0 +1,33 @@
+https://bugs.gentoo.org/522288
+
+From a95987423c4d7781a14ffda34f082086cd51f4f7 Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Fri, 24 Oct 2014 12:08:22 -0400
+Subject: [PATCH] bash-completion: fix runuser install
+
+The runuser symlink used to depend on su being enabled, but a refactoring
+broke that. So if you build with runuser enabled but not su, you end up
+with a broken symlink. Rework the logic so it works in both cases.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ bash-completion/Makemodule.am | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/bash-completion/Makemodule.am b/bash-completion/Makemodule.am
+index 271a6db..045c2d5 100644
+--- a/Makefile.in
++++ b/Makefile.in
+@@ -11071,7 +10823,8 @@
+ @BUILD_MOUNT_TRUE@@MAKEINSTALL_DO_SETUID_TRUE@ chmod 4755 $(DESTDIR)$(bindir)/umount
+
+ @BUILD_BASH_COMPLETION_TRUE@@BUILD_RUNUSER_TRUE@install-data-hook-bashcomp-runuser::
+-@BUILD_BASH_COMPLETION_TRUE@@BUILD_RUNUSER_TRUE@ ln -sf su $(DESTDIR)$(bashcompletiondir)/runuser
++@BUILD_BASH_COMPLETION_TRUE@@BUILD_RUNUSER_TRUE@@BUILD_SU_TRUE@ ln -sf su $(DESTDIR)$(bashcompletiondir)/runuser
++@BUILD_BASH_COMPLETION_TRUE@@BUILD_RUNUSER_TRUE@@BUILD_SU_FALSE@ cp $(top_srcdir)/bash-completion/su $(DESTDIR)$(bashcompletiondir)/runuser
+
+ clean-local-tests:
+ rm -rf $(top_builddir)/tests/output $(top_builddir)/tests/diff
+--
+2.1.2
+