1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-05-13 14:07:46 +00:00

fix gcc builds on linux

This commit is contained in:
GokuWeedLord 2017-12-10 17:13:57 +11:00
parent fa0dbe2866
commit 7555b370cd

View file

@ -6,8 +6,14 @@
#include <Actor/Player.h>
#include <StatusEffect/StatusEffect.h>
#ifdef _MSC_VER
#define EXPORT __declspec( dllexport )
#else
#define EXPORT __attribute__((visibility("default")))
#endif
#define EXPORT_SCRIPTOBJECT( type, base ) \
extern "C" __declspec( dllexport ) base* get##base() \
extern "C" EXPORT base* get##base() \
{ return static_cast< base* >( new type ); }
#define EXPORT_STATUSEFFECTSCRIPT( type ) EXPORT_SCRIPTOBJECT( type, StatusEffectScript )