Don't use unsupported visibily attribute hidden on Solaris

Thanks to Thomas Klausner for passing the report along.
This fixes the following bug report:

	hidden attribute does not work with Solaris ld
	https://bugs.freedesktop.org/show_bug.cgi?id=10227

And as Behdad points out, an even better fix would be to
move checks for supported visibility attribute to configure.
This commit is contained in:
Gilles Dauphin 2007-03-16 10:35:23 -07:00 committed by Carl Worth
parent 8236282c5d
commit d02aa5b23e
2 changed files with 3 additions and 3 deletions

View file

@ -99,7 +99,7 @@ SOFTWARE.
#include "pixman-remap.h"
#if (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 3)) && defined(__ELF__)
#if (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 3)) && defined(__ELF__) && !defined(__sun__)
#define pixman_private __attribute__((__visibility__("hidden")))
#elif defined(__SUNPRO_C) && (__SUNPRO_C >= 0x550)
#define pixman_private __hidden

View file

@ -73,7 +73,7 @@
CAIRO_BEGIN_DECLS
#if __GNUC__ >= 3 && defined(__ELF__)
#if __GNUC__ >= 3 && defined(__ELF__) && !defined(__sun)
# define slim_hidden_proto(name) slim_hidden_proto1(name, slim_hidden_int_name(name))
# define slim_hidden_def(name) slim_hidden_def1(name, slim_hidden_int_name(name))
# define slim_hidden_int_name(name) INT_##name
@ -102,7 +102,7 @@ CAIRO_BEGIN_DECLS
#endif
/* slim_internal.h */
#if (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 3)) && defined(__ELF__)
#if (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 3)) && defined(__ELF__) && !defined(__sun)
#define cairo_private __attribute__((__visibility__("hidden")))
#elif defined(__SUNPRO_C) && (__SUNPRO_C >= 0x550)
#define cairo_private __hidden