From: Todd C. Miller Date: Fri, 11 May 2007 21:05:12 +0000 (+0000) Subject: Add closefrom() to LIB_OBJS not SUDO_OBJS if it is missing since we X-Git-Tag: SUDO_1_7_0~574 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=1488331d7556fe0e89f8899e8daedc4835400e97;p=sudo Add closefrom() to LIB_OBJS not SUDO_OBJS if it is missing since we need it for visudo now too. --- diff --git a/configure b/configure index bbf5821b3..9872ec1db 100755 --- a/configure +++ b/configure @@ -15912,7 +15912,14 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then _ACEOF else - SUDO_OBJS="${SUDO_OBJS} closefrom.o" + case $LIBOBJS in + "closefrom.o.$ac_objext" | \ + *" closefrom.o.$ac_objext" | \ + "closefrom.o.$ac_objext "* | \ + *" closefrom.o.$ac_objext "* ) ;; + *) LIBOBJS="$LIBOBJS closefrom.o.$ac_objext" ;; +esac + echo "$as_me:$LINENO: checking whether F_CLOSEM is declared" >&5 echo $ECHO_N "checking whether F_CLOSEM is declared... $ECHO_C" >&6 if test "${ac_cv_have_decl_F_CLOSEM+set}" = set; then diff --git a/configure.in b/configure.in index a6e3f8fa3..99f785555 100644 --- a/configure.in +++ b/configure.in @@ -1718,7 +1718,7 @@ AC_CHECK_FUNCS(utimes, [AC_CHECK_FUNCS(futimes futimesat, [break])], [AC_CHECK_F SUDO_FUNC_FNMATCH([AC_DEFINE(HAVE_FNMATCH)], [AC_LIBOBJ(fnmatch)]) SUDO_FUNC_ISBLANK AC_REPLACE_FUNCS(strerror strcasecmp sigaction strlcpy strlcat) -AC_CHECK_FUNCS(closefrom, [], [SUDO_OBJS="${SUDO_OBJS} closefrom.o" +AC_CHECK_FUNCS(closefrom, [], [AC_LIBOBJ(closefrom.o) AC_CHECK_DECL(F_CLOSEM, AC_DEFINE(HAVE_FCNTL_CLOSEM), [], [ #include #include ])