Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/windirstat/llfio.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNiall Douglas (s [underscore] sourceforge {at} nedprod [dot] com) <spamtrap@nedprod.com>2020-03-13 15:02:52 +0300
committerNiall Douglas (s [underscore] sourceforge {at} nedprod [dot] com) <spamtrap@nedprod.com>2020-03-13 15:02:52 +0300
commit9bac4699b037471bc113581058a660f66ddf4c5a (patch)
tree3c0376976fa0d3ef6906a40cc2624b4c40f9d6c6 /CMakeLists.txt
parentc43ec836bce574fbd7b11203d021b6ee634cfed4 (diff)
Fix libc++ issues #52 (outdated <filesystem>) and #49 (char8_t)
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt8
1 files changed, 8 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5f400628..325a4c62 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -196,6 +196,14 @@ if(CMAKE_SYSTEM_NAME MATCHES "Linux")
endif()
endif()
if(CMAKE_SYSTEM_NAME MATCHES "FreeBSD" OR APPLE)
+ if(CLANG_VERSION_MAJOR GREATER_EQUAL 9)
+ # Do nothing, it's built in
+ elseif(CLANG_VERSION_MAJOR GREATER_EQUAL 7)
+ find_library(libcxx_cxxfs c++fs)
+ all_link_libraries(PUBLIC ${libcxx_cxxfs})
+ endif()
+ # Link in experimental always. If library is in C++ 14, or older LLVM, experimental filesystem will be used.
+ # If libc++fs or built-in filesystem is used, this link will be discarded.
find_library(libcxx_cxxexperimental c++experimental)
all_link_libraries(PUBLIC ${libcxx_cxxexperimental})
endif()