]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Fix a compilation error on deficient non-glibc systems with GCC 4.
authorBruno Haible <bruno@clisp.org>
Sun, 9 Aug 2009 14:39:05 +0000 (16:39 +0200)
committerBruno Haible <bruno@clisp.org>
Sun, 9 Aug 2009 14:39:05 +0000 (16:39 +0200)
gettext-runtime/intl/ChangeLog
gettext-runtime/intl/printf.c

index 0eabe4f0a9218492394eef09e3bf0ff7f6d223a1..756d3613c87a61511e3fdb6753c67d82b157ffb9 100644 (file)
@@ -1,3 +1,11 @@
+2009-08-09  Bruno Haible  <bruno@clisp.org>
+
+       Fix a compilation error on non-glibc systems that have gcc visibility
+       support but deficient *printf functions.
+       * printf.c (DLL_EXPORTED): Define to non-empty also when
+       HAVE_VISIBILITY is true.
+       Reported at <https://savannah.gnu.org/bugs/?27185>.
+
 2009-06-06  Bruno Haible  <bruno@clisp.org>
 
        Interoperate with automake-1.11 provided --enable-silent-rules option.
index 0088e5195bccedf189009414980b1e5e3d1aebd7..754851404e3d5cac6a4a66d904cdae2bc403f4e0 100644 (file)
@@ -1,5 +1,5 @@
 /* Formatted output to strings, using POSIX/XSI format strings with positions.
-   Copyright (C) 2003, 2006-2007 Free Software Foundation, Inc.
+   Copyright (C) 2003, 2006-2007, 2009 Free Software Foundation, Inc.
    Written by Bruno Haible <bruno@clisp.org>, 2003.
 
    This program is free software; you can redistribute it and/or modify it
@@ -60,7 +60,9 @@ char *alloca ();
 /* When building a DLL, we must export some functions.  Note that because
    the functions are only defined for binary backward compatibility, we
    don't need to use __declspec(dllimport) in any case.  */
-#if defined _MSC_VER && BUILDING_DLL
+#if HAVE_VISIBILITY && BUILDING_DLL
+# define DLL_EXPORTED __attribute__((__visibility__("default")))
+#elif defined _MSC_VER && BUILDING_DLL
 # define DLL_EXPORTED __declspec(dllexport)
 #else
 # define DLL_EXPORTED