Minor fix to Makefile

This commit is contained in:
Stephen Seo 2024-04-23 15:55:48 +09:00
parent f05103d871
commit 8e4c179747

View file

@ -5,7 +5,7 @@ COMMON_CXXFLAGS = -Wall -Wextra -Wpedantic -std=c++20 \
-fstrict-flex-arrays=3 \
-fstack-clash-protection -fstack-protector-strong \
-Wl,-z,nodlopen -Wl,-z,noexecstack \
-Wl,-z,relro -Wl,-z,now
-Wl,-z,relro -Wl,-z,now -fPIE
ifdef DEBUG
CXXFLAGS = -Og -g ${COMMON_CXXFLAGS}
else
@ -21,7 +21,7 @@ OBJECTS = $(addprefix ${OBJDIR}/,$(patsubst %.cpp,%.cpp.o,${SOURCES}))
all: KoreanNumbers
KoreanNumbers: ${OBJECTS}
$(CXX) $(CXXFLAGS) -fPIE -pie -o KoreanNumbers $^
$(CXX) $(CXXFLAGS) -pie -o KoreanNumbers $^
${OBJDIR}/%.cpp.o: %.cpp
@mkdir -p $(dir $@)