diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-08-20 21:56:12 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-08-24 21:08:13 +0300 |
commit | a6f4bd5c8949c800a28f2de4291b096caec4cd89 (patch) | |
tree | 2c5f70b72038b47f10b08d319e26aa923ab4701a /src/main.cpp | |
parent | f92e278da564dab15d984dcaba153c1a92752651 (diff) | |
download | manaverse-a6f4bd5c8949c800a28f2de4291b096caec4cd89.tar.gz manaverse-a6f4bd5c8949c800a28f2de4291b096caec4cd89.tar.bz2 manaverse-a6f4bd5c8949c800a28f2de4291b096caec4cd89.tar.xz manaverse-a6f4bd5c8949c800a28f2de4291b096caec4cd89.zip |
add configure option --with-sdl2 for enable SDL2 support.
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp index 55af95f4f..7bedd1b9d 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -20,6 +20,7 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ + #include "main.h" #include "client.h" @@ -46,6 +47,18 @@ #include <windows.h> #endif +#include <SDL_version.h> + +#if SDL_VERSION_ATLEAST(2,0,0) +#ifndef USE_SDL2 +#error using SDL2 headers but configure set to use SDL1.2 +#endif +#else +#ifdef USE_SDL2 +#error using SDL1.2 headers but configure set to use SDL2 +#endif +#endif + #include "debug.h" char *selfName = nullptr; |