Fix filesystem on gcc < 9.0
This commit is contained in:
parent
6a09c37893
commit
9a8e5be8ee
@ -1,3 +1,4 @@
|
||||
dist: xenial
|
||||
language: cpp
|
||||
compiler:
|
||||
- gcc
|
||||
|
@ -80,11 +80,10 @@ target_include_directories(Minetestmapper PRIVATE ${LIBGD_INCLUDE_DIR})
|
||||
if(UNIX)
|
||||
find_package(PNG REQUIRED)
|
||||
find_package(Threads REQUIRED)
|
||||
find_library(fs_LIBRARY NAMES stdc++fs)
|
||||
if(fs_LIBRARY)
|
||||
target_link_libraries(Minetestmapper fs_LIBRARY)
|
||||
endif()
|
||||
|
||||
target_link_libraries(Minetestmapper PNG::PNG Threads::Threads ${CMAKE_DL_LIBS})
|
||||
|
||||
target_link_libraries(Minetestmapper $<$<AND:$<CXX_COMPILER_ID:GNU>,$<VERSION_LESS:$<CXX_COMPILER_VERSION>,9.0>>:stdc++fs>)
|
||||
endif()
|
||||
|
||||
# Optional Libraries
|
||||
|
Loading…
x
Reference in New Issue
Block a user