feat(Core/Build): add the possibility to link libraries dynamically (#5348)

This commit is contained in:
Kargatum
2021-04-22 03:16:12 +07:00
committed by GitHub
parent 2c5cb29ad4
commit 325dcfc9a6
8 changed files with 261 additions and 8 deletions

View File

@@ -64,6 +64,45 @@
# define ATTR_DEPRECATED
#endif //AC_COMPILER == AC_COMPILER_GNU
#ifdef ACORE_API_USE_DYNAMIC_LINKING
# if AC_COMPILER == AC_COMPILER_MICROSOFT
# define AC_API_EXPORT __declspec(dllexport)
# define AC_API_IMPORT __declspec(dllimport)
# elif AC_COMPILER == AC_COMPILER_GNU
# define AC_API_EXPORT __attribute__((visibility("default")))
# define AC_API_IMPORT
# else
# error compiler not supported!
# endif
#else
# define AC_API_EXPORT
# define AC_API_IMPORT
#endif
#ifdef ACORE_API_EXPORT_COMMON
# define AC_COMMON_API AC_API_EXPORT
#else
# define AC_COMMON_API AC_API_IMPORT
#endif
#ifdef ACORE_API_EXPORT_DATABASE
# define AC_DATABASE_API AC_API_EXPORT
#else
# define AC_DATABASE_API AC_API_IMPORT
#endif
#ifdef ACORE_API_EXPORT_SHARED
# define AC_SHARED_API AC_API_EXPORT
#else
# define AC_SHARED_API AC_API_IMPORT
#endif
#ifdef ACORE_API_EXPORT_GAME
# define AC_GAME_API AC_API_EXPORT
#else
# define AC_GAME_API AC_API_IMPORT
#endif
#define UI64FMTD "%" PRIu64
#define UI64LIT(N) UINT64_C(N)