Skip to content

Commit

Permalink
link stdc++fs when using gcc8
Browse files Browse the repository at this point in the history
  • Loading branch information
octobanana committed Oct 5, 2020
1 parent 2e5c428 commit ed3d60e
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions CMakeLists.txt
Expand Up @@ -80,6 +80,13 @@ if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
message (FATAL_ERROR ">> The ${CMAKE_CXX_COMPILER_ID} compiler version ${CMAKE_CXX_COMPILER_VERSION} is unsupported, requires at least version ${OB_COMPILER_VERSION_GNU}")
endif ()

if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS "9.0.0")
set (OB_LINK_LIBRARIES
${OB_LINK_LIBRARIES}
stdc++fs
)
endif ()

set (OB_FLAGS_GENERAL "-std=c++17 -fdiagnostics-color=auto -fmax-errors=8")

set (OB_FLAGS_DEBUG "-g -Og -rdynamic -Wpedantic -Wall -Wextra -Wcast-align -Wcast-qual -Wctor-dtor-privacy -Wdisabled-optimization -Wformat=2 -Winit-self -Wlogical-op -Wmissing-declarations -Wmissing-include-dirs -Wnoexcept -Wold-style-cast -Woverloaded-virtual -Wredundant-decls -Wshadow -Wsign-conversion -Wsign-promo -Wstrict-null-sentinel -Wstrict-overflow=5 -Wswitch-default -Wundef -Wno-unused")
Expand Down

0 comments on commit ed3d60e

Please sign in to comment.