This repository has been archived on 2020-09-07. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
libs/qad/CMakeLists.txt
2020-08-25 22:38:34 +03:00

41 lines
991 B
CMake

cmake_minimum_required(VERSION 3.0)
cmake_policy(SET CMP0017 NEW) # need include() with .cmake
project(qad)
include_directories(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR})
if (NOT DEFINED ANDROID_PLATFORM)
find_package(OpenGL REQUIRED)
endif()
if (MINGW)
find_package(MinGW REQUIRED)
endif()
# Version
if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/qad_version.h")
file(REMOVE "${CMAKE_CURRENT_SOURCE_DIR}/qad_version.h")
endif()
#message(STATUS "Building QAD version ${QAD_VERSION} (${QAD_LIB_TYPE})")
file(GLOB CMAKES "cmake/*.cmake" "cmake/*.in")
if (LIB)
install(FILES ${CMAKES} DESTINATION ${CMAKE_ROOT}/Modules)
if (WIN32)
install(FILES ${QAD_VERSION_FILE} DESTINATION ${MINGW_INCLUDE}/qad)
else()
install(FILES ${QAD_VERSION_FILE} DESTINATION ${CMAKE_INSTALL_PREFIX}/include/qad)
endif()
else()
install(FILES ${QAD_VERSION_FILE} DESTINATION include/qad)
endif()
add_subdirectory(libs)
if (UTILS)
add_subdirectory(utils)
endif()
copy_to_parent(qad_includes)