From 9a58823b70a796d4248b149216187b74e3289162 Mon Sep 17 00:00:00 2001 From: Luke Usher Date: Tue, 1 Mar 2022 20:37:24 +0000 Subject: [PATCH] chihiro: emulate a chihiro system when boot.id is present --- src/core/kernel/init/CxbxKrnl.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/core/kernel/init/CxbxKrnl.cpp b/src/core/kernel/init/CxbxKrnl.cpp index 75176fc56..61c93b043 100644 --- a/src/core/kernel/init/CxbxKrnl.cpp +++ b/src/core/kernel/init/CxbxKrnl.cpp @@ -627,6 +627,7 @@ static bool CxbxrKrnlXbeSystemSelector(int BootFlags, // Detect XBE type : XbeType xbeType = CxbxKrnl_Xbe->GetXbeType(); EmuLogInit(LOG_LEVEL::INFO, "Auto detect: XbeType = %s", GetXbeTypeToStr(xbeType)); + // Convert XBE type into corresponding system to emulate. switch (xbeType) { case XbeType::xtChihiro: @@ -640,6 +641,10 @@ static bool CxbxrKrnlXbeSystemSelector(int BootFlags, break; DEFAULT_UNREACHABLE; } + + if (std::filesystem::exists(xbeDirectory / "boot.id")) { + emulate_system = SYSTEM_CHIHIRO; + } } EmuLogInit(LOG_LEVEL::INFO, "Host's compatible system types: %2X", reserved_systems);