aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorcaRJ33 <caRJ33@users.noreply.github.com>2019-01-02 23:31:45 +0100
committerGitHub <noreply@github.com>2019-01-02 23:31:45 +0100
commit566b197a06da81fff276f08ce9c9d47fbba550eb (patch)
treeb3f7e54635c6813c6e7477f85af9eae7e17410a9 /Makefile
parent94ca6aa4514d30f69144ff00a40a2e21d0da7211 (diff)
parentbe40a3392874af93c11953f253bcbf21930f5b7e (diff)
Merge pull request #3 from caRJ33/masterHEADmaster
Add 'proper' Windows support
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile24
1 files changed, 24 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 3ab6ba2..b08f044 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,11 @@
CC = gcc
+RM = rm
+RMFLAGS = -f
+
+ifeq ($(OS),Windows_NT)
+ RM = del
+ RMFLAGS = /F /Q
+endif
CFLAGS = -c
LDFLAGS =
@@ -7,6 +14,23 @@ LIBS = -lm
OBJS = main.o
+.PHONY: all debug release clean
+
+all: debug
+
+debug: CFLAGS += -g -Og
+debug: LDFLAGS += -g -Og
+debug: taint-info
+
+release: CFLAGS += -O3 -s
+release: LDFLAGS += -O3 -s
+release: taint-info
+
+clean:
+ -$(RM) $(RMFLAGS) $(OBJS)
+ -$(RM) $(RMFLAGS) taint-info.exe
+ -$(RM) $(RMFLAGS) taint-info
+
%.o: %.c
$(CC) $(CFLAGS) -o $@ $<