Skip to content

Commit

Permalink
trying to use clang-16 on ubuntu
Browse files Browse the repository at this point in the history
  • Loading branch information
K20shores committed Dec 17, 2023
1 parent 686b61c commit 93e48ad
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 9 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,14 @@ jobs:
strategy:
matrix:
build_type: [Release]
env:
CC: clang
CXX: clang++
steps:
- name: Install Clang 16
run: |
sudo apt-get update
sudo apt-get install -y clang-16
sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-16 100
sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-16 100
- name: Checkout code
uses: actions/checkout@v3

Expand Down
6 changes: 0 additions & 6 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,6 @@ set(CMAKE_CXX_EXTENSIONS OFF)

include(cmake/dependencies.cmake)

# on ubuntu with clang, an incorrect version of the c++ standard library was being linked
if (${CMAKE_HOST_SYSTEM_NAME} MATCHES "Linux" AND "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
# If the compiler is Clang, use libc++
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libstdc++")
endif()

################################################################################
# targets

Expand Down

0 comments on commit 93e48ad

Please sign in to comment.