chore: merge knulli target scraper

This commit is contained in:
Abdessamad Derraz committed 2026-11-05 12:42:54 +01:00
commit 97b72c95c5
12 files changed
+3345 -279

No files matched your search

+11 -115
View File
@@ -511,9 +511,7 @@
"cap32",
"cdogs",
"dosbox_pure",
"duckstation",
"easyrpg",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -526,7 +524,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -543,7 +540,6 @@
"hurrican",
"hypseus-singe",
"imame4all",
"jazz2-native",
"lowresnx",
"lutro",
"mame078plus",
@@ -601,10 +597,8 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x16emu",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -628,8 +622,8 @@
"dosbox_pure",
"dosbox_staging",
"duckstation",
"duckstation-legacy",
"easyrpg",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -641,7 +635,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -657,7 +650,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -730,7 +722,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -742,7 +733,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -767,9 +757,9 @@
"dosbox_pure",
"dosbox_staging",
"duckstation",
"duckstation-legacy",
"easyrpg",
"ecwolf",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -781,7 +771,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -790,7 +779,6 @@
"genesisplusgx-expanded",
"gsplus",
"gw",
"gzdoom",
"handy",
"hatari",
"hcl",
@@ -798,8 +786,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"iortcw",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -809,7 +795,6 @@
"mednafen_ngp",
"mednafen_supergrafx",
"mednafen_wswan",
"melonds",
"mgba",
"minivmac",
"moonlight",
@@ -841,7 +826,6 @@
"px68k",
"pygame",
"quasi88",
"raze",
"reminiscence",
"samcoupe",
"same_cdi",
@@ -875,7 +859,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -887,7 +870,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -1252,9 +1234,7 @@
"devilutionx",
"dice",
"dosbox_pure",
"duckstation",
"easyrpg",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -1266,7 +1246,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -1282,7 +1261,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"jazz2-native",
"lightspark",
"lowresnx",
"mame078plus",
@@ -1346,7 +1324,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -1358,7 +1335,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -1385,9 +1361,9 @@
"dosbox_staging",
"dosboxx",
"duckstation",
"duckstation-legacy",
"easyrpg",
"ecwolf",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -1400,7 +1376,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -1409,7 +1384,6 @@
"genesisplusgx-expanded",
"gsplus",
"gw",
"gzdoom",
"handy",
"hatari",
"hcl",
@@ -1417,8 +1391,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"iortcw",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -1429,7 +1401,6 @@
"mednafen_psx",
"mednafen_supergrafx",
"mednafen_wswan",
"melonds",
"mgba",
"minivmac",
"moonlight",
@@ -1461,7 +1432,6 @@
"px68k",
"pygame",
"quasi88",
"raze",
"reminiscence",
"samcoupe",
"same_cdi",
@@ -1495,7 +1465,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -1507,7 +1476,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -1534,9 +1502,9 @@
"dosbox_staging",
"dosboxx",
"duckstation",
"duckstation-legacy",
"easyrpg",
"ecwolf",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -1549,7 +1517,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -1558,15 +1525,12 @@
"genesisplusgx-expanded",
"gsplus",
"gw",
"gzdoom",
"handy",
"hatari",
"hcl",
"holani",
"hurrican",
"hypseus-singe",
"iortcw",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -1577,7 +1541,6 @@
"mednafen_psx",
"mednafen_supergrafx",
"mednafen_wswan",
"melonds",
"mgba",
"minivmac",
"moonlight",
@@ -1609,7 +1572,6 @@
"px68k",
"pygame",
"quasi88",
"raze",
"reminiscence",
"samcoupe",
"same_cdi",
@@ -1643,7 +1605,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -1655,7 +1616,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -2273,8 +2233,8 @@
"dosbox_staging",
"dosboxx",
"duckstation",
"duckstation-legacy",
"easyrpg",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -2286,7 +2246,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -2302,7 +2261,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -2377,7 +2335,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -2389,7 +2346,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -2587,9 +2543,7 @@
"dice",
"dosbox_pure",
"dosbox_staging",
"duckstation",
"easyrpg",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -2601,7 +2555,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -2616,7 +2569,6 @@
"holani",
"hurrican",
"hypseus-singe",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -2691,7 +2643,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -2703,7 +2654,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -3017,9 +2967,9 @@
"dosbox_staging",
"dosboxx",
"duckstation",
"duckstation-legacy",
"easyrpg",
"ecwolf",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -3031,7 +2981,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -3040,7 +2989,6 @@
"genesisplusgx-expanded",
"gsplus",
"gw",
"gzdoom",
"handy",
"hatari",
"hcl",
@@ -3048,8 +2996,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"iortcw",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -3060,7 +3006,6 @@
"mednafen_psx",
"mednafen_supergrafx",
"mednafen_wswan",
"melonds",
"mgba",
"minivmac",
"moonlight",
@@ -3094,7 +3039,6 @@
"px68k",
"pygame",
"quasi88",
"raze",
"reminiscence",
"samcoupe",
"same_cdi",
@@ -3128,7 +3072,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -3140,7 +3083,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -3823,9 +3765,7 @@
"cap32",
"cdogs",
"dosbox_pure",
"duckstation",
"easyrpg",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -3838,7 +3778,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -3855,7 +3794,6 @@
"hurrican",
"hypseus-singe",
"imame4all",
"jazz2-native",
"lowresnx",
"lutro",
"mame078plus",
@@ -3913,10 +3851,8 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x16emu",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -3941,9 +3877,9 @@
"dosbox_pure",
"dosbox_staging",
"duckstation",
"duckstation-legacy",
"easyrpg",
"ecwolf",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -3955,7 +3891,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -3964,7 +3899,6 @@
"genesisplusgx-expanded",
"gsplus",
"gw",
"gzdoom",
"handy",
"hatari",
"hcl",
@@ -3972,8 +3906,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"iortcw",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -3983,7 +3915,6 @@
"mednafen_ngp",
"mednafen_supergrafx",
"mednafen_wswan",
"melonds",
"mgba",
"minivmac",
"moonlight",
@@ -4015,7 +3946,6 @@
"px68k",
"pygame",
"quasi88",
"raze",
"reminiscence",
"samcoupe",
"same_cdi",
@@ -4049,7 +3979,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -4061,7 +3990,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -4078,9 +4006,7 @@
"cap32",
"cdogs",
"dosbox_pure",
"duckstation",
"easyrpg",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -4093,7 +4019,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -4110,7 +4035,6 @@
"hurrican",
"hypseus-singe",
"imame4all",
"jazz2-native",
"lowresnx",
"lutro",
"mame078plus",
@@ -4168,10 +4092,8 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x16emu",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -4195,8 +4117,8 @@
"dosbox_pure",
"dosbox_staging",
"duckstation",
"duckstation-legacy",
"easyrpg",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -4208,7 +4130,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -4224,7 +4145,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -4297,7 +4217,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -4309,7 +4228,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -4334,9 +4252,9 @@
"dosbox_pure",
"dosbox_staging",
"duckstation",
"duckstation-legacy",
"easyrpg",
"ecwolf",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -4348,7 +4266,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -4357,7 +4274,6 @@
"genesisplusgx-expanded",
"gsplus",
"gw",
"gzdoom",
"handy",
"hatari",
"hcl",
@@ -4365,8 +4281,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"iortcw",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -4376,7 +4290,6 @@
"mednafen_ngp",
"mednafen_supergrafx",
"mednafen_wswan",
"melonds",
"mgba",
"minivmac",
"moonlight",
@@ -4408,7 +4321,6 @@
"px68k",
"pygame",
"quasi88",
"raze",
"reminiscence",
"samcoupe",
"same_cdi",
@@ -4442,7 +4354,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -4454,7 +4365,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -5166,8 +5076,8 @@
"dosbox_staging",
"dosboxx",
"duckstation",
"duckstation-legacy",
"easyrpg",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -5179,7 +5089,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -5195,7 +5104,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -5270,7 +5178,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -5282,7 +5189,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -5309,9 +5215,9 @@
"dosbox_staging",
"dosboxx",
"duckstation",
"duckstation-legacy",
"easyrpg",
"ecwolf",
"eduke32",
"emuscv",
"ep128emu-core",
"fake08",
@@ -5323,7 +5229,6 @@
"fmsx",
"freechaf",
"freeintv",
"fury",
"fuse",
"gambatte",
"gearcoleco",
@@ -5332,7 +5237,6 @@
"genesisplusgx-expanded",
"gsplus",
"gw",
"gzdoom",
"handy",
"hatari",
"hcl",
@@ -5340,8 +5244,6 @@
"hurrican",
"hypseus-singe",
"ioquake3",
"iortcw",
"jazz2-native",
"lightspark",
"lowresnx",
"lutro",
@@ -5352,7 +5254,6 @@
"mednafen_psx",
"mednafen_supergrafx",
"mednafen_wswan",
"melonds",
"mgba",
"minivmac",
"moonlight",
@@ -5384,7 +5285,6 @@
"px68k",
"pygame",
"quasi88",
"raze",
"reminiscence",
"samcoupe",
"same_cdi",
@@ -5418,7 +5318,6 @@
"vice_xplus4",
"vice_xscpu64",
"vice_xvic",
"vitaquake2",
"x1",
"x128",
"x16emu",
@@ -5430,7 +5329,6 @@
"xrick",
"xscpu64",
"xvic",
"yabasanshiro",
"yquake2",
"zc210"
],
@@ -6638,7 +6536,6 @@
"hurrican",
"hypseus-singe",
"ikemen",
"ioquake3",
"iortcw",
"jazz2-native",
"kronos",
@@ -6849,7 +6746,6 @@
"hurrican",
"hypseus-singe",
"ikemen",
"ioquake3",
"iortcw",
"jazz2-native",
"kronos",
File diff suppressed because it is too large. Load diff
+4 -3
View File
@@ -925,7 +925,8 @@ platforms:
# ApiSystem.cpp:764-774). Arch R (archr-linux/Arch-R dbd45d45) ships the
# same dict as archr-systems: lines 1-870 are identical, only the prefix
# (/storage/roms instead of /userdata) and the es_systems.cfg path differ.
# Many boards, no per-board core list: no target file.
# Boards follow Batocera's Kconfig model (configs/knulli-*.board set
# BR2_PACKAGE_BATOCERA_TARGET_*), read by knulli_targets_scraper.
knulli:
config: knulli.yml
status: active
@@ -947,8 +948,8 @@ platforms:
by_core: false
by_system: true
schedule: monthly
target_scraper: null
target_source: null
target_scraper: knulli_targets
target_source: https://github.com/knulli-cfw/knulli-linux/tree/knulli-main/configs
install:
detect:
# knulli-linux 57afa662: OS_NAME in os-release
+24 -2
View File
@@ -172,12 +172,34 @@ rocknix:
amd64:
aliases: [x86_64, pc]
# KNULLI reads Batocera's list above, plus its own: vaixterm is a terminal,
# filed as the VaixTerm system's emulator (configgen-defaults.yml:669-671).
# KNULLI's platform scraper reads Batocera's list above, plus this one. The
# target list reads this one alone, so it repeats Batocera's names, all of
# which KNULLI's es_systems.yml carries under the same nodes. vaixterm is a
# terminal, filed as the VaixTerm system's emulator
# (configgen-defaults.yml:669-671).
knulli:
targets:
_default:
remove_cores:
- A500
- "A500+"
- A600
- A1000
- A1200
- A3000
- A4000
- CD32
- CDTV
- flatpak
- odcommander
- sh
- steam
- wine-tkg
- wine
- mugen
- gliden64
- glide64mk2
- rice
- vaixterm
# EmuELEC and AmberELEC have no target file: the scrapers read these lists.
+17 -99
View File
@@ -1,6 +1,6 @@
platform: batocera
source: https://github.com/batocera-linux/batocera.linux/tree/batocera-43.1
scraped_at: '2026-10-17T22:01:01Z'
scraped_at: '2026-11-05T10:55:18Z'
targets:
a3gen2:
architecture: aarch64
@@ -535,7 +535,7 @@ targets:
- yquake2
- zc210
bcm2835:
architecture: aarch64
architecture: arm
cores:
- '81'
- a5200
@@ -549,9 +549,7 @@ targets:
- cap32
- cdogs
- dosbox_pure
- duckstation
- easyrpg
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -564,7 +562,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -581,7 +578,6 @@ targets:
- hurrican
- hypseus-singe
- imame4all
- jazz2-native
- lowresnx
- lutro
- mame078plus
@@ -640,14 +636,12 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x16emu
- yabasanshiro
- yquake2
- zc210
bcm2836:
architecture: aarch64
architecture: arm
cores:
- '81'
- A1200
@@ -674,8 +668,8 @@ targets:
- dosbox_pure
- dosbox_staging
- duckstation
- duckstation-legacy
- easyrpg
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -687,7 +681,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -705,7 +698,6 @@ targets:
- hurrican
- hypseus-singe
- ioquake3
- jazz2-native
- lightspark
- lowresnx
- lutro
@@ -748,7 +740,6 @@ targets:
- px68k
- pygame
- quasi88
- rice
- samcoupe
- sameduck
- scummvm
@@ -780,7 +771,6 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x128
- x16emu
@@ -792,7 +782,6 @@ targets:
- xrick
- xscpu64
- xvic
- yabasanshiro
- yquake2
- zc210
bcm2837:
@@ -824,9 +813,9 @@ targets:
- dosbox_pure
- dosbox_staging
- duckstation
- duckstation-legacy
- easyrpg
- ecwolf
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -838,7 +827,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -849,7 +837,6 @@ targets:
- gliden64
- gsplus
- gw
- gzdoom
- handy
- hatari
- hcl
@@ -857,8 +844,6 @@ targets:
- hurrican
- hypseus-singe
- ioquake3
- iortcw
- jazz2-native
- lightspark
- lowresnx
- lutro
@@ -868,7 +853,6 @@ targets:
- mednafen_ngp
- mednafen_supergrafx
- mednafen_wswan
- melonds
- mgba
- minivmac
- moonlight
@@ -901,9 +885,7 @@ targets:
- px68k
- pygame
- quasi88
- raze
- reminiscence
- rice
- samcoupe
- same_cdi
- sameduck
@@ -936,7 +918,6 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x128
- x16emu
@@ -948,11 +929,10 @@ targets:
- xrick
- xscpu64
- xvic
- yabasanshiro
- yquake2
- zc210
h3:
architecture: aarch64
architecture: arm
cores:
- '81'
- A1200
@@ -977,9 +957,7 @@ targets:
- devilutionx
- dice
- dosbox_pure
- duckstation
- easyrpg
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -991,7 +969,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -1009,7 +986,6 @@ targets:
- hurrican
- hypseus-singe
- ioquake3
- jazz2-native
- lightspark
- lowresnx
- mame078plus
@@ -1046,7 +1022,6 @@ targets:
- prosystem
- px68k
- quasi88
- rice
- samcoupe
- sameduck
- scummvm
@@ -1075,7 +1050,6 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x128
- x16emu
@@ -1087,7 +1061,6 @@ targets:
- xrick
- xscpu64
- xvic
- yabasanshiro
- yquake2
- zc210
h5:
@@ -1121,9 +1094,9 @@ targets:
- dosbox_staging
- dosboxx
- duckstation
- duckstation-legacy
- easyrpg
- ecwolf
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -1136,7 +1109,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -1147,7 +1119,6 @@ targets:
- gliden64
- gsplus
- gw
- gzdoom
- handy
- hatari
- hcl
@@ -1155,8 +1126,6 @@ targets:
- hurrican
- hypseus-singe
- ioquake3
- iortcw
- jazz2-native
- lightspark
- lowresnx
- lutro
@@ -1167,7 +1136,6 @@ targets:
- mednafen_psx
- mednafen_supergrafx
- mednafen_wswan
- melonds
- mgba
- minivmac
- moonlight
@@ -1200,9 +1168,7 @@ targets:
- px68k
- pygame
- quasi88
- raze
- reminiscence
- rice
- samcoupe
- same_cdi
- sameduck
@@ -1235,7 +1201,6 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x128
- x16emu
@@ -1247,7 +1212,6 @@ targets:
- xrick
- xscpu64
- xvic
- yabasanshiro
- yquake2
- zc210
h6:
@@ -1281,9 +1245,9 @@ targets:
- dosbox_staging
- dosboxx
- duckstation
- duckstation-legacy
- easyrpg
- ecwolf
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -1296,7 +1260,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -1307,15 +1270,12 @@ targets:
- gliden64
- gsplus
- gw
- gzdoom
- handy
- hatari
- hcl
- holani
- hurrican
- hypseus-singe
- iortcw
- jazz2-native
- lightspark
- lowresnx
- lutro
@@ -1326,7 +1286,6 @@ targets:
- mednafen_psx
- mednafen_supergrafx
- mednafen_wswan
- melonds
- mgba
- minivmac
- moonlight
@@ -1359,9 +1318,7 @@ targets:
- px68k
- pygame
- quasi88
- raze
- reminiscence
- rice
- samcoupe
- same_cdi
- sameduck
@@ -1394,7 +1351,6 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x128
- x16emu
@@ -1406,7 +1362,6 @@ targets:
- xrick
- xscpu64
- xvic
- yabasanshiro
- yquake2
- zc210
h616:
@@ -1741,7 +1696,7 @@ targets:
- yquake2
- zc210
jh7110:
architecture: aarch64
architecture: riscv64
cores:
- '81'
- a5200
@@ -2040,7 +1995,7 @@ targets:
- yquake2
- zc210
odroidxu4:
architecture: aarch64
architecture: arm
cores:
- '81'
- A1200
@@ -2069,8 +2024,8 @@ targets:
- dosbox_staging
- dosboxx
- duckstation
- duckstation-legacy
- easyrpg
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -2082,7 +2037,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -2100,7 +2054,6 @@ targets:
- hurrican
- hypseus-singe
- ioquake3
- jazz2-native
- lightspark
- lowresnx
- lutro
@@ -2145,7 +2098,6 @@ targets:
- px68k
- pygame
- quasi88
- rice
- samcoupe
- sameduck
- scummvm
@@ -2177,7 +2129,6 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x128
- x16emu
@@ -2189,7 +2140,6 @@ targets:
- xrick
- xscpu64
- xvic
- yabasanshiro
- yquake2
- zc210
qcs6490:
@@ -2379,7 +2329,7 @@ targets:
- yquake2
- zc210
rk3128:
architecture: aarch64
architecture: arm
cores:
- '81'
- A1200
@@ -2405,9 +2355,7 @@ targets:
- dice
- dosbox_pure
- dosbox_staging
- duckstation
- easyrpg
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -2419,7 +2367,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -2436,7 +2383,6 @@ targets:
- holani
- hurrican
- hypseus-singe
- jazz2-native
- lightspark
- lowresnx
- lutro
@@ -2481,7 +2427,6 @@ targets:
- px68k
- pygame
- quasi88
- rice
- samcoupe
- sameduck
- scummvm
@@ -2513,7 +2458,6 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x128
- x16emu
@@ -2525,11 +2469,10 @@ targets:
- xrick
- xscpu64
- xvic
- yabasanshiro
- yquake2
- zc210
rk3288:
architecture: aarch64
architecture: arm
cores:
- '81'
- A1200
@@ -2868,9 +2811,9 @@ targets:
- dosbox_staging
- dosboxx
- duckstation
- duckstation-legacy
- easyrpg
- ecwolf
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -2882,7 +2825,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -2893,7 +2835,6 @@ targets:
- gliden64
- gsplus
- gw
- gzdoom
- handy
- hatari
- hcl
@@ -2901,8 +2842,6 @@ targets:
- hurrican
- hypseus-singe
- ioquake3
- iortcw
- jazz2-native
- lightspark
- lowresnx
- lutro
@@ -2913,7 +2852,6 @@ targets:
- mednafen_psx
- mednafen_supergrafx
- mednafen_wswan
- melonds
- mgba
- minivmac
- moonlight
@@ -2948,9 +2886,7 @@ targets:
- px68k
- pygame
- quasi88
- raze
- reminiscence
- rice
- samcoupe
- same_cdi
- sameduck
@@ -2983,7 +2919,6 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x128
- x16emu
@@ -2995,7 +2930,6 @@ targets:
- xrick
- xscpu64
- xvic
- yabasanshiro
- yquake2
- zc210
rk3399:
@@ -3709,7 +3643,7 @@ targets:
- yquake2
- zc210
s812:
architecture: aarch64
architecture: arm
cores:
- '81'
- A1200
@@ -3738,8 +3672,8 @@ targets:
- dosbox_staging
- dosboxx
- duckstation
- duckstation-legacy
- easyrpg
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -3751,7 +3685,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -3769,7 +3702,6 @@ targets:
- hurrican
- hypseus-singe
- ioquake3
- jazz2-native
- lightspark
- lowresnx
- lutro
@@ -3814,7 +3746,6 @@ targets:
- px68k
- pygame
- quasi88
- rice
- samcoupe
- sameduck
- scummvm
@@ -3846,7 +3777,6 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x128
- x16emu
@@ -3858,7 +3788,6 @@ targets:
- xrick
- xscpu64
- xvic
- yabasanshiro
- yquake2
- zc210
s905:
@@ -3892,9 +3821,9 @@ targets:
- dosbox_staging
- dosboxx
- duckstation
- duckstation-legacy
- easyrpg
- ecwolf
- eduke32
- emuscv
- ep128emu-core
- fake08
@@ -3906,7 +3835,6 @@ targets:
- fmsx
- freechaf
- freeintv
- fury
- fuse
- gambatte
- gearcoleco
@@ -3917,7 +3845,6 @@ targets:
- gliden64
- gsplus
- gw
- gzdoom
- handy
- hatari
- hcl
@@ -3925,8 +3852,6 @@ targets:
- hurrican
- hypseus-singe
- ioquake3
- iortcw
- jazz2-native
- lightspark
- lowresnx
- lutro
@@ -3937,7 +3862,6 @@ targets:
- mednafen_psx
- mednafen_supergrafx
- mednafen_wswan
- melonds
- mgba
- minivmac
- moonlight
@@ -3970,9 +3894,7 @@ targets:
- px68k
- pygame
- quasi88
- raze
- reminiscence
- rice
- samcoupe
- same_cdi
- sameduck
@@ -4005,7 +3927,6 @@ targets:
- vice_xplus4
- vice_xscpu64
- vice_xvic
- vitaquake2
- x1
- x128
- x16emu
@@ -4017,7 +3938,6 @@ targets:
- xrick
- xscpu64
- xvic
- yabasanshiro
- yquake2
- zc210
s905gen2:
@@ -5315,7 +5235,6 @@ targets:
- hurrican
- hypseus-singe
- ikemen
- ioquake3
- iortcw
- jazz2-native
- kronos
@@ -5542,7 +5461,6 @@ targets:
- hurrican
- hypseus-singe
- ikemen
- ioquake3
- iortcw
- jazz2-native
- kronos
File diff suppressed because it is too large. Load diff
@@ -29,27 +29,15 @@ from . import BaseTargetScraper
PLATFORM_NAME = "batocera"
GITHUB_API = "https://api.github.com/repos/batocera-linux/batocera.linux/contents"
try:
from ..base_scraper import github_headers
except ImportError:
from scraper.base_scraper import github_headers
RAW_BASE = "https://raw.githubusercontent.com/batocera-linux/batocera.linux/{tag}"
CONFIG_IN_PATH = "package/batocera/core/batocera-system/Config.in"
ES_SYSTEMS_PATH = "package/batocera/emulationstation/batocera-es-system/es_systems.yml"
_TARGET_FLAG_RE = re.compile(r"^(BR2_PACKAGE_BATOCERA_TARGET_\w+)=y", re.MULTILINE)
# Meta-flag definition: "if COND\n\tconfig DERIVED_FLAG\n\t...\nendif"
_META_BLOCK_RE = re.compile(
r"^if\s+((?:[^\n]|\\\n)+?)\n" # condition (may span lines via \)
r"(?:.*?\n)*?" # optional lines before the config
r"\s+config\s+(BR2_PACKAGE_\w+)" # derived flag name
r".*?^endif", # end of block
re.MULTILINE | re.DOTALL,
)
_IF_RE = re.compile(r"^if\s+(.*)$")
_DEFAULT_Y_RE = re.compile(r"^\s*default\s+y\s*(?:#.*)?$")
def _fetch(url: str, headers: dict | None = None) -> str:
@@ -156,13 +144,30 @@ def _parse_meta_flags(text: str) -> list[tuple[str, str]]:
"""Return [(derived_flag, condition_str)] from top-level if/endif blocks.
These define derived flags like BR2_PACKAGE_BATOCERA_TARGET_X86_64_ANY,
BR2_PACKAGE_BATOCERA_GLES3, etc.
BR2_PACKAGE_BATOCERA_GLES3, etc.: a config inside `if COND` that
defaults to y is on exactly when COND holds. Read line by line: a
condition continued with a backslash keeps its later lines, and a block
whose config is not a package (KNULLI's BR2_KERNEL_LEGACY_3_10) cannot
reach into the next one.
"""
results: list[tuple[str, str]] = []
for m in _META_BLOCK_RE.finditer(text):
cond = _normalise_condition(m.group(1))
flag = m.group(2)
results.append((flag, cond))
condition: str | None = None
config: str | None = None
for line in re.sub(r"\\\n", " ", text).splitlines():
start = _IF_RE.match(line)
if start:
condition, config = _normalise_condition(start.group(1)), None
continue
if condition is None:
continue
if line.startswith("endif"):
condition = config = None
continue
found = _CONFIG_LINE_RE.match(line)
if found:
config = found.group(1)
elif config and _DEFAULT_Y_RE.match(line):
results.append((config, condition))
return results
@@ -174,8 +179,6 @@ BUILDROOT_KCONFIG = (
"package/mesa3d/Config.in",
"package/libglvnd/Config.in",
)
BUILDROOT_RAW = "https://raw.githubusercontent.com/batocera-linux/buildroot/{sha}"
SYSTEM_SYMBOL = "BR2_PACKAGE_BATOCERA_SYSTEM"
_CONFIG_LINE_RE = re.compile(r"^\s*(?:menu)?config\s+(BR2_\w+)")
_OWNED_SELECT_RE = re.compile(r"^\s+select\s+(BR2_\w+)(?:\s+if\s+([^#]+))?")
@@ -217,22 +220,26 @@ def _active_symbols(
Run to a fixed point, as Kconfig does: a select can turn on a config
whose own selects then fire, and a derived flag can follow from either.
Each pass rebuilds the set from the board's own flags, so a select
guarded by a negation (`if !BR2_PACKAGE_BATOCERA_GLES3`) that fired
before GLES3 was derived is dropped once it is: accumulating kept
duckstation-legacy on every GLES3 board.
"""
active = set(board_flags)
while True:
before = len(active)
frozen = frozenset(active)
active |= {
base = frozenset(board_flags)
active = base
for _ in range(64):
following = base | {
derived for derived, condition in meta_rules
if _condition_holds(condition, frozen)
}
active |= {
if _condition_holds(condition, active)
} | {
selected
for owner, selected, condition in rules
if owner in frozen and _condition_holds(condition, frozen)
if owner in active and _condition_holds(condition, active)
}
if len(active) == before:
return frozenset(active)
if following == active:
return active
active = frozenset(following)
raise RuntimeError("Kconfig selects do not settle: a negated condition cycles")
def _parse_es_systems(text: str) -> dict[str, list[str]]:
@@ -279,8 +286,25 @@ def _parse_es_systems(text: str) -> dict[str, list[str]]:
return package_to_emulators
def _arch_from_flag(flag: str) -> str:
"""Guess architecture from board flag name."""
# Buildroot's architecture choice, as a board sets it (arch/Config.in).
_ARCH_SYMBOLS = {
"BR2_aarch64": "aarch64",
"BR2_arm": "arm",
"BR2_x86_64": "x86_64",
"BR2_i386": "x86",
"BR2_riscv": "riscv64",
}
def _arch_from_flag(flag: str, board_flags: set[str] | frozenset[str] = frozenset()) -> str:
"""The board's Buildroot architecture, else a guess from its target flag.
KNULLI's R16, RK3128 and ATM7039 images are 32-bit ARM (BR2_arm=y):
the target flag alone does not say so.
"""
for symbol, arch in _ARCH_SYMBOLS.items():
if symbol in board_flags:
return arch
low = flag.lower()
if "x86_64" in low or "zen3" in low:
return "x86_64"
@@ -290,35 +314,51 @@ def _arch_from_flag(flag: str) -> str:
class Scraper(BaseTargetScraper):
"""Cross-references Batocera boards, Config.in, and es_systems to build target lists."""
"""Cross-references Batocera boards, Config.in, and es_systems to build target lists.
def __init__(
self, url: str = "https://github.com/batocera-linux/batocera.linux"
) -> None:
super().__init__(url=url)
A Buildroot tree built on Batocera's model (KNULLI) overrides the class
attributes: its repository, board prefix, system Config.in, es_systems
and the config every image turns on.
"""
PLATFORM = PLATFORM_NAME
REPO = "batocera-linux/batocera.linux"
BOARD_PREFIX = "batocera-"
CONFIG_IN_PATH = "package/batocera/core/batocera-system/Config.in"
ES_SYSTEMS_PATH = "package/batocera/emulationstation/batocera-es-system/es_systems.yml"
SYSTEM_SYMBOL = "BR2_PACKAGE_BATOCERA_SYSTEM"
BUILDROOT_REPO = "batocera-linux/buildroot"
def __init__(self, url: str = "") -> None:
super().__init__(url=url or f"https://github.com/{self.REPO}")
self.tag = ""
def _raw(self, path: str) -> str:
return f"{RAW_BASE.format(tag=self.tag)}/{path}"
return f"https://raw.githubusercontent.com/{self.REPO}/{self.tag}/{path}"
def _api(self, path: str) -> str:
return f"https://api.github.com/repos/{self.REPO}/contents/{path}?ref={self.tag}"
def _list_boards(self) -> list[str]:
"""List batocera-*.board files from configs/ via GitHub API."""
data = _fetch_json(f"{GITHUB_API}/configs?ref={self.tag}")
"""List <prefix>*.board files from configs/ via GitHub API."""
data = _fetch_json(self._api("configs"))
boards = [
item["name"]
for item in data
if isinstance(item, dict)
and item.get("name", "").startswith("batocera-")
and item.get("name", "").startswith(self.BOARD_PREFIX)
and item.get("name", "").endswith(".board")
] if isinstance(data, list) else []
if not boards:
raise RuntimeError(f"no batocera-*.board file in configs/ at {self.tag}")
raise RuntimeError(
f"no {self.BOARD_PREFIX}*.board file in configs/ at {self.tag}"
)
return boards
def _fetch_board(self, board_name: str) -> tuple[str | None, set[str]]:
"""A board's target flag and every flag it sets, includes followed.
batocera-board.common turns on BATOCERA_SYSTEM, the config whose
<prefix>board.common turns on the system symbol, the config whose
selects bring in the display stack and every emulator group.
"""
flags: set[str] = set()
@@ -343,24 +383,25 @@ class Scraper(BaseTargetScraper):
return target, flags
def _buildroot_rules(self) -> list[tuple[str, str, str]]:
"""Buildroot's selects for the symbols Batocera tests, at its pin."""
pin = _fetch_json(f"{GITHUB_API}/buildroot?ref={self.tag}")
"""Buildroot's selects for the symbols the tree tests, at its pin."""
pin = _fetch_json(self._api("buildroot"))
sha = pin.get("sha") if isinstance(pin, dict) else None
if not sha:
raise RuntimeError(f"no buildroot submodule commit at {self.tag}")
raw = f"https://raw.githubusercontent.com/{self.BUILDROOT_REPO}/{sha}"
rules: list[tuple[str, str, str]] = []
for path in BUILDROOT_KCONFIG:
rules += _parse_owned_selects(_fetch(f"{BUILDROOT_RAW.format(sha=sha)}/{path}"))
rules += _parse_owned_selects(_fetch(f"{raw}/{path}"))
return rules
def fetch_targets(self) -> dict:
"""Build per-board emulator availability map."""
self.tag = self.pinned_revision(PLATFORM_NAME)
self.tag = self.pinned_revision(self.PLATFORM)
print(" fetching board list...", file=sys.stderr)
boards = self._list_boards()
print(" fetching Config.in...", file=sys.stderr)
config_in_url = self._raw(CONFIG_IN_PATH)
config_in_url = self._raw(self.CONFIG_IN_PATH)
config_in_text = _fetch(config_in_url)
if not config_in_text:
raise RuntimeError(f"empty Config.in from {config_in_url}")
@@ -376,7 +417,7 @@ class Scraper(BaseTargetScraper):
rules += self._buildroot_rules()
print(" fetching es_systems.yml...", file=sys.stderr)
es_systems_url = self._raw(ES_SYSTEMS_PATH)
es_systems_url = self._raw(self.ES_SYSTEMS_PATH)
es_text = _fetch(es_systems_url)
if not es_text:
raise RuntimeError(f"empty es_systems.yml from {es_systems_url}")
@@ -390,7 +431,7 @@ class Scraper(BaseTargetScraper):
targets: dict[str, dict] = {}
for board_name in sorted(boards):
target_key = board_name.removeprefix("batocera-").removesuffix(".board")
target_key = board_name.removeprefix(self.BOARD_PREFIX).removesuffix(".board")
print(f" processing {target_key}...", file=sys.stderr)
primary_flag, board_flags = self._fetch_board(board_name)
if primary_flag is None:
@@ -400,8 +441,8 @@ class Scraper(BaseTargetScraper):
selected_packages = _active_symbols(board_flags, meta_rules, rules)
# x86_wow64 builds the 32-bit Wine package the x86_64 image
# carries: no batocera-board.common, no system, no target.
if SYSTEM_SYMBOL not in selected_packages:
print(f" {board_name} builds no Batocera image", file=sys.stderr)
if self.SYSTEM_SYMBOL not in selected_packages:
print(f" {board_name} builds no system image", file=sys.stderr)
continue
# Map selected packages to emulator names via es_systems.yml
@@ -410,7 +451,7 @@ class Scraper(BaseTargetScraper):
for emu in package_to_emulators.get(pkg, []):
emulators.add(emu)
arch = _arch_from_flag(primary_flag)
arch = _arch_from_flag(primary_flag, board_flags)
targets[target_key] = {
"architecture": arch,
"cores": sorted(emulators),
@@ -421,23 +462,23 @@ class Scraper(BaseTargetScraper):
)
return {
"platform": "batocera",
"platform": self.PLATFORM,
"source": f"{self.url}/tree/{self.tag}",
"scraped_at": datetime.now(timezone.utc).strftime("%Y-%m-%dT%H:%M:%SZ"),
"targets": targets,
}
def main() -> None:
def main(scraper_class: type[Scraper] = Scraper) -> None:
parser = argparse.ArgumentParser(
allow_abbrev=False,
description="Scrape Batocera per-board emulator targets"
description=f"Scrape {scraper_class.PLATFORM} per-board emulator targets"
)
parser.add_argument("--dry-run", action="store_true", help="Show target summary")
parser.add_argument("--output", "-o", help="Output YAML file")
args = parser.parse_args()
scraper = Scraper()
scraper = scraper_class()
data = scraper.fetch_targets()
if args.dry_run:
@@ -0,0 +1,42 @@
"""Scraper for KNULLI per-board emulator availability.
KNULLI is a Buildroot external tree on Batocera's model, read with the
Batocera scraper's Kconfig resolution. Sources (knulli-cfw/knulli-linux, at
the tag platforms/knulli.yml names):
- configs/knulli-*.board -- board definitions, each sets
BR2_PACKAGE_BATOCERA_TARGET_* and includes knulli-board.common
- package/system/knulli-system/Config.in -- the system config, sourced by
the root Config.in in place of Batocera's batocera-system/Config.in
- package/emulationstation/knulli-es-system/es_systems.yml
-- emulator requireAnyOf flag mapping
Sources (knulli-cfw/buildroot, at the submodule commit the tag pins):
- arch/Config.in, package/mesa3d/Config.in, package/libglvnd/Config.in
The *_armhf_libs boards include knulli-board.libs, which builds 32-bit
libraries for the matching image and turns no system on: they are no target.
"""
from __future__ import annotations
from .batocera_targets_scraper import Scraper as BatoceraScraper
from .batocera_targets_scraper import main as batocera_main
PLATFORM_NAME = "knulli"
class Scraper(BatoceraScraper):
PLATFORM = PLATFORM_NAME
REPO = "knulli-cfw/knulli-linux"
BOARD_PREFIX = "knulli-"
CONFIG_IN_PATH = "package/system/knulli-system/Config.in"
ES_SYSTEMS_PATH = "package/emulationstation/knulli-es-system/es_systems.yml"
SYSTEM_SYMBOL = "BR2_PACKAGE_KNULLI_SYSTEM"
BUILDROOT_REPO = "knulli-cfw/buildroot"
def main() -> None:
batocera_main(Scraper)
if __name__ == "__main__":
main()
+6 -1
View File
@@ -4560,7 +4560,12 @@ class TargetListsReadThePinnedRelease(unittest.TestCase):
for name in ("batocera", "rocknix", "recalbox"):
source = (ROOT / "scripts" / "scraper" / "targets" / f"{name}_targets_scraper.py").read_text()
with self.subTest(scraper=name):
self.assertIn("self.pinned_revision(PLATFORM_NAME)", source)
# The Batocera scraper reads the pin of the platform it is
# instantiated for (KNULLI subclasses it).
self.assertTrue(
"self.pinned_revision(PLATFORM_NAME)" in source
or "self.pinned_revision(self.PLATFORM)" in source
)
self.assertNotIn("fetch_stable_tag()", source)
self.assertNotIn("fetch_github_latest_version(", source)
+147
View File
@@ -176,6 +176,153 @@ class BatoceraKconfig(unittest.TestCase):
"BR2_PACKAGE_RUFFLE"} & active)
class BatoceraDerivedFlags(unittest.TestCase):
"""A condition continued with a backslash was cut at its first line:
"BR2_PACKAGE_BATOCERA_TARGET_X86_ANY ||" held on every board, so GLES3
did too, and a GLES2 Raspberry Pi got yabasanshiro and eduke32. A block
whose config is not a package (KNULLI's BR2_KERNEL_LEGACY_3_10) sent
the regex backtracking without end."""
CONFIG_IN = (
"if BR2_PACKAGE_BATOCERA_TARGET_X86_64 || \\\n"
" BR2_PACKAGE_BATOCERA_TARGET_H700\n"
"\tconfig BR2_PACKAGE_BATOCERA_GLES3\n\tbool \"gles3\"\n\tdefault y\nendif\n\n"
"if BR2_PACKAGE_BATOCERA_TARGET_SUNXI_R16\n"
" config BR2_KERNEL_LEGACY_3_10\n default y\nendif\n\n"
+ "config BR2_PACKAGE_FILLER\n\tbool \"filler\"\n" * 400
+ "config BR2_PACKAGE_BATOCERA_SYSTEM\n"
"\tselect BR2_PACKAGE_EDUKE32\tif BR2_PACKAGE_BATOCERA_GLES3\n"
"\tselect BR2_PACKAGE_DUCKSTATION_LEGACY\tif !BR2_PACKAGE_BATOCERA_GLES3\n"
)
def active(self, board: set[str]) -> frozenset[str]:
from scraper.targets.batocera_targets_scraper import ( # noqa: PLC0415
_active_symbols,
_parse_meta_flags,
_parse_owned_selects,
)
return _active_symbols(
board | {"BR2_PACKAGE_BATOCERA_SYSTEM"},
_parse_meta_flags(self.CONFIG_IN),
_parse_owned_selects(self.CONFIG_IN),
)
def test_a_continued_condition_keeps_its_later_lines(self):
from scraper.targets.batocera_targets_scraper import ( # noqa: PLC0415
_parse_meta_flags,
)
rules = dict(_parse_meta_flags(self.CONFIG_IN))
self.assertIn("BR2_PACKAGE_BATOCERA_TARGET_H700", rules["BR2_PACKAGE_BATOCERA_GLES3"])
self.assertEqual(rules["BR2_KERNEL_LEGACY_3_10"],
"BR2_PACKAGE_BATOCERA_TARGET_SUNXI_R16")
def test_gles3_follows_the_board(self):
h700 = self.active({"BR2_PACKAGE_BATOCERA_TARGET_H700"})
self.assertIn("BR2_PACKAGE_EDUKE32", h700)
r16 = self.active({"BR2_PACKAGE_BATOCERA_TARGET_SUNXI_R16"})
self.assertNotIn("BR2_PACKAGE_BATOCERA_GLES3", r16)
self.assertNotIn("BR2_PACKAGE_EDUKE32", r16)
def test_a_negated_select_drops_once_the_flag_is_derived(self):
"""GLES3 is derived on the first pass, after which `!GLES3` no
longer holds: accumulating kept duckstation-legacy on every GLES3
board."""
h700 = self.active({"BR2_PACKAGE_BATOCERA_TARGET_H700"})
self.assertNotIn("BR2_PACKAGE_DUCKSTATION_LEGACY", h700)
r16 = self.active({"BR2_PACKAGE_BATOCERA_TARGET_SUNXI_R16"})
self.assertIn("BR2_PACKAGE_DUCKSTATION_LEGACY", r16)
class KnulliPerBoard(unittest.TestCase):
"""KNULLI builds per board on Batocera's model from its own tree:
configs/knulli-*.board, package/system/knulli-system/Config.in and
package/emulationstation/knulli-es-system/es_systems.yml, with
BR2_PACKAGE_KNULLI_SYSTEM as the config every image turns on."""
FILES = {
"configs/knulli-board.common": "BR2_PACKAGE_KNULLI_SYSTEM=y\n",
"configs/knulli-board.libs": "BR2_PACKAGE_BATOCERA_SYSTEM=n\n",
"configs/knulli-h700.board": (
"include knulli-board.common\n\nBR2_aarch64=y\n"
"BR2_PACKAGE_BATOCERA_TARGET_H700=y\n"
),
"configs/knulli-r16.board": (
"include knulli-board.common\n\nBR2_arm=y\n"
"BR2_PACKAGE_BATOCERA_TARGET_SUNXI_R16=y\n"
),
"configs/knulli-h700_armhf_libs.board": (
"include knulli-board.libs\ninclude knulli-h700_armhf_libs.packages\n"
"BR2_arm=y\nBR2_PACKAGE_BATOCERA_TARGET_H700=y\n"
),
"configs/knulli-h700_armhf_libs.packages": "BR2_PACKAGE_SDL2=y\n",
"package/system/knulli-system/Config.in": (
"if BR2_PACKAGE_BATOCERA_TARGET_H700 || \\\n"
" BR2_PACKAGE_BATOCERA_TARGET_A133\n"
"\tconfig BR2_PACKAGE_BATOCERA_GLES3\n\tdefault y\nendif\n\n"
"config BR2_PACKAGE_KNULLI_SYSTEM\n"
"\tselect BR2_PACKAGE_LIBRETRO_MGBA\n"
"\tselect BR2_PACKAGE_PPSSPP\tif BR2_PACKAGE_BATOCERA_GLES3\n"
),
"package/emulationstation/knulli-es-system/es_systems.yml": (
"gba:\n emulators:\n libretro:\n"
" mgba: {requireAnyOf: [BR2_PACKAGE_LIBRETRO_MGBA]}\n"
"psp:\n emulators:\n ppsspp:\n"
" ppsspp: {requireAnyOf: [BR2_PACKAGE_PPSSPP]}\n"
),
}
def test_each_board_gets_its_own_cores(self):
from scripts.scraper.targets import knulli_targets_scraper # noqa: PLC0415
pin = knulli_targets_scraper.Scraper.pinned_revision("knulli")
raw = f"https://raw.githubusercontent.com/knulli-cfw/knulli-linux/{pin}/"
api = "https://api.github.com/repos/knulli-cfw/knulli-linux/contents/"
seen: list[str] = []
class _Body:
def __init__(self, body: str):
self.body = body.encode()
def __enter__(self):
return self
def __exit__(self, *exc):
return False
def read(self):
return self.body
def urlopen(request, *_a, **_k):
url = request.full_url
seen.append(url)
if url == f"{api}configs?ref={pin}":
names = [p.removeprefix("configs/") for p in self.FILES if p.startswith("configs/")]
return _Body(json.dumps([{"name": n} for n in names]))
if url == f"{api}buildroot?ref={pin}":
return _Body('{"sha": "c2d7985b"}')
if url.startswith("https://raw.githubusercontent.com/knulli-cfw/buildroot/c2d7985b/"):
return _Body("config BR2_aarch64\n\tselect BR2_ARCH_IS_64\n")
path = url.removeprefix(raw)
if path in self.FILES:
return _Body(self.FILES[path])
_refuse()
with mock.patch.object(batocera_targets_scraper.urllib.request, "urlopen", urlopen):
data = knulli_targets_scraper.Scraper().fetch_targets()
self.assertEqual(data["platform"], "knulli")
self.assertEqual(data["source"],
f"https://github.com/knulli-cfw/knulli-linux/tree/{pin}")
self.assertEqual(sorted(data["targets"]), ["h700", "r16"])
self.assertEqual(data["targets"]["h700"],
{"architecture": "aarch64", "cores": ["mgba", "ppsspp"]})
self.assertEqual(data["targets"]["r16"],
{"architecture": "arm", "cores": ["mgba"]})
self.assertTrue(all(pin in url or "buildroot/c2d7985b" in url for url in seen), seen)
class RocknixPerDevice(unittest.TestCase):
"""ROCKNIX had no target list: an H700 handheld got the PS2, GameCube
and PS3 firmware of emulators its image does not carry."""
+1
View File
@@ -332,6 +332,7 @@ Register the target scraper in `_registry.yml`:
|---------|--------|----------|
| `retroarch_targets` | libretro buildbot nightly | Scrape directory listings for each target arch |
| `batocera_targets` | Config.in + es_systems.yml | Cross-reference kernel config with system definitions |
| `knulli_targets` | KNULLI's own Config.in + es_systems.yml | The Batocera scraper's Kconfig resolution against KNULLI's tree |
| `emudeck_targets` | EmuScripts + RetroArch cores | GitHub API for script availability per OS |
| `retropie_targets` | scriptmodules + rp_module_flags | Parse Bash scriptmodules for platform flags |
| `lakka_targets` | Lakka-LibreELEC `package.mk` and project options | Core list minus each project and device's exclusions |
+1
View File
@@ -1665,6 +1665,7 @@ Located in `scripts/scraper/targets/`. Each inherits `BaseTargetScraper` and imp
|---------|--------|----------------|
| `retroarch_targets_scraper` | libretro buildbot nightly listings | buildbot architecture |
| `batocera_targets_scraper` | Config.in + es_systems.yml + Buildroot Kconfig | board |
| `knulli_targets_scraper` | the same, read from KNULLI's tree and Buildroot fork | board |
| `recalbox_targets_scraper` | board defconfigs + system.ini cores | board |
| `rocknix_targets_scraper` | emulators package.mk + device options | device |
| `lakka_targets_scraper` | libretro_cores package.mk + project and device options | device image |