mirror of
https://git.mirrors.martin98.com/https://github.com/gulrak/filesystem
synced 2025-07-24 00:34:28 +08:00
stop linking std::filesystem tests against libc++fs on clang 9
This commit is contained in:
parent
8facfa0044
commit
e7169c4943
@ -7,14 +7,18 @@ if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang" AND (CMAKE_CXX_COMPILER_VERSION
|
||||
endif()
|
||||
add_executable(${targetName} ${ARGN})
|
||||
set_property(TARGET ${targetName} PROPERTY CXX_STANDARD 17)
|
||||
if (CMAKE_CXX_COMPILER_VERSION VERSION_LESS 9.0)
|
||||
if(APPLE)
|
||||
target_link_libraries(${targetName} -lc++fs)
|
||||
else()
|
||||
target_compile_options(${targetName} PRIVATE "-stdlib=libc++")
|
||||
target_link_libraries(${targetName} -stdlib=libc++ -lc++fs)
|
||||
endif()
|
||||
|
||||
target_link_libraries(${targetName} -lc++fs)
|
||||
else()
|
||||
if(NOT APPLE)
|
||||
target_link_libraries(${targetName} -stdlib=libc++)
|
||||
endif()
|
||||
endif()
|
||||
target_compile_definitions(${targetName} PRIVATE USE_STD_FS)
|
||||
endif()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user