Преглед изворни кода

Define LOVE_EXPORT on non-Windows.

With GCC or Clang, LOVE_EXPORT is defined as __attribute__((visibility("default"))).
Miku AuahDark пре 3 година
родитељ
комит
c342339fee
1 измењених фајлова са 3 додато и 1 уклоњено
  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