mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-11-06 01:53:56 -06:00
fix: one core name per RetroPie package
The platform scraper kept lr-dosbox-pure as dosbox-pure, which matched the standalone DOSBox Pure Unleashed profile, while the target scraper wrote dosbox_pure. Both now read core_name(), and platforms/retropie.yml is rescraped at its pinned revision 46128cd2: only the libretro core names change, and six Unleashed files leave the RetroPie manifest.
This commit is contained in:
1 parent
39e6afbeb2
commit
87f6211983
5 files changed
+67
-110
No files matched your search
+4
-82
@@ -16,10 +16,10 @@
|
||||
}
|
||||
],
|
||||
"standalone_copies": [],
|
||||
"total_files": 8690,
|
||||
"total_size": 8755302720,
|
||||
"pack_files": 14766,
|
||||
"pack_size": 8873685802,
|
||||
"total_files": 8684,
|
||||
"total_size": 8721213852,
|
||||
"pack_files": 14760,
|
||||
"pack_size": 8839596934,
|
||||
"total_omitted": 347,
|
||||
"omitted_files": [
|
||||
{
|
||||
@@ -20248,19 +20248,6 @@
|
||||
],
|
||||
"category": "game_data"
|
||||
},
|
||||
{
|
||||
"dest": "system/CM32LN_CONTROL.ROM",
|
||||
"sha1": "dc1c5b1b90a4646d00f7daf3679733c7badc7077",
|
||||
"sha256": "9f32c5a670421961c3d46a9cdcff0a1d333b886a72c0c260c9607645a3abf773",
|
||||
"size": 65536,
|
||||
"repo_path": "bios/DOS/DOSBox/CM32LN_CONTROL.ROM",
|
||||
"cores": [
|
||||
"dosbox-pure-unleashed"
|
||||
],
|
||||
"systems": [
|
||||
"dos"
|
||||
]
|
||||
},
|
||||
{
|
||||
"dest": "mt32-roms/ctrl_mt32_1_04.rom",
|
||||
"sha1": "5a5cb5a77d7d55ee69657c2f870416daed52dea7",
|
||||
@@ -92505,19 +92492,6 @@
|
||||
"dos"
|
||||
]
|
||||
},
|
||||
{
|
||||
"dest": "system/DOSBOX.SF2",
|
||||
"sha1": "a00461dbea40093cb9ca1694de9c0ec7ca5650c1",
|
||||
"sha256": "9575028c7a1f589f5770fccc8cff2734566af40cd26ed836944e9a5152688cfe",
|
||||
"size": 32319396,
|
||||
"repo_path": "bios/Other/GeneralUser GS/GeneralUser-GS.sf2",
|
||||
"cores": [
|
||||
"dosbox-pure-unleashed"
|
||||
],
|
||||
"systems": [
|
||||
"dos"
|
||||
]
|
||||
},
|
||||
{
|
||||
"dest": "soundfonts/GeneralUser-GS.sf2",
|
||||
"sha1": "a00461dbea40093cb9ca1694de9c0ec7ca5650c1",
|
||||
@@ -119354,58 +119328,6 @@
|
||||
"nintendo-gamecube"
|
||||
]
|
||||
},
|
||||
{
|
||||
"dest": "system/MT32_CONTROL.ROM",
|
||||
"sha1": "5a5cb5a77d7d55ee69657c2f870416daed52dea7",
|
||||
"sha256": "c0ea149eaadc48049572ec429e45f90ab1bb75f1ed07000c636fc0124b64da23",
|
||||
"size": 65536,
|
||||
"repo_path": "bios/Roland/mt32-roms/ctrl_mt32_1_04.rom",
|
||||
"cores": [
|
||||
"dosbox-pure-unleashed"
|
||||
],
|
||||
"systems": [
|
||||
"dos"
|
||||
]
|
||||
},
|
||||
{
|
||||
"dest": "system/CM32L_CONTROL.ROM",
|
||||
"sha1": "73683d585cd6948cc19547942ca0e14a0319456d",
|
||||
"sha256": "c8aea5fb1b28183523601bbc5fd7e2f48397c1cb26f8687d240333c2190e83e2",
|
||||
"size": 65536,
|
||||
"repo_path": "bios/Roland/mt32-roms/ctrl_cm32l_1_00.rom",
|
||||
"cores": [
|
||||
"dosbox-pure-unleashed"
|
||||
],
|
||||
"systems": [
|
||||
"dos"
|
||||
]
|
||||
},
|
||||
{
|
||||
"dest": "system/MT32_PCM.ROM",
|
||||
"sha1": "f6b1eebc4b2d200ec6d3d21d51325d5b48c60252",
|
||||
"sha256": "d9164063f293410cf33f2f64cdcea6893b44723fe41938e07ec9aef58b406238",
|
||||
"size": 524288,
|
||||
"repo_path": "bios/Roland/MT-32/MT32_PCM.ROM",
|
||||
"cores": [
|
||||
"dosbox-pure-unleashed"
|
||||
],
|
||||
"systems": [
|
||||
"dos"
|
||||
]
|
||||
},
|
||||
{
|
||||
"dest": "system/CM32L_PCM.ROM",
|
||||
"sha1": "289cc298ad532b702461bfc738009d9ebe8025ea",
|
||||
"sha256": "0dc50190bb7ea3fb212c970346b771a511772b528801e7eda6d27efda8c40698",
|
||||
"size": 1048576,
|
||||
"repo_path": "bios/Roland/CM-32L/CM32L_PCM.ROM",
|
||||
"cores": [
|
||||
"dosbox-pure-unleashed"
|
||||
],
|
||||
"systems": [
|
||||
"dos"
|
||||
]
|
||||
},
|
||||
{
|
||||
"dest": "fbalpha2012/hiscore.dat",
|
||||
"sha1": "7381472bf046126257e51a0124e4553282f020e5",
|
||||
|
||||
+19
-18
@@ -14,16 +14,16 @@ cores:
|
||||
- amiberry
|
||||
- atari800
|
||||
- basilisk
|
||||
- beetle-lynx
|
||||
- beetle-ngp
|
||||
- beetle-pce
|
||||
- beetle-pce-fast
|
||||
- beetle-pcfx
|
||||
- beetle-psx
|
||||
- beetle-saturn
|
||||
- beetle-supergrafx
|
||||
- beetle-vb
|
||||
- beetle-wswan
|
||||
- beetle_lynx
|
||||
- beetle_ngp
|
||||
- beetle_pce
|
||||
- beetle_pce_fast
|
||||
- beetle_pcfx
|
||||
- beetle_psx
|
||||
- beetle_saturn
|
||||
- beetle_supergrafx
|
||||
- beetle_vb
|
||||
- beetle_wswan
|
||||
- bennugd
|
||||
- bluemsx
|
||||
- bsnes
|
||||
@@ -42,9 +42,9 @@ cores:
|
||||
- dirksimple
|
||||
- dolphin
|
||||
- dosbox
|
||||
- dosbox-pure
|
||||
- dosbox-sdl2
|
||||
- dosbox-staging
|
||||
- dosbox_pure
|
||||
- drastic
|
||||
- dsda-doom
|
||||
- dxx-rebirth
|
||||
@@ -55,7 +55,7 @@ cores:
|
||||
- fbzx
|
||||
- fceumm
|
||||
- flycast
|
||||
- flycast-dev
|
||||
- flycast_dev
|
||||
- fmsx
|
||||
- freechaf
|
||||
- freeintv
|
||||
@@ -66,7 +66,7 @@ cores:
|
||||
- geargrafx
|
||||
- gearsystem
|
||||
- gemrb
|
||||
- genesis-plus-gx
|
||||
- genesis_plus_gx
|
||||
- giana
|
||||
- gngeopi
|
||||
- gpsp
|
||||
@@ -89,7 +89,7 @@ cores:
|
||||
- mame
|
||||
- mame2000
|
||||
- mame2003
|
||||
- mame2003-plus
|
||||
- mame2003_plus
|
||||
- mame2010
|
||||
- mame2015
|
||||
- mame2016
|
||||
@@ -103,7 +103,7 @@ cores:
|
||||
- minivmac
|
||||
- mrboom
|
||||
- mupen64plus
|
||||
- mupen64plus-next
|
||||
- mupen64plus_next
|
||||
- mysticmine
|
||||
- neocd
|
||||
- nestopia
|
||||
@@ -120,9 +120,10 @@ cores:
|
||||
- opera
|
||||
- oricutron
|
||||
- osmose
|
||||
- parallel-n64
|
||||
- parallel_n64
|
||||
- pcsx-rearmed
|
||||
- pcsx2
|
||||
- pcsx_rearmed
|
||||
- picodrive
|
||||
- pifba
|
||||
- pisnes
|
||||
@@ -147,7 +148,7 @@ cores:
|
||||
- sdlpop
|
||||
- sdltrs
|
||||
- simcoupe
|
||||
- smsplus-gx
|
||||
- smsplus_gx
|
||||
- smw
|
||||
- snes9x
|
||||
- snes9x2002
|
||||
@@ -172,7 +173,7 @@ cores:
|
||||
- uae4all
|
||||
- uae4arm
|
||||
- uqm
|
||||
- vba-next
|
||||
- vba_next
|
||||
- vecx
|
||||
- vice
|
||||
- virtualjaguar
|
||||
|
||||
@@ -56,6 +56,18 @@ _VERSION = re.compile(r'^__version="([^"]+)"', re.MULTILINE)
|
||||
_PACKAGE_DIRS = _SCRIPT_SECTIONS
|
||||
|
||||
|
||||
def core_name(module_id: str) -> str:
|
||||
"""The core a RetroPie package installs, as the buildbot names it.
|
||||
|
||||
A libretro package is lr-<core> with the name hyphenated (lr-beetle-psx
|
||||
builds beetle_psx). A standalone package keeps its id (dosbox-staging).
|
||||
The platform and target scrapers both read it here.
|
||||
"""
|
||||
if module_id.startswith("lr-"):
|
||||
return module_id[3:].replace("-", "_")
|
||||
return module_id
|
||||
|
||||
|
||||
class Scraper(BaseScraper):
|
||||
"""Scraper for the RetroPie package list."""
|
||||
|
||||
@@ -148,10 +160,13 @@ class Scraper(BaseScraper):
|
||||
libretro cores and reads the same files, at BIOS/ instead of
|
||||
system/. Only the core list is its own.
|
||||
"""
|
||||
# A libretro package is lr-<core>; a standalone package is named
|
||||
# after the emulator itself.
|
||||
# A libretro package is lr-<core> with the buildbot name hyphenated
|
||||
# (lr-dosbox-pure builds dosbox_pure), as the target scraper reads
|
||||
# it; a standalone package is named after the emulator itself.
|
||||
# Kept hyphenated, lr-dosbox-pure named dosbox-pure, the standalone
|
||||
# DOSBox Pure Unleashed build RetroPie does not ship.
|
||||
modules = self.module_ids()
|
||||
cores = sorted({module.removeprefix("lr-") for module in modules})
|
||||
cores = sorted({core_name(m) for m in modules})
|
||||
libretro = {m.removeprefix("lr-") for m in modules if m.startswith("lr-")}
|
||||
# The retroarch package is the frontend that runs the lr- cores.
|
||||
standalone = sorted(
|
||||
|
||||
@@ -19,6 +19,7 @@ from datetime import datetime, timezone
|
||||
|
||||
import yaml
|
||||
|
||||
from ..retropie_scraper import core_name
|
||||
from . import BaseTargetScraper
|
||||
|
||||
PLATFORM_NAME = "retropie"
|
||||
@@ -158,15 +159,10 @@ class Scraper(BaseTargetScraper):
|
||||
if not module_id:
|
||||
print(f" warning: no rp_module_id in {filename}", file=sys.stderr)
|
||||
continue
|
||||
# A libretro package is lr-<core> with the buildbot name hyphenated
|
||||
# (lr-beetle-psx -> beetle_psx), and a standalone package keeps the id
|
||||
# the platform list carries (dosbox-staging).
|
||||
core_name = module_id
|
||||
if core_name.startswith("lr-"):
|
||||
core_name = core_name[3:].replace("-", "_")
|
||||
# The platform scraper names the package the same way.
|
||||
for platform in PLATFORM_FLAGS:
|
||||
if _is_available(flags, platform):
|
||||
platform_cores[platform].add(core_name)
|
||||
platform_cores[platform].add(core_name(module_id))
|
||||
|
||||
print(f" parsed {len(filenames)} scriptmodules", file=sys.stderr)
|
||||
|
||||
|
||||
@@ -289,6 +289,29 @@ class RetroPiePackageList(unittest.TestCase):
|
||||
self.assertEqual(config["inherits"], "retroarch")
|
||||
self.assertEqual(config["base_destination"], "BIOS")
|
||||
|
||||
def test_a_libretro_package_takes_the_buildbot_core_name(self):
|
||||
"""lr-dosbox-pure builds dosbox_pure. Kept hyphenated, it matched
|
||||
DOSBox Pure Unleashed, a standalone build RetroPie does not ship,
|
||||
while the target scraper wrote dosbox_pure."""
|
||||
from scraper.targets.retropie_targets_scraper import core_name as target_name
|
||||
|
||||
scraper = self._scraper(
|
||||
{
|
||||
"retropie_packages.sh": '__version="4.8.12"\n',
|
||||
"scriptmodules/libretrocores/lr-dosbox-pure.sh": (
|
||||
'rp_module_id="lr-dosbox-pure"\n'
|
||||
),
|
||||
"scriptmodules/emulators/dosbox-staging.sh": (
|
||||
'rp_module_id="dosbox-staging"\n'
|
||||
),
|
||||
}
|
||||
)
|
||||
cores = scraper.generate_platform_yaml()["cores"]
|
||||
self.assertEqual(cores, ["dosbox-staging", "dosbox_pure"])
|
||||
self.assertEqual(
|
||||
sorted(target_name(m) for m in scraper.module_ids()), cores
|
||||
)
|
||||
|
||||
def test_a_package_built_outside_libretro_runs_standalone(self):
|
||||
"""hatari ships as lr-hatari and as hatari: both layouts are read."""
|
||||
scraper = self._scraper(
|
||||
|
||||
Reference in new issue
Block a user