pkgsrc-Changes archive

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

CVS commit: pkgsrc/lang/mozjs78



Module Name:    pkgsrc
Committed By:   gutteridge
Date:           Mon Jun 14 22:07:36 UTC 2021

Modified Files:
        pkgsrc/lang/mozjs78: Makefile

Log Message:
mozjs78: fix NetBSD i386 builds with Rust >= 1.50

The NetBSD i386 Rust 1.50 builds introduced two different targets (i586
and i686), where previously there was only one (i686). Unfortunately,
the upstream mozjs78 configuration script that narrows to the
appropriate compiler target is confused by this, since it was receiving
"i486" from pkgsrc tooling and didn't know how to pick from more than
one potential approximate match. I'm addressing it this (kludgy) way
for now, as I don't have time to go through Mozilla's scripting and
make adjustments, and I would like this building in the 2021Q2 branch.
If someone else feels there's a better way, please have at it. With
this tweak in place, I'm able to build the xfce4 meta package for
NetBSD/i386 9.2.


To generate a diff of this commit:
cvs rdiff -u -r1.20 -r1.21 pkgsrc/lang/mozjs78/Makefile

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

Modified files:

Index: pkgsrc/lang/mozjs78/Makefile
diff -u pkgsrc/lang/mozjs78/Makefile:1.20 pkgsrc/lang/mozjs78/Makefile:1.21
--- pkgsrc/lang/mozjs78/Makefile:1.20   Mon May 24 19:52:34 2021
+++ pkgsrc/lang/mozjs78/Makefile        Mon Jun 14 22:07:35 2021
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.20 2021/05/24 19:52:34 wiz Exp $
+# $NetBSD: Makefile,v 1.21 2021/06/14 22:07:35 gutteridge Exp $
 
 DISTNAME=      mozjs78_78.4.0.orig
 PKGNAME=       ${DISTNAME:S/_/-/:S/.orig//}
@@ -34,9 +34,20 @@ CONFIGURE_ARGS+=     --disable-debug-symbols
 CONFIGURE_ARGS+=       --enable-strip
 CONFIGURE_ARGS+=       --with-intl-api
 # --disable-optimize
+
 # For rustc/cargo detection
+.include "../../mk/bsd.prefs.mk"
+
+# This is to work around build failures where an upstream configuration script
+# is confused by having more than one approximate match to MACHINE_GNU_PLATFORM
+# "i486" when attempting to select the Rust compiler target.
+.if !empty(MACHINE_PLATFORM:MNetBSD-*-i386)
+CONFIGURE_ARGS+=       --target=i586-unknown-netbsd
+CONFIGURE_ARGS+=       --host=i586-unknown-netbsd
+.else
 CONFIGURE_ARGS+=       --target=${MACHINE_GNU_PLATFORM}
 CONFIGURE_ARGS+=       --host=${MACHINE_GNU_PLATFORM}
+.endif
 
 BUILDLINK_TRANSFORM.SunOS+=    rm:-pie
 



Home | Main Index | Thread Index | Old Index