mirror of
https://github.com/lutris/lutris
synced 2024-09-28 20:13:32 +00:00
small fix for developing on NixOS
adds a small condititon before finding a system-wide wine istallation because `/usr/lib` doesn't exist on NixOS
This commit is contained in:
parent
85082abc80
commit
739f075a10
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -16,6 +16,8 @@ pga.db
|
|||
tests/coverage/*
|
||||
/dist
|
||||
/lutris.egg-info
|
||||
/flake.nix
|
||||
/flake.lock
|
||||
|
||||
# meson builddirs
|
||||
builddir
|
||||
|
|
|
@ -24,11 +24,12 @@ WINE_PATHS: Dict[str, str] = {
|
|||
|
||||
# Insert additional system-wide Wine installations.
|
||||
try:
|
||||
for _candidate in os.listdir("/usr/lib/"):
|
||||
if _candidate.startswith("wine-"):
|
||||
_wine_path = os.path.join("/usr/lib/", _candidate, "bin/wine")
|
||||
if os.path.isfile(_wine_path):
|
||||
WINE_PATHS["System " + _candidate] = _wine_path
|
||||
if system.path_exists("/usr/lib"):
|
||||
for _candidate in os.listdir("/usr/lib/"):
|
||||
if _candidate.startswith("wine-"):
|
||||
_wine_path = os.path.join("/usr/lib/", _candidate, "bin/wine")
|
||||
if os.path.isfile(_wine_path):
|
||||
WINE_PATHS["System " + _candidate] = _wine_path
|
||||
_candidate = None
|
||||
_wine_path = None
|
||||
except Exception as ex:
|
||||
|
|
Loading…
Reference in a new issue