Fix dll exports so that raylib builds in visual studio again. (#2037)

This commit is contained in:
Jeffery Myers 2021-10-07 11:17:45 -07:00 committed by GitHub
parent bb2763cc1f
commit 33ed452439
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 19 additions and 25 deletions

View file

@ -83,11 +83,6 @@
#define RAYLIB_VERSION "4.0"
// Function specifiers definition
#ifndef RLAPI
#define RLAPI // Functions defined as 'extern' by default (implicit specifiers)
#endif
// Function specifiers in case library is build/used as a shared library (Windows)
// NOTE: Microsoft specifiers to tell compiler that symbols are imported/exported from a .dll
#if defined(_WIN32)
@ -95,7 +90,11 @@
#define RLAPI __declspec(dllexport) // We are building the library as a Win32 shared library (.dll)
#elif defined(USE_LIBTYPE_SHARED)
#define RLAPI __declspec(dllimport) // We are using the library as a Win32 shared library (.dll)
#else
#define RLAPI // Functions defined as 'extern' by default (implicit specifiers)
#endif
#else
#define RLAPI // Functions defined as 'extern' by default (implicit specifiers)
#endif
//----------------------------------------------------------------------------------