From: Bruno Haible Date: Sun, 19 Aug 2018 18:58:58 +0000 (+0200) Subject: fnmatch-h: Formalize side effects from other modules. X-Git-Tag: v1.0~5462 X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=ffb9d1f11ed7240034865c9447b4ece8806c226b;p=gnulib.git fnmatch-h: Formalize side effects from other modules. * m4/fnmatch_h.m4 (gl_REPLACE_FNMATCH_H): New macro. * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Invoke it. --- diff --git a/ChangeLog b/ChangeLog index b38be6b5ca..38d1ae397d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2018-08-19 Bruno Haible + fnmatch-h: Formalize side effects from other modules. + * m4/fnmatch_h.m4 (gl_REPLACE_FNMATCH_H): New macro. + * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Invoke it. + limits-h: Formalize side effects from other modules. * m4/limits-h.m4 (gl_REPLACE_LIMITS_H): New macro. * m4/stdint.m4 (gl_STDINT_H): Invoke it. diff --git a/m4/fnmatch.m4 b/m4/fnmatch.m4 index f05f84508f..a61545ac27 100644 --- a/m4/fnmatch.m4 +++ b/m4/fnmatch.m4 @@ -1,4 +1,4 @@ -# Check for fnmatch - serial 12. -*- coding: utf-8 -*- +# Check for fnmatch - serial 13. -*- coding: utf-8 -*- # Copyright (C) 2000-2007, 2009-2018 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation @@ -125,8 +125,7 @@ AC_DEFUN([gl_FUNC_FNMATCH_POSIX], fi fi if test $HAVE_FNMATCH = 0 || test $REPLACE_FNMATCH = 1; then - FNMATCH_H=fnmatch.h - AM_CONDITIONAL([GL_GENERATE_FNMATCH_H], [test -n "$FNMATCH_H"]) + gl_REPLACE_FNMATCH_H fi ]) diff --git a/m4/fnmatch_h.m4 b/m4/fnmatch_h.m4 index afa59fe0a5..077dfef00d 100644 --- a/m4/fnmatch_h.m4 +++ b/m4/fnmatch_h.m4 @@ -1,4 +1,4 @@ -# fnmatch_h.m4 serial 3 +# fnmatch_h.m4 serial 4 dnl Copyright (C) 2009-2018 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -49,6 +49,14 @@ AC_DEFUN_ONCE([gl_FNMATCH_H], [fnmatch]) ]) +dnl Unconditionally enables the replacement of . +AC_DEFUN([gl_REPLACE_FNMATCH_H], +[ + AC_REQUIRE([gl_FNMATCH_H_DEFAULTS]) + FNMATCH_H='fnmatch.h' + AM_CONDITIONAL([GL_GENERATE_FNMATCH_H], [test -n "$FNMATCH_H"]) +]) + AC_DEFUN([gl_FNMATCH_MODULE_INDICATOR], [ dnl Use AC_REQUIRE here, so that the default settings are expanded once only.