mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-09-27 17:52:58 +02:00
giomodules: g_io_module_* must always be exported
Those symbols are not used by GIO itself but by external modules.
This commit is contained in:
@@ -178,6 +178,11 @@
|
||||
* non-default
|
||||
* [visibility flag](https://gcc.gnu.org/onlinedocs/gcc/Code-Gen-Options.html#index-fvisibility-1260)
|
||||
* such as `hidden`.
|
||||
*
|
||||
* This macro must only be used when compiling a shared module. Modules that
|
||||
* support both shared and static linking should define their own macro that
|
||||
* expands to %G_MODULE_EXPORT when compiling the shared module, but is empty
|
||||
* when compiling the static module on Windows.
|
||||
*/
|
||||
|
||||
/**
|
||||
|
@@ -35,14 +35,16 @@ G_BEGIN_DECLS
|
||||
/* exporting and importing functions, this is special cased
|
||||
* to feature Windows dll stubs.
|
||||
*/
|
||||
#define G_MODULE_IMPORT extern
|
||||
#ifdef G_PLATFORM_WIN32
|
||||
# define G_MODULE_EXPORT __declspec(dllexport)
|
||||
#if defined(_WIN32) || defined(__CYGWIN__)
|
||||
# define G_MODULE_EXPORT __declspec(dllexport)
|
||||
# define G_MODULE_IMPORT __declspec(dllimport) extern
|
||||
#elif __GNUC__ >= 4
|
||||
# define G_MODULE_EXPORT __attribute__((visibility("default")))
|
||||
#else /* !G_PLATFORM_WIN32 && __GNUC__ < 4 */
|
||||
# define G_MODULE_EXPORT
|
||||
#endif /* !G_PLATFORM_WIN32 */
|
||||
# define G_MODULE_EXPORT __attribute__((visibility("default")))
|
||||
# define G_MODULE_IMPORT extern
|
||||
#else /* !defined(_WIN32) && !defined(__CYGWIN__) && __GNUC__ < 4 */
|
||||
# define G_MODULE_EXPORT
|
||||
# define G_MODULE_IMPORT extern
|
||||
#endif
|
||||
|
||||
/**
|
||||
* GModuleFlags:
|
||||
|
Reference in New Issue
Block a user