2
0
Эх сурвалжийг харах

Merge pull request #62173 from Faless/gdnative/3.x_mingw_dllexport_plus

Rémi Verschelde 3 жил өмнө
parent
commit
f0cfe3a83b

+ 5 - 3
modules/gdnative/include/gdnative/gdnative.h

@@ -53,13 +53,15 @@ extern "C" {
 #endif
 
 // This is for libraries *using* the header, NOT GODOT EXPOSING STUFF!!
-#ifdef __GNUC__
-#define GDN_EXPORT __attribute__((visibility("default")))
-#elif defined(_WIN32)
+#if !defined(GDN_EXPORT)
+#if defined(_WIN32)
 #define GDN_EXPORT __declspec(dllexport)
+#elif defined(__GNUC__)
+#define GDN_EXPORT __attribute__((visibility("default")))
 #else
 #define GDN_EXPORT
 #endif
+#endif
 
 #include <stdbool.h>
 #include <stdint.h>