Index | Thread | Search

From:
Landry Breuil <landry@openbsd.org>
Subject:
fix spidermonkey128 on arm64/btcfi
To:
ajacoutot@openbsd.org
Cc:
ports@openbsd.org
Date:
Fri, 20 Jun 2025 06:44:28 +0200

Download raw body.

Thread
hi,

while chasing other dragons on arm64, i realized that js128 was busted
on arm64/btcfi, crashes with SIGILL and ktrace points at btcfi.
the inline diff below fixes it, ok ?

Landry

RCS file: /cvs/ports/devel/spidermonkey128/Makefile,v
diff -u -r1.16 Makefile
--- Makefile    29 May 2025 08:38:37 -0000      1.16
+++ Makefile    20 Jun 2025 04:41:32 -0000
@@ -1,5 +1,6 @@
 # see patch-js_src_old-configure_in (appends to LDFLAGS/DSO_LDOPTS)
 USE_WXNEEDED =         Yes
+USE_NOBTCFI-aarch64 =  Yes
 
 ONLY_FOR_ARCHS =       ${RUST_ARCHS}
 
@@ -13,6 +14,7 @@
 SUBST_VARS +=          SO_VERSION
 
 V =                    ${MOZILLA_VERSION}.11.0
+REVISION =             0
 DISTNAME =             firefox-${V}esr.source
 PKGNAME-main =         spidermonkey${MOZILLA_VERSION}-${V}
 PKGNAME-js =           js${MOZILLA_VERSION}-${V}
@@ -90,6 +92,9 @@
 # Autoconf requires GNU m4 1.1 or later
 CONFIGURE_ENV +=       M4=/usr/local/bin/gm4
 BUILD_DEPENDS +=       devel/m4
+
+# use the ld wrapper for nobtcfi wxneeded etc
+CONFIGURE_ENV +=       LDFLAGS="--ld-path=${WRKDIR}/bin/ld"
 
 MAKE_ENV =             SHELL=/bin/sh \
                        SO_VERSION=${SO_VERSION}