stat: Move AC_LIBOBJ invocations to module description.
authorBruno Haible <bruno@clisp.org>
Sat, 21 May 2011 22:34:48 +0000 (00:34 +0200)
committerBruno Haible <bruno@clisp.org>
Wed, 15 Jun 2011 22:06:48 +0000 (00:06 +0200)
* m4/stat.m4 (gl_PREREQ_STAT): New macro, extracted from gl_FUNC_STAT.
(gl_FUNC_STAT): Move AC_LIBOBJ and gl_PREREQ_STAT invocations from
here...
* modules/stat (configure.ac): ... to here.

ChangeLog
m4/stat.m4
modules/stat

index c427ab6e049402c06cb3cb83d0f7f3f4789ea57e..ad665e532049b545d865f32686b0e5db55397303 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2011-05-21  Bruno Haible  <bruno@clisp.org>
+
+       stat: Move AC_LIBOBJ invocations to module description.
+       * m4/stat.m4 (gl_PREREQ_STAT): New macro, extracted from gl_FUNC_STAT.
+       (gl_FUNC_STAT): Move AC_LIBOBJ and gl_PREREQ_STAT invocations from
+       here...
+       * modules/stat (configure.ac): ... to here.
+
 2011-05-21  Bruno Haible  <bruno@clisp.org>
 
        sleep: Move AC_LIBOBJ invocations to module description.
index 27f82d5a91aff206dfc0bbed455419d2521d355f..c63f59fd5330e1e507c0e16b219581f5e63dd2ae 100644 (file)
@@ -1,4 +1,4 @@
-# serial 7
+# serial 8
 
 # Copyright (C) 2009-2011 Free Software Foundation, Inc.
 #
@@ -58,9 +58,11 @@ AC_DEFUN([gl_FUNC_STAT],
       AC_DEFINE([REPLACE_FUNC_STAT_FILE], [1], [Define to 1 if stat needs
         help when passed a file name with a trailing slash]);;
   esac
-  if test $REPLACE_STAT = 1; then
-    AC_LIBOBJ([stat])
-    dnl Prerequisites of lib/stat.c.
-    AC_REQUIRE([AC_C_INLINE])
-  fi
+])
+
+# Prerequisites of lib/stat.c.
+AC_DEFUN([gl_PREREQ_STAT],
+[
+  AC_REQUIRE([AC_C_INLINE])
+  :
 ])
index db179aa38f4c99cb9970bf982fda9ae3da794d5f..6bc27ce3d29f45e3c061b8d7e698bed85b5d9aed 100644 (file)
@@ -12,6 +12,10 @@ stdbool         [test $REPLACE_STAT = 1]
 
 configure.ac:
 gl_FUNC_STAT
+if test $REPLACE_STAT = 1; then
+  AC_LIBOBJ([stat])
+  gl_PREREQ_STAT
+fi
 gl_SYS_STAT_MODULE_INDICATOR([stat])
 
 Makefile.am: