fix(tests): name the raise-exception test's signal so macOS builds it #12076
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/12076"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by 011010 on 2026-10-27T19:19:30Z.
What
guest_raise_exception_testsstops a full macOS build withBUILD_TESTING=ON, and no open pull request covers it:The test declares
static constexpr int SIGUSR1 = 30;(fromdd2890c1c5). On Windows and Linux that name is free in this translation unit; on macOS the SDK definesSIGUSR1as a macro in<sys/signal.h>, which libc++ reaches through<stdlib.h>→<sys/wait.h>, so the declaration expands tostatic constexpr int 30 = 30;.Rename it to
GUEST_SIGUSR1, the nameGuestPthreadCreateSuspended.cpp:18andGuestSignalList.cpp:10-13already use. The value and all 28 uses stay the same, so no behaviour changes.GuestRaiseNestedSleep.cpphas the same declaration but its target is insideif(WIN32)(libkernel/CMakeLists.txt:1205), so it never reaches a macOS build and is left alone.Tested
mainc547deaacb,-DBUILD_TESTING=ON -DCMAKE_OSX_ARCHITECTURES=x86_64.GuestRaiseException.cpp:21:22: error: expected unqualified-id, as quoted above.guest_raise_exception_testsstill does not link onmain:libkernelneeds #7631, #7804, #10552 and #11249 to build on macOS, so this removes one object that stops the build and nothing more.python3 tools/check_conventions.py --base origin/main: all conventions checks passed.python3 tools/pr_overlap.py --branch fix/macos-raise-exception-signal-name: no overlap with open pull requests.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-27T19:27:48Z.
Review: APPROVED
Reviewed exact head
76c419a572. The change consistently renames the test's guest signal constant to GUEST_SIGUSR1, avoiding the macOS SDK macro collision while preserving the value and all call sites. The author reports that the exact x86-64 macOS object, which failed before the rename, now compiles; this is the relevant verification because the Windows and Linux signal name was not conflicting. Hosted Windows and conventions checks pass, and the current-main merge preview and diff check are clean. No test behavior changed. Approved.Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-27T20:41:28Z.
Review: CHANGES_REQUESTED
I had approved this exact head earlier after reviewing the rename and the reported macOS compile check. The later overlap report flagged shared edits to GuestRaiseException.cpp. I checked the current heads: this PR merges cleanly with main by itself, but pairwise merge-tree checks conflict when combined with both open #11872 and open #11969. Please coordinate an order and declare the required Depends on entries (or rebase after those changes land) so the macro rename is not lost during integration. No issue with the rename itself.
Imported from boykopovar/AnyPS5. Originally posted by THEMANnt on 2026-10-28T05:01:39Z.
Review: APPROVED
Reviewed
76c419a5728dd4b4b992636a50b5fb7d8ab6be30— approve. The guest signal constant avoids the host SIGUSR1 macro without changing its value or uses.Windows/GCC 15.2: compiling the exact source with SIGUSR1 defined as 30 passes on head and fails at the constant declaration on base, reproducing the macro collision independently of Apple headers. An exact token-renaming comparison confirms the identifier rename is the only source change, including all uses. This is a syntax/control check, not a macOS SDK build or exception-runtime test. Hosted Build reports success.
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-29T07:28:43Z.
Review: CHANGES_REQUESTED
Re-check — changes still requested
The old references to #11872 and #11969 are no longer actionable because both are closed. Their replacement PRs #12682 and #12688 are open and now conflict with this PR in
GuestRaiseException.cpp; #4630 also remains open and conflicts in that file and the debt document. The current code-only fix still builds according to the author, but its merge order has not been recorded for the current open PRs.What I checked
mainand ran pairwise merge previews with #12682, #12688, and #4630.git diff --check; no local build/test was run.Results
git diff --checkGuestRaiseException.cppGuestRaiseException.cppGuestRaiseException.cppanddocs/dev/debt/libkernel.mdUnedited local merge-check output
Findings
Blocking
Please agree an order with the authors of the currently open #12682, #12688 and #4630, then record it in the relevant
Depends onchecklists or explain the chosen direct rebase strategy. The previous #11872/#11969 conflict report is obsolete; the replacements are separate open PRs, so resolve against their current heads.Non-blocking
I found no new issue with the signal-constant rename itself. The author reports the current head removes this test file from the macOS compile failures. The reported full macOS build still has unrelated failures.
Sources
76c419a5728dd4b4b992636a50b5fb7d8ab6be30mainedf6804cf52c62eacafc592dd6142cb4efe5bd05Not verified
I did not independently reproduce the author’s macOS build results.