- Updated SDL dependency to SDL2
- fixed compilation issues with cmake and visual studio 2015
This commit is contained in:
@@ -27,10 +27,13 @@ macro(FindOrBuildSDL2)
|
||||
if(ANDROID)
|
||||
set(ENV{SDL2DIR} "$ENV{ANDROID_SDL2_ROOT};$ENV{ANDROID_SDL2_ROOT}/libs/${ANDROID_NDK_ABI_NAME}/")
|
||||
elseif(WIN32)
|
||||
set(ENV{SDL2DIR} $ENV{WIN_SDL2_ROOT})
|
||||
# set(ENV{SDL2DIR} $ENV{WIN_SDL2_ROOT})
|
||||
add_subdirectory(${CMAKE_SOURCE_DIR}/thirdparty/SDL2)
|
||||
set(SDL2_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/thirdparty/SDL2/include ${CMAKE_BINARY_DIR}/thirdparty/SDL2)
|
||||
set(SDL2_LIBRARY SDL2)
|
||||
else()
|
||||
find_package(SDL2)
|
||||
endif()
|
||||
|
||||
find_package(SDL2)
|
||||
endmacro()
|
||||
|
||||
macro(FindOrBuildUNZIP)
|
||||
@@ -84,10 +87,11 @@ macro(FindOrBuildBoost)
|
||||
endif()
|
||||
endmacro()
|
||||
|
||||
|
||||
macro(FindOrBuildZLIB)
|
||||
if(BUILD_ZLIB)
|
||||
add_subdirectory(${CMAKE_SOURCE_DIR}/thirdparty/zlib ${CMAKE_BINARY_DIR}/thirdparty/zlib)
|
||||
set(ZLIB_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/thirdparty/zlib)
|
||||
add_subdirectory(${CMAKE_SOURCE_DIR}/thirdparty/zlib)
|
||||
set(ZLIB_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/thirdparty/zlib ${CMAKE_BINARY_DIR}/thirdparty/zlib)
|
||||
set(ZLIB_LIBRARY zlib)
|
||||
else()
|
||||
if(WIN32)
|
||||
@@ -103,12 +107,7 @@ macro(FindOrBuildGIF)
|
||||
if(BUILD_GIF)
|
||||
message(WARNING "ZLIB sources are currently not included within the wagic tree")
|
||||
else()
|
||||
if(WIN32)
|
||||
set(ENV{GIF_DIR} ${CMAKE_SOURCE_DIR}/thirdparty/binary/win)
|
||||
find_package(GIF)
|
||||
else()
|
||||
find_package(GIF)
|
||||
endif()
|
||||
find_package(GIF)
|
||||
endif()
|
||||
endmacro()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user