summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2024-08-11 19:48:27 +0000
committerDimitry Andric <dim@FreeBSD.org>2024-08-15 07:42:36 +0000
commite664cd1dc5fb66d0802db84f469a5c500dd3688a (patch)
treefc20a5dc83ecd2c7b1e90b0f37abe0afc75914ce
parent7088bf662d46ef321a5838d290285086cd6446d2 (diff)
-rw-r--r--stand/efi/loader/Makefile5
1 files changed, 5 insertions, 0 deletions
diff --git a/stand/efi/loader/Makefile b/stand/efi/loader/Makefile
index ec2a147bd69f..c5503da655f9 100644
--- a/stand/efi/loader/Makefile
+++ b/stand/efi/loader/Makefile
@@ -105,6 +105,11 @@ LDFLAGS+= -Wl,-T${LDSCRIPT},-Bsymbolic,-znotext -pie
LDFLAGS+= -Wl,--no-dynamic-linker
.endif
+# When lld is using multiple threads, which it does by default, it can
+# result in non-reproducible output with the custom linker script. Work
+# around this by disabling threading.
+LDFLAGS.lld+= -Wl,--threads=1
+
CLEANFILES+= ${LOADER}.efi
${LOADER}.efi: ${PROG}