Skip to content

feat: build wii - #13

Open
BenjaminHalko wants to merge 5 commits into
encounter:mainfrom
BenjaminHalko:feat/build-wii
Open

BenjaminHalko wants to merge 5 commits into
encounter:mainfrom
BenjaminHalko:feat/build-wii

Conversation

@BenjaminHalko

@BenjaminHalko BenjaminHalko commented Mar 31, 2026 •

Copy link
Copy Markdown

Added support for building Wii disks

Please note, I have yet to do thorough testing, the only game I've tested on is Wii Music

@encounter encounter closed this Apr 8, 2026
@encounter encounter reopened this Apr 8, 2026
@encounter

Copy link
Copy Markdown
Owner

Apologies, finger slipped.

Thanks for the PR! This will be useful when I return to the build tooling. It may be a little while until I can review properly and test it out, but it looks good at an initial glance.

I’ve been aiming for being able to rebuild GameCube images 1:1 with the existing logic, does this generate a 1:1 image for Wii Music?

henriquegemignani added a commit to henriquegemignani/nod-rs that referenced this pull request Apr 12, 2026
henriquegemignani added a commit to henriquegemignani/nod-rs that referenced this pull request Apr 12, 2026
encounter pushed a commit that referenced this pull request Apr 15, 2026
* GC fixes from pr #13

* Fix reading boot.bin

* Fix for building gc iso

* Fix game title in apply_overrides

* Format
encounter added a commit that referenced this pull request Jun 3, 2026
* GC fixes from pr #13

* Fix reading boot.bin

* Fix for building gc iso

* Fix game title in apply_overrides

* Format

* Add python binding

* Add DiscWriter

* Update pyo3

* Fix missing callbacks

* Fix process description

* Refuse untyped arguments

* Replace open_disc with just using DiscReader directly

* Add DiscPatcher

* format

* Add support for changing headers

* PyPartitionReader.__repr__

* read_file now opens a file

* Add set_dol

* Rename to nod-rs

* Format

* lock file

* Remove unused import

* Format

---------

Co-authored-by: Luke Street <[email protected]>
Add is_wii-aware accessors and setters for BootHeader user_offset and user_size (Wii stores these fields >> 2) and update GC partition layout and builder to use them. The change introduces BootHeader::user_offset / set_user_offset and user_size / set_user_size, computes is_wii once where needed, and replaces direct .get()/.set() usages so disc size, user_offset initialization, user_size calculation, and junk insertion properly account for Wii formatting.
Keep the caller-provided ticket and TMD intact for 1:1 disc reconstruction: remove zeroing of the RSA signature and TMD content hash update, and add a comment explaining that the supplied metadata already matches the rebuilt encrypted data. Drop the unused sha1 helper import and the zero_signature/update_tmd_content_hash helpers. Also change certificate alignment from 0x40 to 0x20 and simplify the destructuring to avoid mutating ticket/tmd.
Adjust disc/user size calculations to account for Wii sector alignment and compute user_end once. Replace the fragile file-gap heuristic with an explicit large-user-gap check so junk data starts correctly (4-byte aligned) between inner/outer rim files and extends to the next sector boundary on Wii. Always generate H3 entries for every sector group (including all-zero gap groups) rather than skipping zero groups. Remove the unused find_file_gap helper, drop unnecessary imports and tidy module attributes/imports in wii.rs.
@BenjaminHalko

Copy link
Copy Markdown
Author

@encounter Sorry for the delay, but I was able to verify that it is indeed 1 to 1 with iso and wbfs. I tested with Wii Music, Wii Sports, Mario Kart, and Brawl.

@vic1707

vic1707 commented Nov 18, 2026

Copy link
Copy Markdown

Hi, seeing as v2.0.0 alpha got an update 2 months ago, is there an ETA for this ?
would really appreciate to try remaking https://github.com/Asu-chan/RiivolutionIsoBuilder without relying on wit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants