From 9e60378c46b94c3f89de383147db8e29e1f1b1d7 Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Thu, 1 Jul 2010 13:49:10 -0400 Subject: [PATCH] Substitute @io_logdir@ for the sudoers I/O log directory. --- aclocal.m4 | 12 ++++++------ configure | 46 +++++++++++++++++++++++----------------------- configure.in | 2 ++ 3 files changed, 31 insertions(+), 29 deletions(-) diff --git a/aclocal.m4 b/aclocal.m4 index 17b317be6..f42923a31 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -164,16 +164,16 @@ dnl AC_DEFUN(SUDO_IO_LOGDIR, [ AC_MSG_CHECKING(for I/O log dir location) if test "${with_iologdir-yes}" != "yes"; then - : + io_logdir="$with_iologdir": elif test -d "/var/log"; then - with_iologdir="/var/log/sudo-io" + io_logdir="/var/log/sudo-io" elif test -d "/var/adm"; then - with_iologdir="/var/adm/sudo-io" + io_logdir="/var/adm/sudo-io" else - with_iologdir="/usr/adm/sudo-io" + io_logdir="/usr/adm/sudo-io" fi - SUDO_DEFINE_UNQUOTED(_PATH_SUDO_IO_LOGDIR, "$with_iologdir") - AC_MSG_RESULT($with_iologdir) + SUDO_DEFINE_UNQUOTED(_PATH_SUDO_IO_LOGDIR, "$io_logdir") + AC_MSG_RESULT($io_logdir) ])dnl dnl diff --git a/configure b/configure index d712e5308..cfcfc1c8d 100755 --- a/configure +++ b/configure @@ -816,6 +816,7 @@ sudo_umask password_timeout timeout timedir +io_logdir CONFIGURE_ARGS ac_config_libobj_dir LIBTOOL_DEPS @@ -2786,6 +2787,7 @@ $as_echo "$as_me: Configuring Sudo version $PACKAGE_VERSION" >&6;} # # Begin initial values for man page substitution # +io_logdir=/var/log/sudo-io timedir=/var/run/sudo timeout=5 password_timeout=5 @@ -6966,13 +6968,13 @@ if test "${lt_cv_nm_interface+set}" = set; then : else lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:6969: $ac_compile\"" >&5) + (eval echo "\"\$as_me:6971: $ac_compile\"" >&5) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&5 - (eval echo "\"\$as_me:6972: $NM \\\"conftest.$ac_objext\\\"\"" >&5) + (eval echo "\"\$as_me:6974: $NM \\\"conftest.$ac_objext\\\"\"" >&5) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&5 - (eval echo "\"\$as_me:6975: output\"" >&5) + (eval echo "\"\$as_me:6977: output\"" >&5) cat conftest.out >&5 if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" @@ -8177,7 +8179,7 @@ ia64-*-hpux*) ;; *-*-irix6*) # Find out which ABI we are using. - echo '#line 8180 "configure"' > conftest.$ac_ext + echo '#line 8182 "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? @@ -9438,11 +9440,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9441: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9443: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:9445: \$? = $ac_status" >&5 + echo "$as_me:9447: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -9777,11 +9779,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9780: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9782: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:9784: \$? = $ac_status" >&5 + echo "$as_me:9786: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -9882,11 +9884,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9885: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9887: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:9889: \$? = $ac_status" >&5 + echo "$as_me:9891: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -9937,11 +9939,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:9940: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9942: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:9944: \$? = $ac_status" >&5 + echo "$as_me:9946: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -12304,7 +12306,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 12307 "configure" +#line 12309 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -12400,7 +12402,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 12403 "configure" +#line 12405 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -18223,20 +18225,20 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for I/O log dir location" >&5 $as_echo_n "checking for I/O log dir location... " >&6; } if test "${with_iologdir-yes}" != "yes"; then - : + io_logdir="$with_iologdir": elif test -d "/var/log"; then - with_iologdir="/var/log/sudo-io" + io_logdir="/var/log/sudo-io" elif test -d "/var/adm"; then - with_iologdir="/var/adm/sudo-io" + io_logdir="/var/adm/sudo-io" else - with_iologdir="/usr/adm/sudo-io" + io_logdir="/usr/adm/sudo-io" fi cat >>confdefs.h <&5 -$as_echo "$with_iologdir" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $io_logdir" >&5 +$as_echo "$io_logdir" >&6; } case "$with_passwd" in @@ -20572,8 +20574,6 @@ fi - - diff --git a/configure.in b/configure.in index 79eb069c2..c831c6d7d 100644 --- a/configure.in +++ b/configure.in @@ -63,6 +63,7 @@ AC_SUBST([CONFIGURE_ARGS]) dnl dnl Variables that get substituted in docs (not overridden by environment) dnl +AC_SUBST([io_logdir])dnl real initial value from SUDO_IO_LOGDIR AC_SUBST([timedir])dnl real initial value from SUDO_TIMEDIR AC_SUBST([timeout]) AC_SUBST([password_timeout]) @@ -97,6 +98,7 @@ AC_SUBST([secure_path]) # # Begin initial values for man page substitution # +io_logdir=/var/log/sudo-io timedir=/var/run/sudo timeout=5 password_timeout=5 -- 2.40.0