ci: add Linux build-only job for libtotapi_mono.so (#204)#205
Merged
Conversation
Adds a new `mono-build` job to python-tests.yml that exercises the Linux ld branch of the libtotapi_mono.so target on every PR. Until now the mono target (landed in PR #202) had only been built on macOS arm64; the Linux SO_SONAME / SO_GROUP_BEGIN/END / SO_UNDEFINED branches were unverified. Job structure: 1. Same setup chain as the existing pytest job (BPSD clone, make.header, mtxp/make.mtxp, PIC support libs). The make.header heredoc is duplicated verbatim from the pytest job; both heredocs carry a "KEEP IN SYNC" cross-reference comment so a future flag drift (e.g. OFLAGS change) doesn't silently produce divergent binaries from the two CI paths. 2. Build the 5 per-module .so files that libtotapi_mono.so's $(LIBS_PIC_SO) prereq triggers (eq tr fp ti wrx), plus wr for symmetry with the pytest job's loop. NOT tot/libtotapi.so — this job is scoped to mono-only validation. 3. `make -C tot libtotapi_mono.so` — first Linux exercise. 4. `make -C tot libtotapi_mono_inspect` — hard-fails if the 8-bpsd-storage-symbol invariant drifts. The "no lib*api.so deps" check inside the inspect target prints `ldd`/`otool` output for visual inspection but is NOT a hard exit-code gate yet (can be tightened in a follow-up once the regex is standardized across Linux/macOS output formats). Scope: BUILD ONLY. The 1e-10 equivalence and Layer-C BPSD smoke tests against the mono build are blocked on the unified tot_graphics_stubs_mono.f90 source that #201 Phase 2a will introduce. This PR keeps the validation surface aligned with what is currently buildable. Setup duplication between the `pytest` and `mono-build` jobs (BPSD clone, make.header, mtxp config, PIC libs, per-module .so loop) is intentional — pulling these into a composite action is a separate refactor opportunity not coupled to this small PR. The MED-level drift risk it creates is mitigated by the cross-reference comments on the duplicated steps. Closes #204. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Owner
Author
|
@cursor review |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit a9f6743. Configure here.
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.
Summary
Adds a new
mono-buildCI job exercising the Linux ld branch of the L-7b-ii monolithic Makefile target (libtotapi_mono.so). Until now PR #202's mono target had only been macOS-verified; this PR catches Linux linker incompatibilities before #201 (Phase 2a) starts depending on them.Closes #204.
Scope: BUILD ONLY
The 1e-10 equivalence and Layer-C BPSD smoke tests against the mono build are deferred to #201 (blocked on the unified
tot/tot_graphics_stubs_mono.f90source that #201 Phase 2a introduces). This PR validates:make -C tot libtotapi_mono.soexits 0make -C tot libtotapi_mono_inspect(HARD GATE inside that target — exit 1 if count != 8)lib*api.soruntime depsldd/otooloutput, NOT a hard exit gate — to be tightened once Linux/macOS regex is standardized)Setup duplication acknowledged
The new
mono-buildjob duplicates ~80 lines of setup (BPSD clone,make.header, mtxp config, PIC support libs, per-module .so loop) from the existingpytestjob. Both reviewers flagged this as a real drift risk (a flag change in one and not the other = silent CI-green on divergent binaries).Mitigation in this PR: explicit "KEEP IN SYNC" cross-reference comments on the duplicated steps (notably the
make.headerheredocs).Long-term: extract to a composite action under
.github/actions/— separate refactor opportunity, not coupled to this small PR.Reviewer trail
ef15ecb2→ 1 MED (make.headerdrift risk) + 5 LOW. All addressed in amenda9f67431.ef15ecb2→ "approve, ship" + 2 doc notes (5-vs-6 count, observational vs gate). Both addressed in amenda9f67431.a9f67431: both LGTM.Test plan
python -c "import yaml; yaml.safe_load(...)")🤖 Generated with Claude Code
Note
Medium Risk
Medium risk due to CI pipeline expansion that performs a full Fortran build/link on Linux and depends on an external
bpsdclone, which can introduce new CI failures or longer runtimes.Overview
Adds a new GitHub Actions
mono-buildjob that builds on Linux only the monolithictotshared library targetlibtotapi_mono.so, including its PIC support libraries and required per-module.soprerequisites.The job then runs
make -C tot libtotapi_mono_inspectto hard-gate the BPSD symbol dedup invariant (expects 8 storage symbols) and prints additional inspection output, and the existing pytest job now includes explicit comments to keep the duplicatedmake.headerheredoc in sync with the new job.Reviewed by Cursor Bugbot for commit a9f6743. Bugbot is set up for automated code reviews on this repo. Configure here.