diff options
author | Bruno Haible <bruno@clisp.org> | 2011-11-26 21:08:25 +0100 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2011-11-26 21:08:25 +0100 |
commit | 48bf98f380eeeaebdb5475ff47bf181f62b58ec6 (patch) | |
tree | c378e4c9912f7fa0d54e1275fbd72f9f039f78c5 /modules | |
parent | 7c455adeee7e1af615a1035a87a918ef24a8e72b (diff) | |
download | gnulib-48bf98f380eeeaebdb5475ff47bf181f62b58ec6.tar.gz |
Fix conflict between two instantiations of module 'unistd'.
* gnulib-tool (func_emit_autoconf_snippet): Substitute
${include_guard_prefix} also in the autoconf snippet.
* m4/getopt.m4 (gl_FUNC_GETOPT_POSIX): Don't set GNULIB_UNISTD_H_GETOPT.
* m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Don't initialize
GNULIB_UNISTD_H_GETOPT.
* modules/getopt-posix (configure.ac): Set the
GNULIB_${gl_include_guard_prefix}_UNISTD_H_GETOPT variable.
* modules/getopt-gnu (configure.ac): Likewise.
* modules/unistd (Makefile.am): Change the substitution value of
GNULIB_UNISTD_H_GETOPT to depend on the include guard prefix.
Reported by Simon Josefsson.
Diffstat (limited to 'modules')
-rw-r--r-- | modules/getopt-gnu | 3 | ||||
-rw-r--r-- | modules/getopt-posix | 3 | ||||
-rw-r--r-- | modules/unistd | 2 |
3 files changed, 7 insertions, 1 deletions
diff --git a/modules/getopt-gnu b/modules/getopt-gnu index 6ad3643aa7..69fc7de1a7 100644 --- a/modules/getopt-gnu +++ b/modules/getopt-gnu @@ -14,7 +14,10 @@ if test $REPLACE_GETOPT = 1; then AC_LIBOBJ([getopt]) AC_LIBOBJ([getopt1]) gl_PREREQ_GETOPT + dnl Arrange for unistd.h to include getopt.h. + GNULIB_${gl_include_guard_prefix}_UNISTD_H_GETOPT=1 fi +AC_SUBST([GNULIB_${gl_include_guard_prefix}_UNISTD_H_GETOPT]) gl_MODULE_INDICATOR_FOR_TESTS([getopt-gnu]) Makefile.am: diff --git a/modules/getopt-posix b/modules/getopt-posix index 89b7a542db..b82d6b27cd 100644 --- a/modules/getopt-posix +++ b/modules/getopt-posix @@ -21,7 +21,10 @@ if test $REPLACE_GETOPT = 1; then AC_LIBOBJ([getopt]) AC_LIBOBJ([getopt1]) gl_PREREQ_GETOPT + dnl Arrange for unistd.h to include getopt.h. + GNULIB_${gl_include_guard_prefix}_UNISTD_H_GETOPT=1 fi +AC_SUBST([GNULIB_${gl_include_guard_prefix}_UNISTD_H_GETOPT]) Makefile.am: BUILT_SOURCES += $(GETOPT_H) diff --git a/modules/unistd b/modules/unistd index 633ba31982..0cee9b3884 100644 --- a/modules/unistd +++ b/modules/unistd @@ -70,7 +70,7 @@ unistd.h: unistd.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H -e 's/@''GNULIB_SYMLINK''@/$(GNULIB_SYMLINK)/g' \ -e 's/@''GNULIB_SYMLINKAT''@/$(GNULIB_SYMLINKAT)/g' \ -e 's/@''GNULIB_TTYNAME_R''@/$(GNULIB_TTYNAME_R)/g' \ - -e 's/@''GNULIB_UNISTD_H_GETOPT''@/$(GNULIB_UNISTD_H_GETOPT)/g' \ + -e 's/@''GNULIB_UNISTD_H_GETOPT''@/0$(GNULIB_${gl_include_guard_prefix}_UNISTD_H_GETOPT)/g' \ -e 's/@''GNULIB_UNISTD_H_NONBLOCKING''@/$(GNULIB_UNISTD_H_NONBLOCKING)/g' \ -e 's/@''GNULIB_UNISTD_H_SIGPIPE''@/$(GNULIB_UNISTD_H_SIGPIPE)/g' \ -e 's/@''GNULIB_UNLINK''@/$(GNULIB_UNLINK)/g' \ |