aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2024-02-12 09:27:00 +0000
committerDimitry Andric <dim@FreeBSD.org>2024-02-12 09:27:00 +0000
commitd9c0e2e16660ecbe33e780821e95508a1d7870b1 (patch)
treee876fd6f5ac3059a714a6e9ec62328b0d02356a5
parent81092e92ea5184c4eeedad58044d72cfef72dd24 (diff)
downloadsrc-d9c0e2e16660ecbe33e780821e95508a1d7870b1.tar.gz
src-d9c0e2e16660ecbe33e780821e95508a1d7870b1.zip
Revert "Build clang and other llvm executables as PIE"
This reverts commit 470f9f13de10e47e6d45721c15af6b4abe7aad55. I need more time to figure out how to make this work correctly with incremental builds, which it currently miserably fails on.
-rw-r--r--lib/clang/Makefile.inc6
-rw-r--r--usr.bin/clang/Makefile.inc2
2 files changed, 3 insertions, 5 deletions
diff --git a/lib/clang/Makefile.inc b/lib/clang/Makefile.inc
index 5a8ead5292c6..2dfc966726b0 100644
--- a/lib/clang/Makefile.inc
+++ b/lib/clang/Makefile.inc
@@ -2,11 +2,7 @@
.include <bsd.compiler.mk>
PACKAGE= clang
-
-# Build only PIE static libraries; bsd.lib.mk does support this directly.
-MK_PIE:= no
-CFLAGS+= ${PIEFLAG} ${SHARED_CFLAGS}
-CXXFLAGS+= ${PIEFLAG} ${SHARED_CXXFLAGS}
+MK_PIE:= no # Explicit libXXX.a references
.if ${COMPILER_TYPE} == "clang"
DEBUG_FILES_CFLAGS= -gline-tables-only
diff --git a/usr.bin/clang/Makefile.inc b/usr.bin/clang/Makefile.inc
index 8f812e24fcdb..831cd56a8c25 100644
--- a/usr.bin/clang/Makefile.inc
+++ b/usr.bin/clang/Makefile.inc
@@ -3,6 +3,8 @@ WARNS?= 0
.include <bsd.compiler.mk>
+MK_PIE:= no # Explicit libXXX.a references
+
.if ${COMPILER_TYPE} == "clang"
DEBUG_FILES_CFLAGS= -gline-tables-only
.else