You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
43 lines
508 B
43 lines
508 B
# Defaults |
|
CC := clang |
|
DEBUG := 1 |
|
STATIC := 0 |
|
|
|
LDFLAGS := |
|
CFLAGS :=\ |
|
-std=c99 \ |
|
-Weverything \ |
|
-Wno-padded \ |
|
-Wno-disabled-macro-expansion \ |
|
-pedantic |
|
|
|
# Sources / Results |
|
SRC :=\ |
|
src/project/main.c |
|
|
|
LIBDIR := |
|
LIB :=\ |
|
c |
|
|
|
INCDIR :=\ |
|
src/ |
|
|
|
OUT := project |
|
|
|
# Conditionals / Appends |
|
LDFLAGS +=\ |
|
$(addprefix -L,${LIBDIR})\ |
|
$(addprefix -l,${LIB}) |
|
|
|
CFLAGS +=\ |
|
$(addprefix -I,${INCDIR}) |
|
|
|
ifeq (${DEBUG},1) |
|
CFLAGS += -g |
|
else |
|
CFLAGS += -O2 -Werror |
|
endif |
|
|
|
ifeq (${STATIC},1) |
|
LDFLAGS += -static |
|
endif
|
|
|