Skip to content

rk3568 baseline build (vanilla) — dosbox-x ffmpeg 8.1.2 fix + sanity-check build log - #2

Draft
Pyohwan wants to merge 2 commits into
masterfrom
fix-dosbox-x-ffmpeg8-api
Draft

rk3568 baseline build (vanilla) — dosbox-x ffmpeg 8.1.2 fix + sanity-check build log#2
Pyohwan wants to merge 2 commits into
masterfrom
fix-dosbox-x-ffmpeg8-api

Conversation

@Pyohwan

@Pyohwan Pyohwan commented Jul 18, 2026

Copy link
Copy Markdown
Owner

Summary

Documents the vanilla rk3568 shared-target sanity-check build (no kernel/GPU changes, just confirming the buildroot environment itself works before branching off for ODROID-M1-specific work in odroid-m1-bsp-kernel).

Draft PR against my own fork for documentation purposes only. The actual fix here was already contributed upstream and accepted: batocera-linux#16060 (maintainer dmanlfc confirmed the original source-patch approach was wrong and --disable-avcodec was the correct fix, given parallel_build isolation means ffmpeg isn't actually present in dosbox-x's per-package host at official CI build time).

What's in this branch

  • dosbox-x: --disable-avcodec added to DOSBOX_X_CONF_OPTS (the earlier source-patch commit in this branch's history was reverted per maintainer feedback).

Baseline build log (2026-07-13 ~ 2026-07-16, LG gram)

  • Full rk3568 target build (all boards: odroid-m1, odroid-m1s, rock-3a/3c, anbernic-rgxx3/rg-ds, firefly-station-m2/p2, orangepi-3b, powkiddy-x55, radxa-zero-3w), 1102 packages, ~3 days wall time across multiple sessions (survived 2 reboots + 1 OOM crash + a docker GID mismatch that broke final image packaging until traced to inconsistent sg docker usage).
  • Final image: batocera-rk3568-odroid-m1-44-20260716.img.gz (2.53GB), SD-card-verified on real hardware.
  • Also found and reported a MAME SUBTARGET mismatch that turned out to be a false alarm (our own OOM/reboot interruptions, not a real bug) — mame: fix SUBTARGET mismatch between genie and build steps batocera-linux/batocera.linux#16061 (comment corrected, branch deleted, no code change needed).

Known gap

This baseline image still ships the original (maintainer-deemed-incorrect) dosbox-x source patch, not the --disable-avcodec fix in this branch — a full rebuild with this fix applied hasn't been done yet (not urgent, deferred).

🤖 Generated with Claude Code

https://claude.ai/code/session_f66fcf92-a0dc-4745-94a0-4fa46afc8b55

Pyohwan added 2 commits July 14, 2026 21:01
PR batocera-linux#16042 bumped ffmpeg to 8.1.2 and updated Kodi/kodi-inputstream-ffmpegdirect
patches accordingly, but dosbox-x also links against libavcodec directly and
was missed. Its video capture code (src/hardware/hardware.cpp) still used
APIs removed in ffmpeg 8:

- avcodec_close() — removed; the surrounding avcodec_free_context() calls
  already close+free, so the redundant avcodec_close() calls are dropped
- AVFrame::key_frame — removed; replaced with the AV_FRAME_FLAG_KEY flag
- FF_PROFILE_AAC_LOW — renamed to AV_PROFILE_AAC_LOW

Verified: dosbox-x (v2025.02.01) now builds and installs successfully for
the rk3568 board with this patch applied.
Per maintainer feedback: with the parallel build system, ffmpeg isn't
actually present in dosbox-x's per-package host at build time, so it
builds without capture support by default anyway - patching the
source to compile against ffmpeg 8.1.2 was solving a problem the
build doesn't actually have. --disable-avcodec matches what the
build already does in practice, until ffmpeg is properly wired up as
a dependency and dosbox-x gets updated.
Pyohwan added a commit that referenced this pull request Jul 25, 2026
… need

SPL needs U-Boot in a GPT entry literally named "uboot" (locates it by
label, per Hardkernel's wiki - not "SPL doesn't care about the partition
table", which an earlier commit on this branch mistakenly concluded from
seeing "Trying fit image at 0x4000 sector" without checking what happens
if the named entry is absent). Petitboot's device scan only finds a
bootable OS on partition #1 (confirmed live: with the boot partition at
#2, entries are parsed correctly - "boot option ... is unresolved" is
gone - but Petitboot still lists nothing at all).

