]> git.tdb.fi Git - libs/game.git/blobdiff - source/game/mspgame_api.h
Decorate things which constitute the public API of the library
[libs/game.git] / source / game / mspgame_api.h
diff --git a/source/game/mspgame_api.h b/source/game/mspgame_api.h
new file mode 100644 (file)
index 0000000..1f9cdf0
--- /dev/null
@@ -0,0 +1,18 @@
+#ifndef MSP_GAME_API_H_
+#define MSP_GAME_API_H_
+
+#if defined(_WIN32)
+#if defined(MSPGAME_BUILD)
+#define MSPGAME_API __declspec(dllexport)
+#elif defined(MSPGAME_IMPORT)
+#define MSPGAME_API __declspec(dllimport)
+#else
+#define MSPGAME_API
+#endif
+#elif defined(__GNUC__)
+#define MSPGAME_API __attribute__((visibility("default")))
+#else
+#define MSPGAME_API
+#endif
+
+#endif