aboutsummaryrefslogtreecommitdiff
path: root/Mk
diff options
context:
space:
mode:
authorJan Beich <jbeich@FreeBSD.org>2018-10-01 21:37:14 +0000
committerJan Beich <jbeich@FreeBSD.org>2018-10-01 21:37:14 +0000
commitc1e54e8dcdcf0bba86e35846f52180fae010345e (patch)
tree2b0ed720a8e8a072b3c53f412558787d03159abc /Mk
parent4d5d1f463e8b8d076022b760b9a8f4183630973f (diff)
downloadports-c1e54e8dcdcf0bba86e35846f52180fae010345e.tar.gz
ports-c1e54e8dcdcf0bba86e35846f52180fae010345e.zip
gecko: switch to clang70
Standardizing on one Clang version makes stability more predictable across supported FreeBSD versions. As a side effect performance may suffer some improvement. This also makes it easier to enable LTO as old LLD versions are more buggy.
Notes
Notes: svn path=/head/; revision=481071
Diffstat (limited to 'Mk')
-rw-r--r--Mk/bsd.gecko.mk8
1 files changed, 8 insertions, 0 deletions
diff --git a/Mk/bsd.gecko.mk b/Mk/bsd.gecko.mk
index 944da59cddfb..f68e54694e30 100644
--- a/Mk/bsd.gecko.mk
+++ b/Mk/bsd.gecko.mk
@@ -105,6 +105,14 @@ USE_XORG+= xcb
LLVM_DEFAULT?= 70
BUILD_DEPENDS+= llvm${LLVM_DEFAULT}>0:devel/llvm${LLVM_DEFAULT}
MOZ_EXPORT+= LLVM_CONFIG=llvm-config${LLVM_DEFAULT}
+# Require newer Clang than what's in base system unless user opted out
+. if ${CC} == cc && ${CXX} == c++ && exists(/usr/lib/libc++.so)
+BUILD_DEPENDS+= ${LOCALBASE}/bin/clang${LLVM_DEFAULT}:devel/llvm${LLVM_DEFAULT}
+CPP= ${LOCALBASE}/bin/clang-cpp${LLVM_DEFAULT}
+CC= ${LOCALBASE}/bin/clang${LLVM_DEFAULT}
+CXX= ${LOCALBASE}/bin/clang++${LLVM_DEFAULT}
+USES:= ${USES:Ncompiler\:*} # XXX avoid warnings
+. endif
.endif
.if ${MOZILLA_VER:R:R} >= 61