-
Notifications
You must be signed in to change notification settings - Fork 39
feat: Added simple Docker build support for Mac/Windows users. #35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,21 @@ | ||||||||||||||||||||||||||
| # syntax=docker/dockerfile:1 | ||||||||||||||||||||||||||
| FROM devkitpro/devkitarm:latest AS root | ||||||||||||||||||||||||||
|
||||||||||||||||||||||||||
| FROM devkitpro/devkitarm:latest AS root | |
| FROM devkitpro/devkitarm:<pinned-tag> AS root |
Copilot
AI
Apr 9, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
apt-get upgrade in the image build increases build time and reduces reproducibility (and can occasionally introduce breaking changes in the toolchain image). Prefer installing only the needed packages with --no-install-recommends and cleaning apt lists, without upgrading the full base image.
| RUN apt-get -y update && apt-get -y upgrade && \ | |
| apt-get -y install \ | |
| build-essential \ | |
| git \ | |
| zip \ | |
| ; | |
| RUN apt-get -y update && \ | |
| apt-get -y install --no-install-recommends \ | |
| build-essential \ | |
| git \ | |
| zip \ | |
| && rm -rf /var/lib/apt/lists/* |
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -39,17 +39,44 @@ The overlay can be used to change the config options and to see what patches are | |||||
|
|
||||||
| ## Building | ||||||
|
|
||||||
| ### prerequisites | ||||||
| - Install [devkitpro](https://devkitpro.org/wiki/Getting_Started) | ||||||
| - Run the following: | ||||||
| ```sh | ||||||
| git clone --recurse-submodules https://github.com/ITotalJustice/sys-patch.git | ||||||
| cd ./sys-patch | ||||||
| make | ||||||
| ``` | ||||||
|
|
||||||
| The output of `out/` can be copied to your SD card. | ||||||
| To activate the sys-module, reboot your switch, or, use [sysmodules overlay](https://github.com/WerWolv/ovl-sysmodules/releases/latest) with the accompanying overlay to activate it. | ||||||
| ### Clone with submodules | ||||||
|
|
||||||
| Clone this repository (with submodules), and move into the project directory. | ||||||
|
|
||||||
| ```sh | ||||||
| git clone --recurse-submodules https://github.com/ITotalJustice/sys-patch.git | ||||||
| cd ./sys-patch | ||||||
| ``` | ||||||
|
|
||||||
| If you cloned, but forgot the submodules, you can install them after-the-fact. | ||||||
|
|
||||||
| ```sh | ||||||
| # git clone --recurse-submodules https://github.com/ITotalJustice/sys-patch.git | ||||||
| # cd ./sys-patch | ||||||
|
|
||||||
| git submodule init | ||||||
| git submodule update | ||||||
| ``` | ||||||
|
|
||||||
| ### With Docker | ||||||
|
|
||||||
| 1. Install [Docker Desktop](https://docker.com/desktop) (for Mac/Windows). | ||||||
| 1. Run: | ||||||
|
|
||||||
| ```sh | ||||||
| docker compose up --build | ||||||
|
||||||
| docker compose up --build | |
| docker compose run --rm syspatch |
Copilot
AI
Apr 9, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This instruction likely points to the wrong toolchain for Nintendo Switch builds. The project uses libnx/switch_rules and -march=armv8-a... (AArch64), so users typically need devkitPro with devkitA64 (not devkitARM). Updating the wording here will prevent failed local builds.
| 1. Install [devkitARM](https://devkitpro.org/wiki/Getting_Started). | |
| 1. Install [devkitPro with devkitA64](https://devkitpro.org/wiki/Getting_Started). |
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,6 @@ | ||||||||
| services: | ||||||||
| syspatch: | ||||||||
| build: | ||||||||
| context: . | ||||||||
|
||||||||
| context: . | |
| context: . | |
| user: "${UID:-1000}:${GID:-1000}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The base image
devkitpro/devkitarmis for 32-bit ARM and doesn’t match this project’s Switch/libnx toolchain (AArch64). CI builds indevkitpro/devkita64(see.github/workflows/build-jobs.yaml:11), and bothsysmod/Makefileandoverlay/Makefileinclude$(DEVKITPRO)/libnx/switch_rulesand targetarmv8-a. Update the Dockerfile to use thedevkita64image soswitch-devand the AArch64 compiler are available and the Docker build succeeds.