-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
32 lines (24 loc) · 1.01 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
include(CheckIncludeFiles)
include(GNUInstallDirs)
# define project
cmake_minimum_required (VERSION 3.5)
project (jstrings VERSION 1.2 LANGUAGES CXX)
set(PROJECT_CONTACT "Damian R ([email protected])")
set(PROJECT_WEBSITE "https://github.com/drojaazu")
configure_file("${CMAKE_CURRENT_SOURCE_DIR}/src/project.hpp.cfg" "${CMAKE_CURRENT_SOURCE_DIR}/src/project.hpp")
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_COMPILER_NAMES clang++ g++ icpc c++ cxx)
# set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PROJECT_SOURCE_DIR}/bin)
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -DDEBUG")
if (NOT EXISTS ${CMAKE_BINARY_DIR}/CMakeCache.txt)
if (NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "" FORCE)
endif()
endif()
# define target
aux_source_directory("${CMAKE_CURRENT_SOURCE_DIR}/src" SRCFILES)
include_directories("${CMAKE_CURRENT_SOURCE_DIR}/inc")
add_executable(${PROJECT_NAME} ${SRCFILES})
target_compile_features(${PROJECT_NAME} PUBLIC cxx_std_11)
install(TARGETS jstrings
RUNTIME DESTINATION bin)