Makefile.minimal - MinGW/cmd support

Changed Makefile.minimal to support MinGW/cmd. Someone should test it with Linux or it could just be offered as an alternative to the current one which refuses to work under MinGW/cmd.

Code:

Makefile to build the SDL library

INCLUDE = -I./include
CFLAGS = -g -O2 $(INCLUDE)
AR = ar
RANLIB = ranlib

ifeq ($(OS),Windows_NT)
RM = del /Q
FixPath = $(subst /,,$1)
else
RM = rm -f
FixPath = $1
endif

TARGET = libSDL.a
SOURCES =
src/.c
src/audio/
.c
src/audio/dummy/.c
src/cpuinfo/
.c
src/events/.c
src/file/
.c
src/haptic/.c
src/haptic/dummy/
.c
src/joystick/.c
src/joystick/dummy/
.c
src/loadso/dummy/.c
src/power/
.c
src/filesystem/dummy/.c
src/render/
.c
src/render/software/.c
src/stdlib/
.c
src/thread/.c
src/thread/generic/
.c
src/timer/.c
src/timer/dummy/
.c
src/video/.c
src/video/dummy/
.c \

OBJECTS = $(patsubst %.c,%.o,$(wildcard $(SOURCES)))

all: $(TARGET)

$(TARGET): $(OBJECTS)
$(AR) crv $@ $^
$(RANLIB) $@

clean:
$(RM) $(call FixPath,$(TARGET) $(OBJECTS))------------------------
SGScript scripting engine (http://www.sgscript.org)

Before anybody complains: yes, it’s perfectly possible to end up with
MinGW without MSYS because they come separately (in fact I could never
figure out from where to get MSYS). Also Code::Blocks comes with MinGW
without installing MSYS, though that’s vanilla MinGW (instead of
MinGW-w64) so that one won’t work fine with SDL anyway.