setenv: restore to working order
authorJim Meyering <meyering@redhat.com>
Sun, 19 Dec 2010 21:48:27 +0000 (22:48 +0100)
committerJim Meyering <meyering@redhat.com>
Sun, 19 Dec 2010 21:48:27 +0000 (22:48 +0100)
$HAVE_SETENV is used in gl_FUNC_SETENV, yet its definitions were
mistakenly removed.
* m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Restore code to set
HAVE_SETENV.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Restore code to initialize
HAVE_SETENV.

ChangeLog
m4/setenv.m4
m4/stdlib_h.m4

index ab8f234..357f06f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2010-12-19  Jim Meyering  <meyering@redhat.com>
+
+       setenv: restore to working order
+       $HAVE_SETENV is used in gl_FUNC_SETENV, yet its definitions were
+       mistakenly removed.
+       * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Restore code to set
+       HAVE_SETENV.
+       * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Restore code to initialize
+       HAVE_SETENV.
+
 2010-12-19  Bruno Haible  <bruno@clisp.org>
 
        Document some different function declarations on OSF/1 5.1.
index ccbe267..7070a5d 100644 (file)
@@ -21,7 +21,9 @@ AC_DEFUN([gl_FUNC_SETENV_SEPARATE],
     HAVE_DECL_SETENV=0
   fi
   AC_CHECK_FUNCS_ONCE([setenv])
-  if test $ac_cv_func_setenv = yes; then
+  if test $ac_cv_func_setenv = no; then
+    HAVE_SETENV=0
+  else
     AC_CACHE_CHECK([whether setenv validates arguments],
       [gl_cv_func_setenv_works],
       [AC_RUN_IFELSE([AC_LANG_PROGRAM([[
index e5a74cc..9ec3e00 100644 (file)
@@ -92,6 +92,7 @@ AC_DEFUN([gl_STDLIB_H_DEFAULTS],
   HAVE_RANDOM_R=1;           AC_SUBST([HAVE_RANDOM_R])
   HAVE_REALPATH=1;           AC_SUBST([HAVE_REALPATH])
   HAVE_RPMATCH=1;            AC_SUBST([HAVE_RPMATCH])
+  HAVE_SETENV=1;             AC_SUBST([HAVE_SETENV])
   HAVE_DECL_SETENV=1;        AC_SUBST([HAVE_DECL_SETENV])
   HAVE_STRTOD=1;             AC_SUBST([HAVE_STRTOD])
   HAVE_STRTOLL=1;            AC_SUBST([HAVE_STRTOLL])