fix: place AdvanceMAME's sets in EmuELEC's dir_rom

AdvanceMAME reads its sets from dir_rom, a list of folders
(advance/osd/fileio.c:74, doc/advmame.d:680,699-701). EmuELEC's
advmame.rc sets dir_rom /storage/roms/mame (advmame.rc:11), and
advmame.sh rewrites /roms/mame to /roms/arcade when it is started for
the arcade system (advmame.sh:26-30). The extractor kept the keys under
the BIOS root alone: it now records those under the roms root too, and
a key the script rewrites gives one record for arcade and one for every
other system. A configgen record carries the systems it is written for.

The profile lays its 29 sets out at the top of dir_rom. On EmuELEC they
land in roms/mame. The 12 root archives AdvanceMAME alone claimed there
now hold the copies of the cores that also declare them (mame, geolith),
none of them lost.

A destination outside the BIOS tree is no proof of content: the moved
entry resolves by its layout path alone. roms/mame/konamigv.zip took
bios/Arcade/MAME/konamigv.zip, MAME 0.289's set, by that tail.
This commit is contained in:
Abdessamad Derraz committed 2026-11-10 13:07:12 +01:00
1 parent 4a5c693b66
commit 8eaffcfead
7 files changed
+384 -29

No files matched your search

+4 -1
View File
@@ -1541,12 +1541,15 @@ def resolve_local_file(
layout = file_entry.get("layout_path")
if layout and layout != dest_hint:
plain = {k: v for k, v in file_entry.items() if k != "layout_path"}
# A destination outside the BIOS tree says nothing of the collection:
# EmuELEC's roms/mame/konamigv.zip is not bios/Arcade/MAME's set.
outside = file_entry.get("unprefixed") or file_entry.get("root")
answers = [
resolve_local_file(
plain, db, zip_contents, dest_hint=hint, _depth=_depth,
data_dir_registry=data_dir_registry,
)
for hint in (dest_hint, str(layout))
for hint in ((str(layout),) if outside else (dest_hint, str(layout)))
]
for found in answers:
if found[0] is not None and (