From 1dd3f1cdc12ee530bdd93252dc25f25998aae013 Mon Sep 17 00:00:00 2001 From: Danyal Ahmed <58849388+danyalahmed1995@users.noreply.github.com> Date: Sat, 30 May 2026 22:52:51 +0500 Subject: [PATCH] proton: detect incomplete default_pfx --- proton | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/proton b/proton index 54557e93bd8..23aa305c1a6 100755 --- a/proton +++ b/proton @@ -578,8 +578,13 @@ class Proton: f.write(new_fixup_mtime + "\n") def missing_default_prefix(self): - '''Check if the default prefix dir is missing. Returns true if missing, false if present''' - return not os.path.isdir(self.default_pfx_dir) + '''Check if the default prefix dir is missing or incomplete. Returns true if missing, false if present''' + required_paths = ( + self.default_pfx_dir + "system.reg", + self.default_pfx_dir + "drive_c/windows/system32/d3d8.dll", + self.default_pfx_dir + "drive_c/windows/syswow64/d3d8.dll", + ) + return any(not os.path.isfile(path) for path in required_paths) def make_default_prefix(self): with self.dist_lock: