better CMakeLists.txt and clang-format
This commit is contained in:
parent
801e74d752
commit
fdb6e89310
@ -14,7 +14,7 @@ BreakConstructorInitializersBeforeComma: 'false'
|
|||||||
ColumnLimit: '80'
|
ColumnLimit: '80'
|
||||||
ConstructorInitializerAllOnOneLineOrOnePerLine: 'true'
|
ConstructorInitializerAllOnOneLineOrOnePerLine: 'true'
|
||||||
Cpp11BracedListStyle: 'true'
|
Cpp11BracedListStyle: 'true'
|
||||||
IndentCaseLabels: 'true'
|
IndentCaseLabels: 'false'
|
||||||
KeepEmptyLinesAtTheStartOfBlocks: 'false'
|
KeepEmptyLinesAtTheStartOfBlocks: 'false'
|
||||||
Language: Cpp
|
Language: Cpp
|
||||||
MaxEmptyLinesToKeep: '2'
|
MaxEmptyLinesToKeep: '2'
|
||||||
|
@ -6,6 +6,8 @@ project("GeneticImages"
|
|||||||
HOMEPAGE_URL "https://labs.phundrak.fr/phundrak/genetic-images"
|
HOMEPAGE_URL "https://labs.phundrak.fr/phundrak/genetic-images"
|
||||||
LANGUAGES CXX)
|
LANGUAGES CXX)
|
||||||
|
|
||||||
|
set(CMAKE_CXX_COMPILER /usr/bin/clang++)
|
||||||
|
|
||||||
file(GLOB SRC_FILES "src/*.cc")
|
file(GLOB SRC_FILES "src/*.cc")
|
||||||
|
|
||||||
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake")
|
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake")
|
||||||
@ -15,9 +17,16 @@ include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
|
|||||||
conan_basic_setup()
|
conan_basic_setup()
|
||||||
|
|
||||||
enable_cxx_compiler_flag_if_supported("-Wall")
|
enable_cxx_compiler_flag_if_supported("-Wall")
|
||||||
|
enable_cxx_compiler_flag_if_supported("-Wextra")
|
||||||
|
enable_cxx_compiler_flag_if_supported("-Wshadow")
|
||||||
|
enable_cxx_compiler_flag_if_supported("-Wpedantic")
|
||||||
enable_cxx_compiler_flag_if_supported("-pedantic")
|
enable_cxx_compiler_flag_if_supported("-pedantic")
|
||||||
enable_cxx_compiler_flag_if_supported("-O3")
|
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
|
||||||
enable_cxx_compiler_flag_if_supported("-flto")
|
enable_cxx_compiler_flag_if_supported("-g")
|
||||||
|
else()
|
||||||
|
enable_cxx_compiler_flag_if_supported("-O3")
|
||||||
|
enable_cxx_compiler_flag_if_supported("-flto")
|
||||||
|
endif()
|
||||||
|
|
||||||
# include_directories(<PUBLIC HEADER DIRECTORIES>)
|
# include_directories(<PUBLIC HEADER DIRECTORIES>)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user