Loïc Minier <[EMAIL PROTECTED]> writes:
>
>  I'm not sure upstream would accept a patch cluttering the headers for
>  to avoid warnings with an old compiler.

Nosing around in /usr/lib/glib-2.0/include/glibconfig.h I see there's
just such a 2.95 conditional on G_HAVE_ISO_VARARGS, if that could be
extended to G_HAVE_GNUC_VISIBILITY.  Changing to the following works
for me


#define G_HAVE_GNUC_VARARGS 1
#define G_HAVE_GROWING_STACK 0
#define G_HAVE_GNUC_VISIBILITY 1

/* gcc-2.95.x supports both gnu style and ISO varargs, but if -ansi
 * is passed ISO vararg support is turned off, and there is no work
 * around to turn it on, so we unconditionally turn it off.
 *
 * gcc-2.95.x doesn't have __attribute__((visibility ...)).
 */
#if __GNUC__ == 2 && __GNUC_MINOR__ == 95
#  undef G_HAVE_ISO_VARARGS
#  undef G_HAVE_GNUC_VISIBILITY
#endif

#if G_HAVE_GNUC_VISIBILITY
#define G_GNUC_INTERNAL __attribute__((visibility("hidden")))
#else
#define G_GNUC_INTERNAL
#endif

Reply via email to