mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-11-24 02:27:52 -06:00
fix: one rule for a file every setup installs
This commit is contained in:
1 parent
501b2a84f3
commit
5dbd2df9ec
6 files changed
+37
-9
No files matched your search
@@ -46,6 +46,7 @@ from resolve.validation import (
|
||||
case_folded_slots,
|
||||
declaration_settles,
|
||||
inner_rom_check,
|
||||
installed_everywhere,
|
||||
installed_with_emulator,
|
||||
outside_gap_scope,
|
||||
read_from_save_dir,
|
||||
@@ -915,7 +916,8 @@ class _ProfileComparison:
|
||||
"name": fname,
|
||||
"path": effective_path,
|
||||
"required": f.get("required", False),
|
||||
"bundled": installed_with_emulator(f, platform),
|
||||
"bundled": (installed_with_emulator(f, platform) if platform
|
||||
else installed_everywhere(f)),
|
||||
"note": f.get("note", ""),
|
||||
"source_ref": f.get("source_ref", ""),
|
||||
"in_platform": False,
|
||||
|
||||
@@ -764,6 +764,15 @@ def installed_with_emulator(entry: dict, platform: str = "") -> bool:
|
||||
return bool(entry.get("bundled")) and platform not in (entry.get("not_bundled_on") or [])
|
||||
|
||||
|
||||
def installed_everywhere(entry: dict) -> bool:
|
||||
"""Whether the emulator brings the entry on every setup, for a view that names none.
|
||||
|
||||
An entry a platform package leaves out (`not_bundled_on`) is a file that
|
||||
setup's users still need: touchHLE panics without its fonts on ROCKNIX.
|
||||
"""
|
||||
return bool(entry.get("bundled")) and not entry.get("not_bundled_on")
|
||||
|
||||
|
||||
def unread_on(entry: dict, platform: str) -> bool:
|
||||
"""Whether this platform's launcher points the emulator at other files.
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ from model.registry import list_release_pack_platforms
|
||||
from model.profiles import reads_own_files
|
||||
from resolve.layout import runs_standalone, standalone_layout_path
|
||||
from resolve.standalone import standalone_set
|
||||
from resolve.validation import installed_with_emulator
|
||||
from resolve.validation import installed_everywhere, installed_with_emulator
|
||||
from sitegen import markup
|
||||
from core.paths import REPO_ROOT
|
||||
from installer_build.module import installer_module
|
||||
@@ -79,14 +79,14 @@ def _platform_display_in(platforms_dir: str, name: str) -> str:
|
||||
def comes_with_app(f: dict) -> bool:
|
||||
"""The emulator installs the file in the build the entry describes, on every setup.
|
||||
|
||||
The rule verify and the pack read (``installed_with_emulator``), for a
|
||||
page that names no setup. An entry a platform package leaves out
|
||||
The rule the gap report and the wanted list read (``installed_everywhere``),
|
||||
for a page that names no setup. An entry a platform package leaves out
|
||||
(``not_bundled_on``: Batocera's hcl installs the binary alone) is a file
|
||||
that setup's readers get, and the manifests serve it there. An entry
|
||||
narrowed by ``mode`` is that build's alone: the other build reads its
|
||||
own entry, or nothing.
|
||||
"""
|
||||
return installed_with_emulator(f) and not f.get("not_bundled_on")
|
||||
return installed_everywhere(f)
|
||||
|
||||
|
||||
def install_commands(args: str = "", indent: str = "",
|
||||
|
||||
@@ -28,7 +28,7 @@ from model.profiles import unique_emulator_profiles
|
||||
from packs.crossref import first_hash
|
||||
from core.hashing import cut_md5_owner, declared_hash_lists, parse_hash_list
|
||||
from resolve.review import LARGE_FILE_ISSUE_URL, Placement, placement
|
||||
from resolve.validation import deliverable, filter_files_by_mode, installed_with_emulator
|
||||
from resolve.validation import deliverable, filter_files_by_mode, installed_everywhere
|
||||
from sitegen.config import UPLOAD_ROOT
|
||||
|
||||
ALGORITHMS = ("sha1", "sha256", "md5", "crc32")
|
||||
@@ -231,7 +231,7 @@ def wanted_declarations(profiles: dict, coverages: dict, gap_report: dict) -> li
|
||||
for row, unsourceable in rows:
|
||||
for entry in gap_entries(profile, str(row.get("name", "")),
|
||||
str(row.get("identity") or ""), unsourceable):
|
||||
if entry.get("category") == GAME_DATA or installed_with_emulator(entry):
|
||||
if entry.get("category") == GAME_DATA or installed_everywhere(entry):
|
||||
continue
|
||||
system = entry.get("system") or (systems[0] if len(systems) == 1 else "")
|
||||
found.append({
|
||||
|
||||
Reference in new issue
Block a user