mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-11-25 19:08:51 -06:00
fix: read targets from the config's own tree
resolve_platform_cores and offer_boards read the RetroArch and platform targets under the repository, whatever --platforms-dir a run was given, behind a process-long cache. load_platform_config now records the directory it read (_platforms_dir), the resolver reads targets from it, the cache is keyed on that directory, and downloadable_on takes it from its callers. The key is kept out of the published registry export.
This commit is contained in:
1 parent
6aca93231a
commit
8780398518
7 files changed
+69
-22
No files matched your search
@@ -18,6 +18,7 @@ from resolve.layout import (
|
||||
standalone_layout_path,
|
||||
)
|
||||
from model.declarations import ROMS_ROOT, outer_layout
|
||||
from model.platforms import config_platforms_dir
|
||||
from model.profiles import core_key, profile_names
|
||||
from core.paths import REPO_ROOT
|
||||
|
||||
@@ -63,12 +64,13 @@ def offer_boards(config: dict) -> dict[tuple[str, str], frozenset[str] | None]:
|
||||
|
||||
ROCKNIX writes a core under a `case "${DEVICE}"` branch for the devices
|
||||
it builds (`when`), and a default for a named device in board_defaults
|
||||
(DEVICE=RK3326). Boards are the platform's targets, aliases included.
|
||||
(DEVICE=RK3326). Boards are the platform's targets, aliases included,
|
||||
read from the directory the config was loaded from.
|
||||
"""
|
||||
platform = str(config.get("_key") or "")
|
||||
targets = list_available_targets(
|
||||
platform, str(REPO_ROOT / "platforms")
|
||||
) if platform else []
|
||||
targets = (
|
||||
list_available_targets(platform, config_platforms_dir(config)) if platform else []
|
||||
)
|
||||
names = {t["name"]: [t["name"], *t.get("aliases", [])] for t in targets}
|
||||
|
||||
def admitted(test: Callable[[str], bool]) -> set[str]:
|
||||
|
||||
Reference in new issue
Block a user