Set path to source port binary in Makefile

This commit is contained in:
Simon Howard 2024-08-31 16:16:27 -04:00
parent 71fbd71195
commit 3243cc4968
2 changed files with 4 additions and 1 deletions

View File

@ -1,4 +1,5 @@
export SOURCE_PORT = $(shell which chocolate-doom)
export SDL_VIDEODRIVER = dummy
export DOOMOPTS = -mb 16 -nodraw -noblit -nosound \
-noautoload -nogui -nograbmouse

View File

@ -20,11 +20,13 @@ def read_config(path):
return result
source_port = os.getenv("SOURCE_PORT")
assert source_port != "", "SOURCE_PORT environment variable not set."
lmp_file, out_file = sys.argv[1:]
cfg = read_config(lmp_file)
args = [
"chocolate-doom", "-iwad", cfg["iwad"],
source_port, "-iwad", cfg["iwad"],
"-statdump", out_file,
"-timedemo", lmp_file,
] + shlex.split(os.getenv("DOOMOPTS", ""))