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)
This commit is contained in:
parent
092f463ea9
commit
72e9496768
@ -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)
|
||||
|
@ -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)
|
||||
|
@ -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)
|
||||
|
@ -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)
|
||||
|
@ -1,6 +1,3 @@
|
||||
# Compiler
|
||||
CC = clang
|
||||
|
||||
# Flags
|
||||
CFLAGS = -std=c99 -pedantic -O2
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user