Make it easier to use the 'visibility' module.
authorBruno Haible <bruno@clisp.org>
Wed, 4 Mar 2009 11:04:32 +0000 (12:04 +0100)
committerBruno Haible <bruno@clisp.org>
Wed, 4 Mar 2009 11:04:32 +0000 (12:04 +0100)
ChangeLog
gnulib-tool
modules/visibility

index 86a78527e0f206d865abd120b5c590973714f59f..903ff80bf41e1d75a0d459d5a0c833e64da5e084 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2009-03-04  Bruno Haible  <bruno@clisp.org>
+
+       * modules/visibility (Makefile.am): Augment AM_CFLAGS.
+       * gnulib-tool (func_emit_lib_Makefile_am): Emit initialization of
+       AM_CFLAGS.
+       Reported by Simon Josefsson.
+
 2009-03-03  Bruno Haible  <bruno@clisp.org>
 
        * doc/visibility.texi: Recommend to use HAVE_VISIBILITY as a C macro.
index 5882c68b7c5c909a6b9519fe00087a048e9a7e55..d47bb8123d60a07ab4a967d3ecb7116936791320 100755 (executable)
@@ -1932,6 +1932,7 @@ func_emit_lib_Makefile_am ()
   if test -z "$makefile_name"; then
     echo
     echo "AM_CPPFLAGS ="
+    echo "AM_CFLAGS ="
   fi
   echo
   if LC_ALL=C grep "^[a-zA-Z0-9_]*_${perhapsLT}LIBRARIES *+\{0,1\}= *$libname\\.$libext\$" allsnippets.tmp > /dev/null; then
index 33e5e68386b2908ebb19f9cdf2e730b0514c66f5..a30249c74a8d01a53be166b293d88789074ae4e0 100644 (file)
@@ -10,6 +10,11 @@ configure.ac:
 gl_VISIBILITY
 
 Makefile.am:
+# The value of $(CFLAG_VISIBILITY) needs to be added to the CFLAGS for the
+# compilation of all sources that make up the library. This line here does it
+# only for the gnulib part of it. The developer is responsible for adding
+# $(CFLAG_VISIBILITY) to the Makefile.ams of the other portions of the library.
+AM_CFLAGS += $(CFLAG_VISIBILITY)
 
 Include: