mirror of
https://github.com/ZeroTier/ZeroTierOne
synced 2025-08-21 13:54:15 -07:00
Cleanup, fix a valgrind error, stack use reduction.
This commit is contained in:
parent
e8ab6adf89
commit
9e80db0fd1
11 changed files with 4217 additions and 2120 deletions
|
@ -8,7 +8,7 @@ ifeq ($(origin CXX),default)
|
|||
endif
|
||||
|
||||
INCLUDES?=
|
||||
DEFS?=-D_FORTIFY_SOURCE=2
|
||||
DEFS?=
|
||||
LDLIBS?=
|
||||
DESTDIR?=
|
||||
|
||||
|
@ -55,14 +55,15 @@ endif
|
|||
|
||||
ifeq ($(ZT_DEBUG),1)
|
||||
override DEFS+=-DZT_TRACE
|
||||
override CFLAGS+=-Wall -g -O -pthread $(INCLUDES) $(DEFS)
|
||||
override CXXFLAGS+=-Wall -g -O -std=c++11 -pthread $(INCLUDES) $(DEFS)
|
||||
override CFLAGS+=-Wall -g -pthread $(INCLUDES) $(DEFS)
|
||||
override CXXFLAGS+=-Wall -g -std=c++11 -pthread $(INCLUDES) $(DEFS)
|
||||
override LDFLAGS+=
|
||||
STRIP?=echo
|
||||
# The following line enables optimization for the crypto code, since
|
||||
# C25519 in particular is almost UNUSABLE in -O0 even on a 3ghz box!
|
||||
node/Salsa20.o node/SHA512.o node/C25519.o node/Poly1305.o: CFLAGS = -Wall -O2 -g -pthread $(INCLUDES) $(DEFS)
|
||||
node/Salsa20.o node/SHA512.o node/C25519.o node/Poly1305.o: CXXFLAGS=-Wall -O2 -g -pthread $(INCLUDES) $(DEFS)
|
||||
else
|
||||
override DEFS+=-D_FORTIFY_SOURCE=2
|
||||
CFLAGS?=-O3 -fstack-protector
|
||||
override CFLAGS+=-Wall -fPIE -pthread $(INCLUDES) -DNDEBUG $(DEFS)
|
||||
CXXFLAGS?=-O3 -fstack-protector
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue