summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorBryan Drewery <bdrewery@FreeBSD.org>2018-06-20 16:10:14 +0000
committerBryan Drewery <bdrewery@FreeBSD.org>2018-06-20 16:10:14 +0000
commita7d84af8903353c75350105366bed5c80182a66f (patch)
tree3e165d3bc4b30ad91db8f320e3d54eefe1c6c691 /Makefile
parenta883ed8c1da61eacb305818a4029623699f01534 (diff)
downloadsrc-test2-a7d84af8903353c75350105366bed5c80182a66f.tar.gz
src-test2-a7d84af8903353c75350105366bed5c80182a66f.zip
Add WITH_SYSTEM_LINKER, on by default, that avoids building lld when possible.
This works similar to WITH_SYSTEM_COMPILER added in r300354. It only supports lld via WITH_LLD_BOOTSTRAP. When both SYSTEM_COMPILER and SYSTEM_LINKER logic passes then libclang will not build in cross-tools. If either check fails though then libclang is built. The .info is reworked to notify when libclang will be built since if either clang or lld needs to be rebuilt, but not the other, the notification can lead to confusion on why "clang is building". -fuse-ld= is not used with this method so some combinations of compiler and linker are expected to fail. A new 'make test-system-linker' target is added to see the logic results. Makefile.inc1: CROSS_BINUTILS_PREFIX support had to be moved higher up so that XLD could be set and MK_LLD_BOOTSTRAP disabled before checking SYSTEM_LINKER logic as done with SYSTEM_COMPILER. This also required moving where bsd.linker.mk was read since XLD needs to be set before parsing it. This creates a situation where src.opts.mk can not test LINKER_FEATURES or add LLD_BOOTSTAP to BROKEN_OPTIONS. Reviewed by: emaste (earlier version) Sponsored by: Dell EMC Differential Revision: https://reviews.freebsd.org/D15894
Notes
Notes: svn path=/head/; revision=335450
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile4
1 files changed, 2 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 2a1ebc9d81f2..4113aeb0e71e 100644
--- a/Makefile
+++ b/Makefile
@@ -143,7 +143,7 @@ TGTS= all all-man buildenv buildenvvars buildkernel buildworld \
stage-packages \
create-packages-world create-packages-kernel create-packages \
packages installconfig real-packages sign-packages package-pkg \
- print-dir test-system-compiler
+ print-dir test-system-compiler test-system-linker
# These targets require a TARGET and TARGET_ARCH be defined.
XTGTS= native-xtools native-xtools-install xdev xdev-build xdev-install \
@@ -168,7 +168,7 @@ META_TGT_WHITELIST+= \
_* build32 buildfiles buildincludes buildkernel buildsoft \
buildworld everything kernel-toolchain kernel-toolchains kernel \
kernels libraries native-xtools showconfig test-system-compiler \
- tinderbox toolchain \
+ test-system-linker tinderbox toolchain \
toolchains universe world worlds xdev xdev-build
.ORDER: buildworld installworld