Explorar el Código

Define LOVE_EXPORT on non-Windows.

With GCC or Clang, LOVE_EXPORT is defined as __attribute__((visibility("default"))).
Miku AuahDark hace 3 años
padre
commit
c342339fee
Se han modificado 1 ficheros con 3 adiciones y 1 borrados
  1. 3 1
      src/common/config.h

+ 3 - 1
src/common/config.h

@@ -104,8 +104,10 @@
 #endif
 
 // DLL-stuff.
-#ifdef LOVE_WINDOWS
+#if defined(_MSC_VER)
 #	define LOVE_EXPORT __declspec(dllexport)
+#elif defined(__GNUC__) || defined(__clang__)
+#	define LOVE_EXPORT __attribute__((visibility("default")))
 #else
 #	define LOVE_EXPORT
 #endif