Skip to content

CI: fail when an example or test build fails (osx, linux64, msys2) - #8590

Open
danoli3 wants to merge 1 commit into
openframeworks:masterfrom
danoli3:ci-fail-on-build-errors
Open

danoli3 wants to merge 1 commit into
openframeworks:masterfrom
danoli3:ci-fail-on-build-errors

Conversation

@danoli3

@danoli3 danoli3 commented Oct 15, 2026

Copy link
Copy Markdown
Member

Problem

build-macos (osx, makefiles) is green on master, but allAddonsExample fails to link in it. From master's run on 13 Oct:

Undefined symbols for architecture arm64:
  "kleidicv::hal::bgr_to_bgr(...)", referenced from: ... in opencv.a
clang++: error: linker command failed with exit code 1
make[1]: *** [bin/allAddonsExample_debug] Error 1

The projectGenerator CI builds the same project with Xcode and fails, which is how this showed up.

scripts/ci/osx/run_tests.sh, linux64/run_tests.sh and msys2/run_tests.sh all have set -e commented out (since #7947):

  • osx: the emptyExample and allAddonsExample builds aren't checked at all.
  • linux64 / msys2: a failed test build only shows up later, as a missing binary.

Change

Each make in those scripts goes through build_or_fail. If a build fails, it stops the job with a GitHub error annotation naming it:

::error title=Build failed::make -j2 Debug failed in examples/templates/allAddonsExample

The tests' own exit-code checks are unchanged.

Expected result

build-macos (osx, makefiles) will fail on this PR until the macOS OpenCV package is fixed in apothecary. Its opencv.a uses KleidiCV, but libkleidicv isn't in the xcframework. The fix is to build it with -DWITH_KLEIDICV=OFF, or to ship libkleidicv. That failure is the point: it has been hidden until now.

scripts/ci/{osx,linux64,msys2}/run_tests.sh have set -e commented out,
so a failed make didn't fail the job. On osx the emptyExample and
allAddonsExample builds weren't checked at all: allAddonsExample has been
failing to link on master (undefined kleidicv:: symbols from the macOS
OpenCV package) while build-macos (osx, makefiles) stayed green. On linux64
and msys2 a failed test build only showed up later as a missing binary.

Each make now goes through build_or_fail, which stops the job and adds a
GitHub error annotation naming the build. The tests' own exit code checks
are unchanged.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant