Repository navigation
feat(tools): add optional Zig BinDiff CLI for ELF32/PRX - #60
Merged
Merged
Conversation
Compare positional byte ranges and ELF32 MIPS/PSP metadata through a standalone Zig 0.17.1 host tool with deterministic JSON and explicit errors. Add synthetic regressions and SHA-256-pinned Windows/Linux CI checks. Verified: 4 unit tests in Debug and safe, 14 CLI tests, safe Windows and Linux cross-builds, host Release build and CTest (18 pass, 6 fixture skips). Closes #59.
endercodezz
marked this pull request as ready for review
November 5, 2026 18:38
This was referenced Nov 5, 2026
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.
Add
p3p-bindiff, an optional Zig 0.17.1 host CLI for positional binary comparison and structural comparison of decrypted ELF32 little-endian MIPS/PSP PRX files. Reports byte counts/ranges and header/segment/section changes in text or deterministic JSON, with exit codes 0/1/2 and malformed-input checks. Entries match by table index; no decryption, relocation normalization or function matching is added.The runtime, Builder and their CMake builds do not depend on Zig.
tools/bindiff/check.pycontains downloads/caches/build outputs in the workspace and verifies pinned official compiler archive SHA-256 values. Add separate Windows/Linux CI jobs using the same checks; only source and synthetic fixture generators are tracked.Verified locally on Windows:
python tools/bindiff/check.py --download: official archive verification/extraction, format check, 4/4 Debug unit tests, 4/4 safe unit tests, safe build and 14/14 CLI regression tests. CLI tests compare actual repeated JSON bytes and 40 seeded file pairs against a Python oracle.x86_64-linuxcross-build passed. Native Windows and Linux BinDiff CI both passed on622dfd3: CI run, including official archive verification, Debug/safe unit tests, safe builds and all 14 CLI regressions. All six CI jobs passed, including existing host/3DS/texpack checks.origin/master(0b4845e) without rewriting history, separate no-game Release host build and fullctest --test-dir build/host -j6 --output-on-failure --no-tests=error: 19 passed, 6 fixture-dependent skips, no failures. All BinDiff checks passed again.git diff --checkand repository precommit gate passed.tools/bindiff/**and verify a cleancore.autocrlf=trueindex checkout with the unchanged Zig formatter, then rerun all BinDiff checks successfully.Closes #59