From 72e949676847473dcc71b70c99802c28301ff01a Mon Sep 17 00:00:00 2001 From: Alexandre Erwin Ittner Date: Tue, 19 Apr 2016 21:44:46 -0300 Subject: [PATCH] Use standard C compiler by default Always use the standard compiler as defined by the environment variable CC. User can set it when a different compiler if required (e.g. CC=clang make) --- demo/allegro5/Makefile | 13 ------------- demo/glfw/Makefile | 13 ------------- demo/sdl/Makefile | 13 ------------- demo/x11/Makefile | 13 ------------- example/Makefile | 3 --- 5 files changed, 55 deletions(-) diff --git a/demo/allegro5/Makefile b/demo/allegro5/Makefile index 2291c7e..b771258 100644 --- a/demo/allegro5/Makefile +++ b/demo/allegro5/Makefile @@ -1,10 +1,6 @@ # Install BIN = demo -# Compiler -CC = clang -DCC = gcc - # Flags CFLAGS = -std=c89 -pedantic @@ -23,15 +19,6 @@ else endif endif -# Modes -.PHONY: gcc -gcc: CC = gcc -gcc: $(BIN) - -.PHONY: clang -clang: CC = clang -clang: $(BIN) - $(BIN): @mkdir -p bin rm -f bin/$(BIN) $(OBJS) diff --git a/demo/glfw/Makefile b/demo/glfw/Makefile index 6d01ab2..8b0615b 100644 --- a/demo/glfw/Makefile +++ b/demo/glfw/Makefile @@ -1,10 +1,6 @@ # Install BIN = demo -# Compiler -CC = clang -DCC = gcc - # Flags CFLAGS = -std=c99 -pedantic -O2 @@ -23,15 +19,6 @@ else endif endif -# Modes -.PHONY: clang -clang: CC = clang -clang: $(BIN) - -.PHONY: gcc -gcc: CC = gcc -gcc: $(BIN) - $(BIN): @mkdir -p bin rm -f bin/$(BIN) $(OBJS) diff --git a/demo/sdl/Makefile b/demo/sdl/Makefile index 4f0ec7f..4b8ccf4 100644 --- a/demo/sdl/Makefile +++ b/demo/sdl/Makefile @@ -1,10 +1,6 @@ # Install BIN = demo -# Compiler -CC = clang -DCC = gcc - # Flags CFLAGS = -std=c99 -pedantic -O2 @@ -23,15 +19,6 @@ else endif endif -# Modes -.PHONY: clang -clang: CC = clang -clang: $(BIN) - -.PHONY: gcc -gcc: CC = gcc -gcc: $(BIN) - $(BIN): @mkdir -p bin rm -f bin/$(BIN) $(OBJS) diff --git a/demo/x11/Makefile b/demo/x11/Makefile index 19a2c27..0570089 100644 --- a/demo/x11/Makefile +++ b/demo/x11/Makefile @@ -1,25 +1,12 @@ # Install BIN = zahnrad -# Compiler -CC = clang -DCC = gcc - # Flags CFLAGS = -std=c89 -pedantic -O2 SRC = main.c OBJ = $(SRC:.c=.o) -# Modes -.PHONY: gcc -gcc: CC = gcc -gcc: $(BIN) - -.PHONY: clang -clang: CC = clang -clang: $(BIN) - $(BIN): @mkdir -p bin rm -f bin/$(BIN) $(OBJS) diff --git a/example/Makefile b/example/Makefile index fc32735..82d5849 100644 --- a/example/Makefile +++ b/example/Makefile @@ -1,6 +1,3 @@ -# Compiler -CC = clang - # Flags CFLAGS = -std=c99 -pedantic -O2