hedgewars/CMakeLists.txt
changeset 8661 ac8dba27a3f1
parent 8611 90f445317e8a
child 8662 bfcc09f2accc
--- a/hedgewars/CMakeLists.txt	Wed Mar 06 02:52:17 2013 +0100
+++ b/hedgewars/CMakeLists.txt	Wed Mar 06 03:11:15 2013 +0100
@@ -4,7 +4,19 @@
 find_package(SDL_ttf)
 find_package(SDL_mixer)
 
-include(${CMAKE_SOURCE_DIR}/cmake_modules/FindSDL_Extras.cmake)
+
+include (CheckLibraryExists)
+#Mix_Init/Mix_Quit from SDL_mixer 1.2.9
+check_library_exists(${SDL_MIXER_LIBRARY} Mix_Init "" HAVE_MIXINIT) 
+if(HAVE_MIXINIT)
+    list(APPEND pascal_flags "-dSDL_MIXER_NEWER")
+endif()
+#IMG_Init/IMG_Quit from SDL_image 1.2.7
+check_library_exists(${SDL_IMAGE_LIBRARY} IMG_Init "" HAVE_IMGINIT)
+if(HAVE_IMGINIT)
+    list(APPEND pascal_flags "-dSDL_IMAGE_NEWER")
+endif()
+
 
 configure_file(${hedgewars_SOURCE_DIR}/hedgewars/config.inc.in ${CMAKE_CURRENT_BINARY_DIR}/config.inc)