diff options
| author | raysan5 <[email protected]> | 2020-01-19 11:22:28 +0100 |
|---|---|---|
| committer | raysan5 <[email protected]> | 2020-01-19 11:22:28 +0100 |
| commit | 406373caa93a018393f70d6bd1de0fd7acfdea03 (patch) | |
| tree | aa5b08af8dc8626fd7ec96434c658669bf6b5008 /src | |
| parent | 6a46dcb374a31eab225f8be9f8ed935a2530b44e (diff) | |
| download | raylib-406373caa93a018393f70d6bd1de0fd7acfdea03.tar.gz raylib-406373caa93a018393f70d6bd1de0fd7acfdea03.zip | |
Review functions definition modifiers
Diffstat (limited to 'src')
| -rw-r--r-- | src/raylib.h | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/src/raylib.h b/src/raylib.h index b3d5c144..b9ce607d 100644 --- a/src/raylib.h +++ b/src/raylib.h @@ -74,14 +74,17 @@ #ifndef RAYLIB_H #define RAYLIB_H -#include <stdarg.h> // Required for: va_list - Only used by TraceLogCallback +#include <stdarg.h> // Required for: va_list - Only used by TraceLogCallback -#if defined(_WIN32) && defined(BUILD_LIBTYPE_SHARED) - #define RLAPI __declspec(dllexport) // We are building raylib as a Win32 shared library (.dll) -#elif defined(_WIN32) && defined(USE_LIBTYPE_SHARED) - #define RLAPI __declspec(dllimport) // We are using raylib as a Win32 shared library (.dll) -#else - #define RLAPI // We are building or using raylib as a static library (or Linux shared library) +#define RLAPI // We are building or using raylib as a static library (or Linux shared library) + +#if defined(_WIN32) + // Microsoft attibutes to tell compiler that symbols are imported/exported from a .dll + #if defined(BUILD_LIBTYPE_SHARED) + #define RLAPI __declspec(dllexport) // We are building raylib as a Win32 shared library (.dll) + #elif defined(USE_LIBTYPE_SHARED) + #define RLAPI __declspec(dllimport) // We are using raylib as a Win32 shared library (.dll) + #endif #endif //---------------------------------------------------------------------------------- |
