From 05ba352f2f874127d91ccbab51f2ad777afa9881 Mon Sep 17 00:00:00 2001 From: Alvaro Burnett Date: Mon, 12 Mar 2018 22:38:05 +0100 Subject: [PATCH] Makefile: Find SDL2.dll --- Makefile | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 140a2c2b..3d5a6322 100755 --- a/Makefile +++ b/Makefile @@ -235,12 +235,9 @@ $(OBJ)/%.res: %.rc %.o: %.res cvtres /OUT:"$@" $^ -# We must provide SDL2.dll with the Windows port. This is an AWFUL HACK to find it. -SPACE := -SPACE += +# We must provide SDL2.dll with the Windows port. $(BIN)/SDL/SDL2.dll: - @$(eval POTENTIAL_MATCHES := $(subst @@@," ",$(patsubst %,%/SDL2.dll,$(subst ;,$(SPACE),$(subst $(SPACE),@@@,$(lib)))))) - @$(eval MATCH := $(shell ls $(POTENTIAL_MATCHES) 2> NUL | head -n 1)) + @$(eval MATCH := $(shell where $$LIB:SDL2.dll)) cp "$(MATCH)" $@ # Tester