Re: Please revert commit a2bd861

From: Jan Beich <>
Date: Tue, 30 Nov 2021 01:10:12 UTC
Robert Clausecker <> writes:

> Commit a2bd861 (most recent commit on 2021Q4) breaks the ports build:
> [00:10:17] Warning: (www/firefox): Error: www/firefox depends on
> nonexistent origin 'devel/wasi-compiler-rt12'; Please contact
> maintainer of the port to fix this.
> [00:11:44] Error: Fatal errors encountered gathering initial ports metadata

Mk/ sets LLVM_DEFAULT=13 but respects user wishes from
DEFAULT_VERSIONS in make.conf(5) unless LTO option is enabled.
Unfortunately, while wasi-compiler-rt13 and wasi-compiler-rt11
do exist wasi-compiler-rt12 doesn't. Mixing LLVM subprojects from
different major versions are unlikely to be supported.

In short, the package cluster isn't affected due to using defaults.

> Please revert this commit so ports can be built.

Can you try the following instead?

diff --git a/Mk/ b/Mk/
index b912e1aa7ade..efaa641294ca 100644
--- a/Mk/
+++ b/Mk/
@@ -93,7 +93,9 @@ MOZ_OPTIONS+=	--with-libclang-path="${LOCALBASE}/llvm${LLVM_DEFAULT}/lib"
 # Ignore Mk/ but respect make.conf(5) unless LTO is enabled
+# wasi-compiler-rt* is currently limited to llvm11 and llvm13
+.if !defined(DEFAULT_VERSIONS) || ! ${DEFAULT_VERSIONS:Mllvm*} || ${PORT_OPTIONS:MLTO} || \
+	${DEFAULT_VERSIONS:Mllvm=1[02]} || ${DEFAULT_VERSIONS:Mllvm=[7-9]0}
 LLVM_DEFAULT=	13 # chase bundled LLVM in lang/rust for LTO
 # Require newer Clang than what's in base system unless user opted out