aboutsummaryrefslogtreecommitdiff
path: root/emulators
diff options
context:
space:
mode:
authorGuido Falsi <madpilot@FreeBSD.org>2022-02-09 14:20:54 +0000
committerGuido Falsi <madpilot@FreeBSD.org>2022-02-09 14:33:41 +0000
commit66392cf640932b50db9ea4d5ebcabb28999e65e4 (patch)
tree6d5ef205c4b1c619ecf8866967c98d95eca04120 /emulators
parent2c53103cfe86034d4f3da866bd829188c4fc6114 (diff)
downloadports-66392cf640932b50db9ea4d5ebcabb28999e65e4.tar.gz
ports-66392cf640932b50db9ea4d5ebcabb28999e65e4.zip
emulators/virtualbox-ose-legacy: Fix build on head
The legacy version of virtualbox fails to build on head with clang > 11, so force using clang 11 there. PR: 254616 (suggested in) (cherry picked from commit 39f7031c79eb0da62240461fe830b9df08545f55)
Diffstat (limited to 'emulators')
-rw-r--r--emulators/virtualbox-ose-legacy/Makefile10
1 files changed, 10 insertions, 0 deletions
diff --git a/emulators/virtualbox-ose-legacy/Makefile b/emulators/virtualbox-ose-legacy/Makefile
index 7d0e5812f01a..9276da479d50 100644
--- a/emulators/virtualbox-ose-legacy/Makefile
+++ b/emulators/virtualbox-ose-legacy/Makefile
@@ -206,6 +206,16 @@ KMK_FLAGS+= -j${MAKE_JOBS_NUMBER}
.include <bsd.port.pre.mk>
+.if ${CHOSEN_COMPILER_TYPE} == clang && ${OPSYS} == FreeBSD && ${OSVERSION} > 1400022
+# clang > 11 included in FreeBSD 14 fails to compile this legacy version
+# of virtualbox-ose, force clang 11 on FreeBSD 14 where a newer clang is
+# included.
+BUILD_DEPENDS+= clang${VBOX_LLVM_VER}:devel/llvm${VBOX_LLVM_VER}
+CC= clang${VBOX_LLVM_VER}
+CXX= clang++${VBOX_LLVM_VER}
+VBOX_LLVM_VER?= 11
+.endif
+
.if ${PYTHON_MAJOR_VER} >= 3
PLIST_SUB+= PYTHON_PYCDIR=/__pycache__/ \
PYTHON_PYCEXT=.cpython-${PYTHON_SUFFIX}.pyc