Skip to content

Commit

Permalink
CMakeLists: use --stdlib=libc++ on macOS only with clang
Browse files Browse the repository at this point in the history
  • Loading branch information
barracuda156 authored and hatstand committed Jul 22, 2024
1 parent 1506c27 commit 43826d9
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,9 @@ set(CMAKE_EXPORT_COMPILE_COMMANDS ON CACHE INTERNAL "")
if (CMAKE_CXX_COMPILER MATCHES ".*clang")
set(CMAKE_COMPILER_IS_CLANGXX 1)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-uninitialized")
endif ()

if (APPLE)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --stdlib=libc++")
if (APPLE)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --stdlib=libc++")
endif ()
endif ()

find_program(CCACHE_EXECUTABLE NAMES ccache)
Expand Down

0 comments on commit 43826d9

Please sign in to comment.