1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-05-06 10:47:45 +00:00

fix gcc builds on linux

This commit is contained in:
GokuWeedLord 2017-12-10 17:13:57 +11:00
parent e2bc55cd44
commit 7248e351ea

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 )