mirror of
https://github.com/SFML/SFML.git
synced 2025-03-14 01:40:05 +08:00
Minor modifications to Config.hpp
git-svn-id: https://sfml.svn.sourceforge.net/svnroot/sfml/branches/sfml2@1615 4e206d99-4929-0410-ac5d-dfc041789085
This commit is contained in:
parent
6a6ff075e8
commit
1279cb208c
@ -93,42 +93,32 @@
|
|||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
// Define portable import / export macros
|
// Define portable import / export macros
|
||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
#if defined(SFML_SYSTEM_WINDOWS)
|
#if defined(SFML_SYSTEM_WINDOWS) && !defined(SFML_STATIC)
|
||||||
|
|
||||||
#ifndef SFML_STATIC
|
#ifdef SFML_EXPORTS
|
||||||
|
|
||||||
// Windows platforms
|
// From DLL side, we must export
|
||||||
#ifdef SFML_EXPORTS
|
#define SFML_API __declspec(dllexport)
|
||||||
|
|
||||||
// From DLL side, we must export
|
|
||||||
#define SFML_API __declspec(dllexport)
|
|
||||||
|
|
||||||
#else
|
|
||||||
|
|
||||||
// From client application side, we must import
|
|
||||||
#define SFML_API __declspec(dllimport)
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// For Visual C++ compilers, we also need to turn off this annoying C4251 warning.
|
|
||||||
// You can read lots ot different things about it, but the point is the code will
|
|
||||||
// just work fine, and so the simplest way to get rid of this warning is to disable it
|
|
||||||
#ifdef _MSC_VER
|
|
||||||
|
|
||||||
#pragma warning(disable : 4251)
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
// No specific directive needed for static build
|
// From client application side, we must import
|
||||||
#define SFML_API
|
#define SFML_API __declspec(dllimport)
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// For Visual C++ compilers, we also need to turn off this annoying C4251 warning.
|
||||||
|
// You can read lots ot different things about it, but the point is the code will
|
||||||
|
// just work fine, and so the simplest way to get rid of this warning is to disable it
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
|
||||||
|
#pragma warning(disable : 4251)
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
// Other platforms don't need to define anything
|
// Other platforms and static build don't need these export macros
|
||||||
#define SFML_API
|
#define SFML_API
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user