Both are satisfied simultaneously by declaring the boot partition first
in genimage.cfg: genimage numbers GPT entries by declaration order, not
by on-disk offset (confirmed by reading genimage's own overlap-checking
code, which only rejects actual overlaps). So the boot partition becomes
GPT #1 for Petitboot while "uboot" keeps its own named entry (now #3) at
its original 8M offset for the SPL. Physical layout on the card is
unchanged either way.

Verified end to end on hardware in this exact image: SPL finds u-boot.itb
fine at GPT #3 ("Trying fit image at 0x4000 sector" -> all atf/fdt checks
OK), U-Boot's bootstd sees the boot partition as "part 1" and boots
extlinux.conf's "batocera-vu8m" label correctly (VU8M active, correctly
rotated), and Petitboot lists and boots "batocera.linux" from the same
card. All three requirements hold in the same image at last.
Pyohwan added a commit that referenced this pull request Jul 26, 2026
… need

SPL needs U-Boot in a GPT entry literally named "uboot" (locates it by
label, per Hardkernel's wiki - not "SPL doesn't care about the partition
table", which an earlier commit on this branch mistakenly concluded from
seeing "Trying fit image at 0x4000 sector" without checking what happens
if the named entry is absent). Petitboot's device scan only finds a
bootable OS on partition #1 (confirmed live: with the boot partition at
#2, entries are parsed correctly - "boot option ... is unresolved" is
gone - but Petitboot still lists nothing at all).

Both are satisfied simultaneously by declaring the boot partition first
in genimage.cfg: genimage numbers GPT entries by declaration order, not
by on-disk offset (confirmed by reading genimage's own overlap-checking
code, which only rejects actual overlaps). So the boot partition becomes
GPT #1 for Petitboot while "uboot" keeps its own named entry (now #3) at
its original 8M offset for the SPL. Physical layout on the card is
unchanged either way.

Verified end to end on hardware in this exact image: SPL finds u-boot.itb
fine at GPT #3 ("Trying fit image at 0x4000 sector" -> all atf/fdt checks
OK), U-Boot's bootstd sees the boot partition as "part 1" and boots
extlinux.conf's "batocera-vu8m" label correctly (VU8M active, correctly
rotated), and Petitboot lists and boots "batocera.linux" from the same
card. All three requirements hold in the same image at last.
Pyohwan added a commit that referenced this pull request Jul 27, 2026
… need

SPL needs U-Boot in a GPT entry literally named "uboot" (locates it by
label, per Hardkernel's wiki - not "SPL doesn't care about the partition
table", which an earlier commit on this branch mistakenly concluded from
seeing "Trying fit image at 0x4000 sector" without checking what happens
if the named entry is absent). Petitboot's device scan only finds a
bootable OS on partition #1 (confirmed live: with the boot partition at
#2, entries are parsed correctly - "boot option ... is unresolved" is
gone - but Petitboot still lists nothing at all).

Both are satisfied simultaneously by declaring the boot partition first
in genimage.cfg: genimage numbers GPT entries by declaration order, not
by on-disk offset (confirmed by reading genimage's own overlap-checking
code, which only rejects actual overlaps). So the boot partition becomes
GPT #1 for Petitboot while "uboot" keeps its own named entry (now #3) at
its original 8M offset for the SPL. Physical layout on the card is
unchanged either way.

Verified end to end on hardware in this exact image: SPL finds u-boot.itb
fine at GPT #3 ("Trying fit image at 0x4000 sector" -> all atf/fdt checks
OK), U-Boot's bootstd sees the boot partition as "part 1" and boots
extlinux.conf's "batocera-vu8m" label correctly (VU8M active, correctly
rotated), and Petitboot lists and boots "batocera.linux" from the same
card. All three requirements hold in the same image at last.
@Pyohwan Pyohwan closed this Aug 29, 2026
@Pyohwan
Pyohwan deleted the fix-dosbox-x-ffmpeg8-api branch August 29, 2026 09:17
@Pyohwan
Pyohwan restored the fix-dosbox-x-ffmpeg8-api branch August 29, 2026 09:26
@Pyohwan Pyohwan reopened this Aug 29, 2026
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.

1 participant