From d513db14282d6d2c8864f44751ca779ac3635016 Mon Sep 17 00:00:00 2001 From: schm1dtmac Date: Wed, 2 Sep 2026 05:03:15 +0100 Subject: [PATCH 1/3] [Mac OS X] Fix sys_ss_random_number_generator & cleanup some dead code --- Utilities/File.cpp | 9 +++++++++ rpcs3/rpcs3.cpp | 8 -------- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/Utilities/File.cpp b/Utilities/File.cpp index 7302dda0c2e9..065143120f89 100644 --- a/Utilities/File.cpp +++ b/Utilities/File.cpp @@ -1230,6 +1230,15 @@ bool fs::is_optical_raw_device(const std::string& path) { return false; } + +#if defined(__APPLE__) + // On Mac OS X optical disks will only ever be mounted under /dev/disk(whatever), similar for raw devices, + // so reject anything not containing the disk string. + if (!path.contains("disk")) + { + return false; + } +#endif struct ::stat file_info; diff --git a/rpcs3/rpcs3.cpp b/rpcs3/rpcs3.cpp index 814f8d982842..1faee2804354 100644 --- a/rpcs3/rpcs3.cpp +++ b/rpcs3/rpcs3.cpp @@ -655,14 +655,6 @@ int run_rpcs3(int argc, char** argv) } #endif -#if defined(__APPLE__) && defined(__x86_64__) - if (const utils::OS_version os = utils::get_OS_version(); - os.version_major == 14 && os.version_minor < 3 && (utils::get_cpu_brand().rfind("VirtualApple", 0) == 0)) - { - report_fatal_error(fmt::format("RPCS3 requires macOS 14.3.0 or later.\nYou're currently using macOS %i.%i.%i.\nPlease update macOS from System Settings.\n\n", os.version_major, os.version_minor, os.version_patch)); - } -#endif - ensure(thread_ctrl::is_main(), "Not main thread"); // Initialize thread pool finalizer (on first use) From f12b87814158800548b9e9c5a840be3fab1d09b1 Mon Sep 17 00:00:00 2001 From: Elad <18193363+elad335@users.noreply.github.com> Date: Wed, 2 Sep 2026 07:36:35 +0300 Subject: [PATCH 2/3] Update disk path validation for Mac OS X --- Utilities/File.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Utilities/File.cpp b/Utilities/File.cpp index 065143120f89..d23d91992017 100644 --- a/Utilities/File.cpp +++ b/Utilities/File.cpp @@ -1234,7 +1234,7 @@ bool fs::is_optical_raw_device(const std::string& path) #if defined(__APPLE__) // On Mac OS X optical disks will only ever be mounted under /dev/disk(whatever), similar for raw devices, // so reject anything not containing the disk string. - if (!path.contains("disk")) + if (!path.starts_with("/dev/disk") && !path.starts_with("/dev/rdisk")) { return false; } From 56f721355b2c39276370925ceb4bb7edc274a7c4 Mon Sep 17 00:00:00 2001 From: schm1dtmac Date: Wed, 2 Sep 2026 12:18:50 +0100 Subject: [PATCH 3/3] Address review --- Utilities/File.cpp | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/Utilities/File.cpp b/Utilities/File.cpp index d23d91992017..7a7f31de3d34 100644 --- a/Utilities/File.cpp +++ b/Utilities/File.cpp @@ -1225,21 +1225,20 @@ bool fs::is_optical_raw_device(const std::string& path) return false; #else - // Skip a useless check if the path cannot point to a device node (device nodes always live in "/dev") - if (!path.starts_with("/dev/")) - { - return false; - } - -#if defined(__APPLE__) +#ifdef __APPLE__ // On Mac OS X optical disks will only ever be mounted under /dev/disk(whatever), similar for raw devices, // so reject anything not containing the disk string. if (!path.starts_with("/dev/disk") && !path.starts_with("/dev/rdisk")) { return false; } +#else + // Skip a useless check if the path cannot point to a device node (device nodes always live in "/dev") + if (!path.starts_with("/dev/")) + { + return false; + } #endif - struct ::stat file_info; if (::stat(path.c_str(), &file_info) != 0)