aboutsummaryrefslogtreecommitdiff
path: root/makefile
diff options
context:
space:
mode:
Diffstat (limited to 'makefile')
-rw-r--r--makefile21
1 files changed, 11 insertions, 10 deletions
diff --git a/makefile b/makefile
index 8160d4fb..8bc386df 100644
--- a/makefile
+++ b/makefile
@@ -16,12 +16,12 @@ CWARNSCPP= \
16 -Wdisabled-optimization \ 16 -Wdisabled-optimization \
17 -Waggregate-return \ 17 -Waggregate-return \
18 -Wdouble-promotion \ 18 -Wdouble-promotion \
19 #-Wno-aggressive-loop-optimizations # not accepted by clang \ 19 -Wstrict-aliasing=3 # not accepted by clang \
20 #-Wlogical-op # not accepted by clang \ 20 -Wno-aggressive-loop-optimizations # not accepted by clang \
21 -Wlogical-op # not accepted by clang \
21 # the next warnings generate too much noise, so they are disabled 22 # the next warnings generate too much noise, so they are disabled
22 # -Wconversion -Wno-sign-conversion \ 23 # -Wconversion -Wno-sign-conversion \
23 # -Wsign-conversion \ 24 # -Wsign-conversion \
24 # -Wconversion \
25 # -Wstrict-overflow=2 \ 25 # -Wstrict-overflow=2 \
26 # -Wformat=2 \ 26 # -Wformat=2 \
27 # -Wcast-qual \ 27 # -Wcast-qual \
@@ -35,7 +35,7 @@ CWARNSC= -Wdeclaration-after-statement \
35 -Wold-style-definition \ 35 -Wold-style-definition \
36 36
37 37
38CWARNS= $(CWARNSCPP) $(CWARNSC) 38CWARNS= $(CWARNSCPP) $(CWARNSC)
39 39
40 40
41# -DEXTERNMEMCHECK -DHARDSTACKTESTS -DHARDMEMTESTS -DTRACEMEM='"tempmem"' 41# -DEXTERNMEMCHECK -DHARDSTACKTESTS -DHARDMEMTESTS -DTRACEMEM='"tempmem"'
@@ -43,23 +43,24 @@ CWARNS= $(CWARNSCPP) $(CWARNSC)
43# -pg -malign-double 43# -pg -malign-double
44# -DLUA_USE_CTYPE -DLUA_USE_APICHECK 44# -DLUA_USE_CTYPE -DLUA_USE_APICHECK
45# (in clang, '-ftrapv' for runtime checks of integer overflows) 45# (in clang, '-ftrapv' for runtime checks of integer overflows)
46# -fsanitize=undefined -ftrapv 46# -fsanitize=undefined -ftrapv -fno-inline
47TESTS= -DLUA_USER_H='"ltests.h"' 47TESTS= -DLUA_USER_H='"ltests.h"' -O0
48 48
49# -mtune=native -fomit-frame-pointer 49# -mtune=native -fomit-frame-pointer
50# -fno-stack-protector 50# -fno-stack-protector
51LOCAL = $(TESTS) $(CWARNS) -g 51# -DLUA_NILINTABLE
52LOCAL = $(TESTS) $(CWARNS) -g -DEXTERNMEMCHECK
52 53
53 54
54 55
55# enable Linux goodies 56# enable Linux goodies
56MYCFLAGS= $(LOCAL) -std=c99 -DLUA_USE_LINUX -DLUA_COMPAT_5_2 57MYCFLAGS= $(LOCAL) -std=c99 -DLUA_USE_LINUX
57MYLDFLAGS= $(LOCAL) -Wl,-E 58MYLDFLAGS= $(LOCAL) -Wl,-E
58MYLIBS= -ldl -lreadline 59MYLIBS= -ldl -lreadline
59 60
60 61
61CC= clang-3.8 62CC= gcc
62CFLAGS= -Wall -O2 $(MYCFLAGS) 63CFLAGS= -Wall -O2 $(MYCFLAGS) -Wfatal-errors
63AR= ar rcu 64AR= ar rcu
64RANLIB= ranlib 65RANLIB= ranlib
65RM= rm -f 66RM= rm -f