Skip to content

ci: Keep mirrored hidden-symbol list changes on Linux - #2292

Merged
zackees merged 2 commits into
masterfrom
ci/hidden-symbol-scope
Oct 25, 2026
Merged

zackees merged 2 commits into
masterfrom
ci/hidden-symbol-scope

Conversation

@zackees

@zackees zackees commented Oct 25, 2026

Copy link
Copy Markdown
Member

Refs #2288

Why

Between 2026-10-17 and 2026-10-24, 98 of 123 merged port PRs started the macOS and Windows lanes, about 9–10 min each in the merge queue. The main reason is that each port edits libobs/cmake/rust-hidden.txt, rust-exports.map and rust-unexports-macos.txt to hide its non-EXPORT shims. All of libobs/cmake/ counts as shared.

Those three files list one inventory of hidden symbols, written once per linker:

  • Windows never reads them. Its exports come from rust-exports.d/ only.
  • macOS hides names with -unexported_symbols_list, and that list already contains Linux-only names (_dbus_*, _portal_*). An extra name is harmless there.
  • Linux checks that the three agree. rust/obs-util/tests/platform/export_list.rs fails when a hidden name is missing from the map's local: section or from the macOS list.

Change

ci_scope.py compares the three lists against the merge base. If they add or drop the same plain names and nothing else changes, they no longer select macOS or Windows. Comments may change too.

These still count as shared and start every platform:

  • wildcards (_ZN*, _R*);
  • a global: or section edit;
  • names that differ between the lists;
  • rust-exports.d/ fragments, which do change the Windows exports;
  • every other libobs/cmake file.

Nightly and release runs still build every platform.

Evidence

  • RED (ci: Test that a mirrored…): ci/test_hidden_symbol_scope.py fails 3 of its 7 tests against the stub.
  • GREEN: all 7 pass, and test_ci_scope and test_master_push_scope are unchanged and still pass.
  • Replay of history: I replayed every merge since 2026-10-17 that touched the lists.
    • All 64 were mirrored.
    • 49 would have run Linux-only, saving the macOS and Windows lanes on each one in both PR CI and the queue.
    • The other 15 also touched another shared file (build.rs, platform/mod.rs, C++ tests).
  • ./lint: one unrelated local failure. test_local_gate_probe fails because of a soldr broker version mismatch on this machine.

A port hides its non-EXPORT shims by adding one name to rust-hidden.txt,
rust-exports.map (local:) and rust-unexports-macos.txt. Windows reads none
of these, macOS already lists names it lacks, and rust/obs-util's
export_list test checks on Linux that the three agree. When the three add
or drop the same plain names and nothing else changes, they no longer
start the macOS and Windows lanes. Wildcards, sections and exported
fragments (rust-exports.d) stay shared.

Refs #2288
@zackees
zackees added this pull request to the merge queue Oct 25, 2026
Merged via the queue into master with commit ff9adbf Oct 25, 2026
30 checks passed
@zackees
zackees deleted the ci/hidden-symbol-scope branch October 26, 2026 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant