2012-01-06 04:12:57 +00:00
|
|
|
# ASEPRITE
|
2015-03-16 18:05:13 +00:00
|
|
|
# Copyright (C) 2001-2015 David Capello
|
2010-08-11 00:49:32 +00:00
|
|
|
|
2015-05-29 14:26:56 +00:00
|
|
|
include(CheckCXXSourceCompiles)
|
|
|
|
|
2010-09-30 20:04:32 +00:00
|
|
|
include_directories(.)
|
2010-08-11 00:49:32 +00:00
|
|
|
|
2010-08-25 19:18:46 +00:00
|
|
|
if(MSVC)
|
|
|
|
add_definitions(-D_CRT_SECURE_NO_WARNINGS)
|
|
|
|
endif(MSVC)
|
|
|
|
|
2010-09-30 20:04:32 +00:00
|
|
|
if(NOT USE_SHARED_JPEGLIB)
|
|
|
|
add_subdirectory(jpeg)
|
|
|
|
endif()
|
|
|
|
|
|
|
|
if(NOT USE_SHARED_ZLIB)
|
|
|
|
include_directories(zlib)
|
|
|
|
add_subdirectory(zlib)
|
|
|
|
endif()
|
|
|
|
|
|
|
|
if(NOT USE_SHARED_LIBPNG)
|
|
|
|
add_subdirectory(libpng)
|
|
|
|
endif()
|
|
|
|
|
2012-03-15 03:17:49 +00:00
|
|
|
if(NOT USE_SHARED_GIFLIB)
|
|
|
|
add_subdirectory(giflib)
|
|
|
|
endif()
|
|
|
|
|
2012-03-19 17:04:24 +00:00
|
|
|
if(NOT USE_SHARED_TINYXML)
|
|
|
|
add_subdirectory(tinyxml)
|
|
|
|
endif()
|
|
|
|
|
2015-05-29 14:26:56 +00:00
|
|
|
if(NOT USE_SHARED_GTEST AND EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/gtest/CMakeLists.txt)
|
|
|
|
# We don't use add_subdirectory(gtest) because the gtest
|
|
|
|
# CMakeLists.txt modifies some MSVC flags.
|
|
|
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/gtest ${CMAKE_CURRENT_SOURCE_DIR}/gtest/include)
|
|
|
|
add_library(gtest ${CMAKE_CURRENT_SOURCE_DIR}/gtest/src/gtest-all.cc)
|
|
|
|
else()
|
|
|
|
find_library(gtest)
|
|
|
|
check_cxx_source_compiles("
|
|
|
|
#include <gtest/gtest.h>
|
|
|
|
int main() { }
|
|
|
|
" HAVE_GTEST_GTEST_H)
|
|
|
|
if(NOT HAVE_GTEST_GTEST_H)
|
|
|
|
message(FATAL_ERROR "gtest/gtest.h is missing. Set USE_SHARED_GTEST=OFF and initialize submodules: git submodule update --init --recursive")
|
|
|
|
endif()
|
2012-03-19 17:33:49 +00:00
|
|
|
endif()
|
|
|
|
|
2015-04-23 22:14:13 +00:00
|
|
|
if(NOT USE_SHARED_CURL)
|
2015-03-10 16:50:12 +00:00
|
|
|
set(BUILD_RELEASE_DEBUG_DIRS ON BOOL)
|
2011-07-28 00:26:22 +00:00
|
|
|
add_subdirectory(curl)
|
|
|
|
endif()
|
2012-03-15 03:17:49 +00:00
|
|
|
|
2015-03-16 18:05:13 +00:00
|
|
|
if(USE_ALLEG4_BACKEND AND NOT USE_SHARED_LIBLOADPNG)
|
|
|
|
add_subdirectory(loadpng)
|
2012-07-09 00:21:01 +00:00
|
|
|
endif()
|
2013-03-31 03:36:00 +00:00
|
|
|
|
|
|
|
if(ENABLE_WEBSERVER)
|
|
|
|
add_subdirectory(mongoose)
|
|
|
|
endif()
|
2014-10-17 00:27:25 +00:00
|
|
|
|
2014-10-26 01:22:58 +00:00
|
|
|
if(NOT USE_SHARED_PIXMAN)
|
|
|
|
add_subdirectory(pixman-cmake)
|
|
|
|
endif()
|
2014-10-30 04:06:27 +00:00
|
|
|
|
2014-10-17 00:27:25 +00:00
|
|
|
add_subdirectory(simpleini)
|