Skip to content

Commit b170f69

Browse files
committed
Add extra flag in invariant Makefile to build a non-PIE executable.
1 parent b916de7 commit b170f69

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

regression/invariants/Makefile

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,17 @@ OBJ += ../../src/big-int/big-int$(LIBEXT) \
1010
include ../../src/config.inc
1111
include ../../src/common
1212

13+
ifeq ($(OS),Windows_NT)
14+
detected_OS := Windows
15+
else
16+
detected_OS := $(shell sh -c 'uname 2>/dev/null || echo Unknown')
17+
endif
18+
19+
ifeq ($(detected_OS),Linux)
20+
CFLAGS += "-no-pie"
21+
CXXFLAGS += "-no-pie"
22+
endif
23+
1324
test: driver$(EXEEXT)
1425
@../test.pl -e -p -c ../driver
1526

0 commit comments

Comments
 (0)