Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CI] Make cmake.c++20*.test actualy use C++20 and add cmake.c++23*.test #2496

Merged
merged 3 commits into from
Jan 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 53 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,59 @@ jobs:
CXX_STANDARD: '20'
run: ./ci/do_ci.sh cmake.c++20.stl.test

cmake_test_cxx23_gcc:
name: CMake C++23 test(GCC)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: setup
env:
CMAKE_VERSION: 3.20.6
run: |
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/setup_cmake.sh
- name: run tests
env:
CXX_STANDARD: '23'
run: ./ci/do_ci.sh cmake.c++23.test
- name: run tests (enable stl)
env:
CXX_STANDARD: '23'
run: ./ci/do_ci.sh cmake.c++23.stl.test

cmake_test_cxx23_clang:
name: CMake C++23 test(Clang with libc++)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: setup
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
CXXFLAGS: "-stdlib=libc++"
CMAKE_VERSION: 3.20.6
run: |
sudo -E ./ci/setup_ci_environment.sh
sudo -E ./ci/setup_cmake.sh
- name: run tests
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
CXXFLAGS: "-stdlib=libc++"
CXX_STANDARD: '23'
run: ./ci/do_ci.sh cmake.c++23.test
- name: run tests (enable stl)
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
CXXFLAGS: "-stdlib=libc++"
CXX_STANDARD: '23'
run: ./ci/do_ci.sh cmake.c++23.stl.test

cmake_otprotocol_test:
name: CMake test (with otlp-exporter)
runs-on: ubuntu-20.04
Expand Down
28 changes: 27 additions & 1 deletion ci/do_ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,19 @@ elif [[ "$1" == "cmake.c++20.test" ]]; then
cmake ${CMAKE_OPTIONS[@]} \
-DCMAKE_CXX_FLAGS="-Werror $CXXFLAGS" \
-DWITH_ASYNC_EXPORT_PREVIEW=ON \
-DWITH_STL=CXX20 \
owent marked this conversation as resolved.
Show resolved Hide resolved
${IWYU} \
"${SRC_DIR}"
eval "$MAKE_COMMAND"
make test
exit 0
elif [[ "$1" == "cmake.c++23.test" ]]; then
cd "${BUILD_DIR}"
rm -rf *
cmake ${CMAKE_OPTIONS[@]} \
-DCMAKE_CXX_FLAGS="-Werror $CXXFLAGS" \
-DWITH_ASYNC_EXPORT_PREVIEW=ON \
-DWITH_STL=CXX23 \
owent marked this conversation as resolved.
Show resolved Hide resolved
${IWYU} \
"${SRC_DIR}"
eval "$MAKE_COMMAND"
Expand Down Expand Up @@ -267,7 +280,20 @@ elif [[ "$1" == "cmake.c++20.stl.test" ]]; then
-DWITH_METRICS_EXEMPLAR_PREVIEW=ON \
-DCMAKE_CXX_FLAGS="-Werror $CXXFLAGS" \
-DWITH_ASYNC_EXPORT_PREVIEW=ON \
-DWITH_STL=ON \
-DWITH_STL=CXX20 \
owent marked this conversation as resolved.
Show resolved Hide resolved
${IWYU} \
"${SRC_DIR}"
eval "$MAKE_COMMAND"
make test
exit 0
elif [[ "$1" == "cmake.c++23.stl.test" ]]; then
cd "${BUILD_DIR}"
rm -rf *
cmake ${CMAKE_OPTIONS[@]} \
-DWITH_METRICS_EXEMPLAR_PREVIEW=ON \
-DCMAKE_CXX_FLAGS="-Werror $CXXFLAGS" \
-DWITH_ASYNC_EXPORT_PREVIEW=ON \
-DWITH_STL=CXX23 \
owent marked this conversation as resolved.
Show resolved Hide resolved
${IWYU} \
"${SRC_DIR}"
eval "$MAKE_COMMAND"
Expand Down