ci: fix coverage cgo runtime loading - #429
Closed
XuPeng-SH wants to merge 1 commit into
Closed
Conversation
7 tasks
Contributor
Author
|
Closing after the #27480 scope correction. The native/CGo link-contract changes were removed from matrixorigin/matrixone#27480, which now uses the existing main CI contract and does not require this companion workflow change. Native dependency-closure hardening can return as a separately scoped MatrixOne + CI change. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this fixes
MatrixOne coverage UT linked every CGo test binary against the checkout-local
libmo.so, but only embedded the third-party library directory in ELFRUNPATH. Go executes test binaries under/tmp/go-build..., so the dynamic loader could not findlibmo.soand the complete coverage run failed before tests started.This change:
$GITHUB_WORKSPACE/cgoandthirdparties/install/libin the temporary test binaries runtime search path;cgo/lib.goinstead of maintaining another partial hard-coded library list;-lmobefore its queried dependency closure.Verification
Using PR matrixorigin/matrixone#27480 source in a clean Linux/arm64 container with
LD_LIBRARY_PATHunset:RUNPATHomitted/workspace/cgo, execution failed with status 127 (libmo.sonot found);RUNPATHincluded/workspace/cgo, execution passed with status 0.Also checked with actionlint (excluding the workflows existing custom-runner/context diagnostics), YAML parsing, and
git diff --check.Related: matrixorigin/matrixone#27480.