waitpid: Move AC_LIBOBJ invocations to module description.
authorBruno Haible <bruno@clisp.org>
Sun, 22 May 2011 15:50:15 +0000 (17:50 +0200)
committerBruno Haible <bruno@clisp.org>
Wed, 15 Jun 2011 22:07:04 +0000 (00:07 +0200)
* m4/waitpid.m4 (gl_FUNC_WAITPID): Set HAVE_WAITPID. Move AC_LIBOBJ
invocation from here...
* modules/waitpid (configure.ac): ... to here.

ChangeLog
m4/waitpid.m4
modules/waitpid

index 6c8fb2f..773cd34 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2011-05-22  Bruno Haible  <bruno@clisp.org>
 
+       waitpid: Move AC_LIBOBJ invocations to module description.
+       * m4/waitpid.m4 (gl_FUNC_WAITPID): Set HAVE_WAITPID. Move AC_LIBOBJ
+       invocation from here...
+       * modules/waitpid (configure.ac): ... to here.
+
+2011-05-22  Bruno Haible  <bruno@clisp.org>
+
        utimensat: Move AC_LIBOBJ invocations to module description.
        * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Move AC_LIBOBJ invocations from
        here...
index ccc25e4..ceeeeed 100644 (file)
@@ -1,4 +1,4 @@
-# waitpid.m4 serial 1
+# waitpid.m4 serial 2
 dnl Copyright (C) 2010-2011 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -7,9 +7,8 @@ dnl with or without modifications, as long as this notice is preserved.
 AC_DEFUN([gl_FUNC_WAITPID],
 [
   AC_REQUIRE([AC_CANONICAL_HOST])
+  HAVE_WAITPID=1
   case $host_os in
-    mingw*)
-      AC_LIBOBJ([waitpid])
-      ;;
+    mingw*) HAVE_WAITPID=0 ;;
   esac
 ])
index f9699c6..59e0375 100644 (file)
@@ -10,6 +10,9 @@ sys_wait
 
 configure.ac:
 gl_FUNC_WAITPID
+if test $HAVE_WAITPID = 0; then
+  AC_LIBOBJ([waitpid])
+fi
 gl_SYS_WAIT_MODULE_INDICATOR([waitpid])
 
 Makefile.am: