[llvm] [premerge] Route macOS build through a monolithic script to enable Job Summary (PR #211565)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 23 07:50:06 PDT 2026
llvmorg-github-actions[bot] wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-github-workflow
Author: Arseniy Obolenskiy (aobolensk)
<details>
<summary>Changes</summary>
The macOS premerge job built inline instead of via a `monolithic-*.sh` script, so it never emitted a GitHub Job Summary or JUnit XML like Linux/Windows do on failure
---
Full diff: https://github.com/llvm/llvm-project/pull/211565.diff
2 Files Affected:
- (added) .ci/monolithic-macos.sh (+40)
- (modified) .github/workflows/premerge.yaml (+3-18)
``````````diff
diff --git a/.ci/monolithic-macos.sh b/.ci/monolithic-macos.sh
new file mode 100755
index 0000000000000..37f20610440f6
--- /dev/null
+++ b/.ci/monolithic-macos.sh
@@ -0,0 +1,40 @@
+#!/usr/bin/env bash
+#===----------------------------------------------------------------------===##
+#
+# Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+# See https://llvm.org/LICENSE.txt for license information.
+# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
+#
+#===----------------------------------------------------------------------===##
+
+#
+# This script performs a monolithic build of the monorepo and runs the tests of
+# most projects on macOS. This should be replaced by per-project scripts that
+# run only the relevant tests.
+#
+
+source .ci/utils.sh
+
+projects="${1}"
+targets="${2}"
+
+start-group "CMake"
+
+xcrun cmake -G Ninja \
+ -B "${BUILD_DIR}" \
+ -S "${MONOREPO_ROOT}"/llvm \
+ -D LLVM_ENABLE_PROJECTS="${projects}" \
+ -D LLVM_DISABLE_ASSEMBLY_FILES=ON \
+ -D CMAKE_BUILD_TYPE=Release \
+ -D LLDB_INCLUDE_TESTS=OFF \
+ -D LLVM_ENABLE_ASSERTIONS=ON \
+ -D LLVM_LIT_ARGS="-v --xunit-xml-output ${BUILD_DIR}/test-results.xml --use-unique-output-file-name --timeout=1200 --time-tests --succinct" \
+ -D CMAKE_C_COMPILER_LAUNCHER=sccache \
+ -D CMAKE_CXX_COMPILER_LAUNCHER=sccache
+
+start-group "ninja"
+
+if [[ -n "${targets}" ]]; then
+ ninja -C "${BUILD_DIR}" ${targets} |& tee ninja.log
+ cp ${BUILD_DIR}/.ninja_log ninja.ninja_log
+fi
diff --git a/.github/workflows/premerge.yaml b/.github/workflows/premerge.yaml
index e1ef62ed3904c..b48f719b75ec9 100644
--- a/.github/workflows/premerge.yaml
+++ b/.github/workflows/premerge.yaml
@@ -290,29 +290,14 @@ jobs:
PROJECTS: ${{ needs.premerge-compute-macos.outputs.macos-projects }}
CHECK_TARGETS: ${{ needs.premerge-compute-macos.outputs.macos-check-targets }}
CLANG_TOOLCHAIN_PROGRAM_TIMEOUT: 120
+ GITHUB_TOKEN: ${{ github.token }}
+ GITHUB_PR_NUMBER: ${{ github.event.pull_request.number }}
run: |
export SCCACHE_IDLE_TIMEOUT=0
mkdir -p artifacts
SCCACHE_LOG=info SCCACHE_ERROR_LOG=$(pwd)/artifacts/sccache.log sccache --start-server
- xcrun cmake -G Ninja \
- -B build \
- -S llvm \
- -DLLVM_ENABLE_PROJECTS="${PROJECTS}" \
- -DLLVM_DISABLE_ASSEMBLY_FILES=ON \
- -DCMAKE_BUILD_TYPE=Release \
- -DLLDB_INCLUDE_TESTS=OFF \
- -DLLVM_ENABLE_ASSERTIONS=ON \
- -DCMAKE_C_COMPILER_LAUNCHER=sccache \
- -DCMAKE_CXX_COMPILER_LAUNCHER=sccache
-
- ninja -C build ${CHECK_TARGETS}
- - name: Show sccache stats
- if: always()
- run: |
- mkdir -p artifacts
- sccache --show-stats
- sccache --show-stats >> artifacts/sccache_stats.txt
+ ./.ci/monolithic-macos.sh "${{ needs.premerge-compute-macos.outputs.macos-projects }}" "${{ needs.premerge-compute-macos.outputs.macos-check-targets }}"
- name: Upload Artifacts
# In some cases, Github will fail to upload the artifact. We want to
# continue anyways as a failed artifact upload is an infra failure, not
``````````
</details>
https://github.com/llvm/llvm-project/pull/211565
More information about the llvm-commits
mailing list