From 829cb2f84f770e935ed70c2d06a488d728f4a525 Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Wed, 18 Aug 2010 07:42:47 -0400 Subject: [PATCH] Substitute sysconfdir in the installed sudoers file to get the correct path for sudoers.d. --HG-- branch : 1.7 --- configure | 3 ++- configure.in | 2 +- sudoers => sudoers.in | 5 +++-- 3 files changed, 6 insertions(+), 4 deletions(-) rename sudoers => sudoers.in (95%) diff --git a/configure b/configure index f6190623c..7ae9cf497 100755 --- a/configure +++ b/configure @@ -18470,7 +18470,7 @@ test "$datarootdir" = '${prefix}/share' && datarootdir='$(prefix)/share' test "$docdir" = '${datarootdir}/doc/${PACKAGE_TARNAME}' && docdir='$(datarootdir)/doc/$(PACKAGE_TARNAME)' test "$sysconfdir" = '${prefix}/etc' -a X"$with_stow" != X"yes" && sysconfdir='/etc' -ac_config_files="$ac_config_files Makefile sudo.man visudo.man sudoers.man sudoers.ldap.man sudoreplay.man sudo_usage.h" +ac_config_files="$ac_config_files Makefile sudo.man visudo.man sudoers.man sudoers.ldap.man sudoreplay.man sudo_usage.h sudoers" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure @@ -19427,6 +19427,7 @@ do "sudoers.ldap.man") CONFIG_FILES="$CONFIG_FILES sudoers.ldap.man" ;; "sudoreplay.man") CONFIG_FILES="$CONFIG_FILES sudoreplay.man" ;; "sudo_usage.h") CONFIG_FILES="$CONFIG_FILES sudo_usage.h" ;; + "sudoers") CONFIG_FILES="$CONFIG_FILES sudoers" ;; *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac diff --git a/configure.in b/configure.in index af6e7fb8f..ae06875b3 100644 --- a/configure.in +++ b/configure.in @@ -2803,7 +2803,7 @@ test "$sysconfdir" = '${prefix}/etc' -a X"$with_stow" != X"yes" && sysconfdir='/ dnl dnl Substitute into the Makefile and man pages dnl -AC_CONFIG_FILES([Makefile sudo.man visudo.man sudoers.man sudoers.ldap.man sudoreplay.man sudo_usage.h]) +AC_CONFIG_FILES([Makefile sudo.man visudo.man sudoers.man sudoers.ldap.man sudoreplay.man sudo_usage.h sudoers]) AC_OUTPUT dnl diff --git a/sudoers b/sudoers.in similarity index 95% rename from sudoers rename to sudoers.in index 4d346a6f5..42e639e80 100644 --- a/sudoers +++ b/sudoers.in @@ -85,5 +85,6 @@ root ALL=(ALL) ALL # Defaults targetpw # Ask for the password of the target user # ALL ALL=(ALL) ALL # WARNING: only use this together with 'Defaults targetpw' -## Read drop-in files from /etc/sudoers.d (the # here does not mean a comment) -#includedir /etc/sudoers.d +## Read drop-in files from @sysconfdir@/sudoers.d +## (the '#' here does not indicate a comment) +#includedir @sysconfdir@/sudoers.d -- 2.40.0