From d8a4d7118e410e1bc5ed251ccad38404128df53d Mon Sep 17 00:00:00 2001 From: Mathias Kraus Date: Wed, 8 Jan 2025 01:18:46 +0100 Subject: [PATCH] iox-#1755 Use v18 of clang-format and clang-tidy --- .../install-iceoryx-deps-and-clang/action.yml | 12 ++++++------ .github/workflows/build-test.yml | 18 +++++++++--------- .github/workflows/lint_pull_request.yml | 6 +++--- .github/workflows/nightly.yml | 2 +- tools/scripts/clang_format.sh | 2 +- tools/scripts/clang_tidy_check.sh | 2 +- 6 files changed, 21 insertions(+), 21 deletions(-) diff --git a/.github/actions/install-iceoryx-deps-and-clang/action.yml b/.github/actions/install-iceoryx-deps-and-clang/action.yml index b4fd5e2afc..46f280e9d9 100644 --- a/.github/actions/install-iceoryx-deps-and-clang/action.yml +++ b/.github/actions/install-iceoryx-deps-and-clang/action.yml @@ -7,16 +7,16 @@ runs: run: | sudo dpkg --add-architecture i386 sudo wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - - sudo add-apt-repository "deb http://apt.llvm.org/focal/ llvm-toolchain-focal-15 main" + sudo add-apt-repository "deb http://apt.llvm.org/noble/ llvm-toolchain-noble-18 main" sudo apt-get update sudo apt-get install -y libacl1-dev libncurses5-dev sudo apt-get install -y libacl1-dev:i386 libc6-dev-i386 libc6-dev-i386-cross libstdc++6-i386-cross gcc-multilib g++-multilib - sudo apt-get install -y clang-format-15 clang-tidy-15 clang-tools-15 clang-15 lld + sudo apt-get install -y clang-format-18 clang-tidy-18 clang-tools-18 clang-18 lld sudo rm /usr/bin/clang sudo rm /usr/bin/clang++ sudo rm /usr/bin/clang-tidy sudo rm /usr/bin/clang-format - sudo ln -s /usr/bin/clang-15 /usr/bin/clang - sudo ln -s /usr/bin/clang++-15 /usr/bin/clang++ - sudo ln -s /usr/bin/clang-tidy-15 /usr/bin/clang-tidy - sudo ln -s /usr/bin/clang-format-15 /usr/bin/clang-format + sudo ln -s /usr/bin/clang-18 /usr/bin/clang + sudo ln -s /usr/bin/clang++-18 /usr/bin/clang++ + sudo ln -s /usr/bin/clang-tidy-18 /usr/bin/clang-tidy + sudo ln -s /usr/bin/clang-format-18 /usr/bin/clang-format diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index 42d8925504..824b93fcca 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -13,7 +13,7 @@ jobs: pre-flight-check: # prevent stuck jobs consuming runners for 6 hours timeout-minutes: 60 - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 - name: Install iceoryx dependencies and clang-tidy @@ -25,7 +25,7 @@ jobs: - run: ./tools/ci/cmake-linter.sh check-status-of-nightly-action: - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: pre-flight-check steps: - name: Install dependencies @@ -102,7 +102,7 @@ jobs: # prevent stuck jobs consuming runners for 6 hours timeout-minutes: 60 needs: pre-flight-check - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 - name: Unix (FreeBSD) test @@ -132,7 +132,7 @@ jobs: build-test-ubuntu-with-address-sanitizer-gcc-latest: # prevent stuck jobs consuming runners for 1 hour timeout-minutes: 60 - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: pre-flight-check steps: - uses: egor-tensin/setup-gcc@v1.3 @@ -146,7 +146,7 @@ jobs: build-test-ubuntu-with-address-sanitizer-clang-latest: # prevent stuck jobs consuming runners for 1 hour timeout-minutes: 60 - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: pre-flight-check steps: - name: Checkout @@ -169,7 +169,7 @@ jobs: build-test-ubuntu-with-thread-sanitizer-clang-latest: # prevent stuck jobs consuming runners for 3 hours timeout-minutes: 180 - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: pre-flight-check steps: - name: Checkout @@ -182,7 +182,7 @@ jobs: build-test-ubuntu-32-bit: # prevent stuck jobs consuming runners for 6 hours timeout-minutes: 60 - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: pre-flight-check steps: - name: Checkout @@ -204,7 +204,7 @@ jobs: build-test-ubuntu-32-64-bit-mix-mode: # prevent stuck jobs consuming runners for 6 hours timeout-minutes: 60 - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: pre-flight-check steps: - name: Checkout @@ -217,7 +217,7 @@ jobs: build-test-ubuntu-bazel: # prevent stuck jobs consuming runners for 6 hours timeout-minutes: 60 - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 needs: pre-flight-check steps: - name: Checkout diff --git a/.github/workflows/lint_pull_request.yml b/.github/workflows/lint_pull_request.yml index 137937845e..732f8c4b4e 100644 --- a/.github/workflows/lint_pull_request.yml +++ b/.github/workflows/lint_pull_request.yml @@ -6,7 +6,7 @@ on: jobs: clang-tidy-review: - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - name: Checkout @@ -24,7 +24,7 @@ jobs: run: ./tools/scripts/clang_tidy_check.sh scan_list .clang-tidy-diff-scans.txt "${{ steps.changed_files.outputs.added_modified }}" check-for-todo: - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - name: Checkout @@ -36,7 +36,7 @@ jobs: run: ./tools/ci/todo-verificator.sh verify-links-in-markdown-documentation: - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v4 diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index b5de354795..2def388b04 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -15,7 +15,7 @@ jobs: - run: ./tools/ci/build-test-macos.sh clang-tidy-full-scan: - runs-on: ubuntu-latest + runs-on: ubuntu-24.04 steps: - name: Checkout diff --git a/tools/scripts/clang_format.sh b/tools/scripts/clang_format.sh index 49f16bb96d..6460013e0a 100755 --- a/tools/scripts/clang_format.sh +++ b/tools/scripts/clang_format.sh @@ -29,7 +29,7 @@ fail() { hash git || fail "git not found" # Check if we have at least a specific clang-format version installed -CLANG_FORMAT_VERSION=12 +CLANG_FORMAT_VERSION=18 CLANG_FORMAT_CMD="clang-format-$CLANG_FORMAT_VERSION" if ! command -v $CLANG_FORMAT_CMD &> /dev/null then diff --git a/tools/scripts/clang_tidy_check.sh b/tools/scripts/clang_tidy_check.sh index 32a2fc7ad4..c08fcd2a72 100755 --- a/tools/scripts/clang_tidy_check.sh +++ b/tools/scripts/clang_tidy_check.sh @@ -36,7 +36,7 @@ fail() { exit 1 } -CLANG_TIDY_VERSION=15 +CLANG_TIDY_VERSION=18 CLANG_TIDY_CMD="clang-tidy-$CLANG_TIDY_VERSION" if ! command -v $CLANG_TIDY_CMD &> /dev/null then