mirror of
https://github.com/GrapheneOS/hardened_malloc.git
synced 2025-04-19 22:10:19 +02:00
use CC as CXX to make sure LTO is compatible
This commit is contained in:
parent
1bc201c4c1
commit
8d2df1deb8
1 changed files with 4 additions and 1 deletions
5
Makefile
5
Makefile
|
@ -40,7 +40,10 @@ SOURCES := chacha.c h_malloc.c memory.c pages.c random.c util.c
|
|||
OBJECTS := $(SOURCES:.c=.o)
|
||||
|
||||
ifeq ($(CONFIG_CXX_ALLOCATOR),true)
|
||||
LDLIBS += -lstdc++
|
||||
# make sure LTO is compatible in case CC and CXX don't match (such as clang and g++)
|
||||
CXX := $(CC)
|
||||
LDLIBS += -lstdc++ -shared-libgcc
|
||||
|
||||
SOURCES += new.cc
|
||||
OBJECTS += new.o
|
||||
endif
|
||||
|
|
Loading…
Add table
Reference in a new issue