From 6d93e3873450055cc46a347daac0cbb6451bd9b4 Mon Sep 17 00:00:00 2001 From: Yamagi Burmeister Date: Thu, 13 Feb 2014 08:12:18 +0100 Subject: [PATCH] Port the Makefile to our new Windows build environment --- Makefile | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/Makefile b/Makefile index 3efff4b..24595e1 100644 --- a/Makefile +++ b/Makefile @@ -6,12 +6,14 @@ # # # Dependencies: # # - None, but you need a Quake II to play. # -# While in theorie every one should work # +# While in theorie every client should work # # Yamagi Quake II ist recommended. # # # # Platforms: # # - FreeBSD # # - Linux # +# - Mac OS X # +# - OpenBSD # # - Windows # # ----------------------------------------------------- # @@ -22,6 +24,11 @@ else OSTYPE := $(shell uname -s) endif +# Special case for MinGW +ifneq (,$(findstring MINGW,$(OSTYPE))) +OSTYPE := Windows +endif + # Detect the architecture ifeq ($(OSTYPE), Windows) # At this time only i386 is supported on Windows @@ -98,15 +105,9 @@ endif # ---------- # Cleanup -ifeq ($(OSTYPE), Windows) -clean: - @echo "===> CLEAN" - @-rmdir /S /Q release build -else clean: @echo "===> CLEAN" ${Q}rm -Rf build release -endif # ---------- @@ -114,12 +115,12 @@ endif ifeq ($(OSTYPE), Windows) rogue: @echo "===> Building game.dll" - ${Q}tools/mkdir.exe -p release + ${Q}mkdir -p release $(MAKE) release/game.dll build/%.o: %.c @echo "===> CC $<" - ${Q}tools/mkdir.exe -p $(@D) + ${Q}mkdir -p $(@D) ${Q}$(CC) -c $(CFLAGS) -o $@ $< else rogue: