Skip to content

Commit

Permalink
update cmake
Browse files Browse the repository at this point in the history
  • Loading branch information
admercs committed Apr 24, 2024
1 parent 9ca15aa commit 63cb7f4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
2 changes: 1 addition & 1 deletion cmake/cmake-modules/CommonSetup.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ macro(CommonSetup)
${RPC_LIB_DEFINES} ${CMAKE_CXX_FLAGS}")

if(${CMAKE_CXX_COMPILER_ID} MATCHES "Clang")
set(CMAKE_CXX_FLAGS "-stdlib=libc++ -Wno-documentation -Wno-unknown-warning-option ${CMAKE_CXX_FLAGS}")
set(CMAKE_CXX_FLAGS "-Wno-documentation -Wno-unknown-warning-option ${CMAKE_CXX_FLAGS}") # -stdlib=libc++
find_package(LLVM REQUIRED CONFIG)
set(CXX_EXP_LIB "-L${LLVM_LIBRARY_DIRS} -lc++fs -ferror-limit=10")
else()
Expand Down
7 changes: 1 addition & 6 deletions scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -130,14 +130,9 @@ elif [ "$(uname)" = 'Linux' ]; then
export CXX="g++-${GCC_VERSION}"
CMAKE_VARS="-DCXX_STANDARD=c++${CXX_STANDARD}"
else
if (( $(echo "${VERSION_ID} < 22.04" | bc -l) )); then
CMAKE_VARS="-DCXX_STANDARD=c++${CXX_STANDARD} -DCMAKE_CXX_FLAGS=-stdlib=libc++"
else
CMAKE_VARS="-DCXX_STANDARD=c++${CXX_STANDARD}"
fi
export CC="clang-${CLANG_VERSION}"
export CXX="clang++-${CLANG_VERSION}"

CMAKE_VARS="-DCXX_STANDARD=c++${CXX_STANDARD}" # not needed: -DCMAKE_CXX_FLAGS=-stdlib=libc++
fi
else
echo 'ERROR: This build script only supports Linux and MacOS.'
Expand Down

0 comments on commit 63cb7f4

Please sign in to comment.