Repository navigation
feat(relinker): support explicit CLI help - #2117
Conversation
|
FYI, #2154 adds an independent Windows diagnostic fixture-isolation CTest in the same Python-enabled block of |
|
This conflicts with main after today's merges; could you rebase? It passed testing and is otherwise ready. |
0cdc998 to
1fc31ba
Compare
|
Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in Depends on.
|
|
The usage guide still says there is no --help flag. This small documentation follow-up corrects that and the help/no-argument exit codes: nyavana@609a1c3 Verified with a Linux relinker build, cli_help, and direct CLI checks. Sharing for consideration. AI-assisted. |
…r-help feat(relinker): support explicit CLI help
What
relinker --helpcurrently fails with an unknown-option error. Recognize--help, print the shared usage text to stdout, and exit successfully before opening input files, writing output or registries, or running the converted executable. A help request does not require input/output paths. Unknown options, missing option values, and incompatible options still fail normally;--helpconsumed as an option value retains its literal meaning.Add a CTest process-level regression test covering the success status/output, existing-output preservation, absence of registry/conversion side effects, and retained parser errors. Short
-hremains a positional argument.Related: #1856 adds parser unit tests but does not implement help. Its existing test source was compiled against this parser and passed. No dependency on #1856.
Tested
Latest publication head
0cdc9988incorporates upstream main745b775ewithout conflicts. Relinker-only Release build and all 38 local CTest tests passed on Apple M2 (5.81 seconds, 30-second per-test timeout), including the merged parser tests andcli_help. Conventions, test registration and whitespace checks passed. Both independent reviewers rechecked the final diff with no actionable findings. Hosted results below apply to the earlier CLI commit, not this updated head.Open overlaps #2119 and #2154 implement separate features and are not dependencies. When integrating those branches, retain centralized usage text with both CLI switches and preserve both independent Python test registrations.
Apple M2 / 16 GB, macOS 27.2, AppleClang 17, CMake 4.4.4, Ninja 1.13.2; based on main
6cc0503d.unknown option: --helpand passes after the change.f765b27ccompiled against this parser and passed.git diff --checkpassed.6e2e076: GitHub-hosted standalone relinker builds/tests passed on macOS, Linux and Windows (run). Full Linux/Windows builds at this commit hit the existing missing SPIR-V header include error, also observed on the upstream baseline.guest_video_out_wqhd_detectionreports missingVK_KHR_surface, prints a skip message, but CTest reports failure despite configured skip return code 77. Its exit behavior remains unresolved. This is a separate executable with no CLI parser/main dependency; no passing full Windows suite is claimed.Checklist
mainat745b775e; overlapping open PRs checked.mdfiles or images added to the repository