mirror of
https://github.com/ps5-linux/ps5-linux-image.git
synced 2026-07-18 03:50:55 +00:00
Each distro ships with a self-contained build-rootfs.sh that the entrypoint
calls in place of distrobuilder. This keeps upstream's distrobuilder flow
untouched for the existing distros (ubuntu/arch/cachyos/fedora/etc.) and
isolates the new distros' build logic in their own dirs.
distros/bazzite/
build-rootfs.sh — skopeo+umoci on ghcr.io/ublue-os/bazzite:stable,
promote ostree /usr/etc -> /etc, install linux-ps5 RPM,
mask rpm-ostree services, set up grow-rootfs + DTM-TA
amdgpu reprobe.
image.yaml, grow-rootfs, grow-rootfs.service
distros/bazzite-deck/
Symlinks into distros/bazzite/ — bazzite-deck shares all build logic;
the case branch in build-rootfs.sh dispatches via $DISTRO.
distros/batocera/
build-rootfs.sh — download upstream batocera-x86_64-*.img.gz, mount,
extract /boot/batocera squashfs, swap in linux-ps5
kernel, patch libretroControllers.py, install first-boot
SHARE-partition creator (ps5-share-init).
docker/image-builder/entrypoint.sh
- detect_kver() helper from /kernel-debs/ package filenames
- dispatch to distros/$DISTRO/build-rootfs.sh when present (skips
distrobuilder for that distro)
- EFI assembly detects /boot/efi/ vs /boot/bzImage layouts so batocera
(which mounts FAT at /boot, not /boot/efi, for batocera-part SHARE
detection) works alongside the standard layout
build_image.sh
- IMG_SIZE defaults: bazzite* -> 24 GB, batocera* -> 16 GB
- FORMAT: bazzite* -> rpm (linux-ps5 RPM); batocera* stays deb
CI workflows are NOT modified — the upstream build-image.yml /
trigger-builds.yml continue to apply and will skip these distros unless
explicitly dispatched (they're not in MULTI_DISTROS). Local builds:
./build_image.sh --distro bazzite
./build_image.sh --distro bazzite-deck
./build_image.sh --distro batocera
Co-authored-by: mia26MAjFm <mia26MAjFm@users.noreply.github.com>
29 lines
1.1 KiB
Markdown
29 lines
1.1 KiB
Markdown
# batocera
|
|
|
|
Adds support for [Batocera](https://batocera.org/) (Buildroot-based
|
|
retro-emulation distro) on PS5 hardware.
|
|
|
|
Batocera ships as an `.img.gz` with FAT32 boot + ext4 SHARE partitions; the
|
|
OS itself lives in a squashfs at `/boot/batocera`.
|
|
`distros/batocera/build-rootfs.sh` downloads + unsquashes that image and
|
|
swaps in the linux-ps5 kernel:
|
|
|
|
1. Download `https://mirrors.o2switch.fr/batocera/x86_64/stable/last/`
|
|
2. Loop-mount the FAT32, find the embedded squashfs
|
|
3. `unsquashfs` to `$CHROOT`
|
|
4. Extract the linux-ps5 `.deb`'s `vmlinuz` → `/boot/bzImage`
|
|
5. Patch `libretroControllers.py` (PS5 controller-mapping fix)
|
|
6. Set up first-boot SHARE partition creator (`ps5-share-init`)
|
|
7. Write fstab with `/boot vfat` (NOT `/boot/efi` — batocera-part's
|
|
SHARE auto-detection greps `/proc/mounts` for `/boot`)
|
|
|
|
## Build locally
|
|
|
|
```bash
|
|
./build_image.sh --distro batocera
|
|
```
|
|
|
|
Image size: 16 GB default (Batocera unsquashes to ~6 GB; headroom for
|
|
/userdata). Override the batocera release with `BATOCERA_VER` /
|
|
`BATOCERA_BUILD` envs (defaults track the upstream "last" channel).
|