pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

rust194: for NetBSD/aarch64* bump PTHREAD_KEYS_MAX to 512.



Module Name:	pkgsrc-wip
Committed By:	Havard Eidnes <he%NetBSD.org@localhost>
Pushed By:	he
Date:		Sun Mar 8 14:06:27 2026 +0100
Changeset:	74186e7caf87019f6fc09c51702c8532ccac6a7e

Modified Files:
	rust194/options.mk

Log Message:
rust194: for NetBSD/aarch64* bump PTHREAD_KEYS_MAX to 512.

Otherwise the build bumps into

fatal runtime error: out of TLS keys, aborting
rustc exited with signal: 6 (SIGABRT) (core dumped)
error: could not compile `tinystr` (lib)

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=74186e7caf87019f6fc09c51702c8532ccac6a7e

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 rust194/options.mk | 8 ++++++++
 1 file changed, 8 insertions(+)

diffs:
diff --git a/rust194/options.mk b/rust194/options.mk
index 879f1b0559..2afe0cb9ee 100644
--- a/rust194/options.mk
+++ b/rust194/options.mk
@@ -83,6 +83,14 @@ CONFIGURE_ARGS+=	--llvm-root=${BUILDLINK_PREFIX.llvm}
 CONFIGURE_ARGS+=	--set rust.lld=false
 .endif
 
+# Rust bumps into NetBSD's limit of 256 TLS keys per process, at least
+# on aarch64 with "fatal runtime error: out of TLS keys, aborting"
+# (for some incomprehensible reason this isn't triggered on NetBSD/amd64 10.1)
+.if !empty(MACHINE_PLATFORM:MNetBSD-*-aarch64*)
+# So try to bump that per-process limit:
+MAKE_ENV+=		PTHREAD_KEYS_MAX=512
+.endif
+
 #
 # Link cargo statically against "native" libraries.
 # (openssl and curl specifically).


Home | Main Index | Thread Index | Old Index