Update CMakeLists.txt
Add compile defintions for filesystem header for older gcc versions
This commit is contained in:
parent
4b6858d526
commit
739942bc37
1 changed files with 8 additions and 1 deletions
|
|
@ -12,7 +12,14 @@ project("clutchlog"
|
|||
enable_language(CXX) # C++
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
|
||||
set(CMAKE_CXX_STANDARD_LIBRARIES -lstdc++fs)
|
||||
if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
|
||||
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -pedantic -std=c++17 -lstdc++fs")
|
||||
if(CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 6.0 AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 9.0)
|
||||
link_libraries(stdc++fs)
|
||||
add_compile_definitions(FSEXPERIMENTAL)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
######################################################################################
|
||||
# Configurable user settings
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue