public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: dev-libs/nspr/, dev-libs/nspr/files/
@ 2016-09-28 10:09 Lars Wendler
  0 siblings, 0 replies; 5+ messages in thread
From: Lars Wendler @ 2016-09-28 10:09 UTC (permalink / raw
  To: gentoo-commits

commit:     0625099413811021f37a1cbeabee2183c3a22d58
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Wed Sep 28 10:09:18 2016 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Wed Sep 28 10:09:37 2016 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=06250994

dev-libs/nspr: Bump to version 4.13

Package-Manager: portage-2.3.1
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>

 dev-libs/nspr/Manifest                             |   1 +
 dev-libs/nspr/files/nspr-4.10.6-solaris.patch      |   4 +-
 dev-libs/nspr/files/nspr-4.7.0-prtime.patch        |   4 +-
 dev-libs/nspr/files/nspr-4.7.1-solaris.patch       |   4 +-
 .../files/nspr-4.8.4-darwin-install_name.patch     |   8 +-
 dev-libs/nspr/files/nspr-4.8.9-link-flags.patch    |   8 +-
 dev-libs/nspr/files/nspr-4.9.5_nspr_config.patch   |   5 +-
 dev-libs/nspr/nspr-4.13.ebuild                     | 125 +++++++++++++++++++++
 8 files changed, 142 insertions(+), 17 deletions(-)

diff --git a/dev-libs/nspr/Manifest b/dev-libs/nspr/Manifest
index 5a07789..f17b8ae 100644
--- a/dev-libs/nspr/Manifest
+++ b/dev-libs/nspr/Manifest
@@ -2,3 +2,4 @@ DIST nspr-4.10.10.tar.gz 1134164 SHA256 343614971c30520d0fa55f4af0a72578e2d8674b
 DIST nspr-4.10.8.tar.gz 1131130 SHA256 507ea57c525c0c524dae4857a642b4ef5c9d795518754c7f83422d22fe544a15 SHA512 f14e3bd46cd1dee9d7163adbf3b09a450ea8c6c65499c5b6696eba7e85b6b12d3f90561a1dfe0dc0dc5fe1b14758b4191e546d9f0e29a66f33c69dd6ed6f50d9 WHIRLPOOL 67be897d54e2446d563cfe505047b23880025bd3f1ea5492964f8d286f56776e41a8e63bd9d197d3115efae0d63bd0c7005fb9fc56abdfce0702c27e6a9e872c
 DIST nspr-4.11.tar.gz 1134106 SHA256 cb320a9eee7028275ac0fce7adc39dee36f14f02fd8432fce1b7e1aa5e3685c2 SHA512 26c47ba618f5a7748cacc5152348b6fd37bdcc82806bbff485ed4d485aecad13d202270a837c735670030e96380ec3177f3bc8a47e0dca359cfb097a84242c02 WHIRLPOOL f8707154d1981a09140d31d359d5a40867eaad447620a4731a11c770cae13b8e9a64ef45c82123083e37e2effedfb0c367cc57969a3baf65628ff1e9ccf41517
 DIST nspr-4.12.tar.gz 1135458 SHA256 e0b10a1e569153668ff8bdea6c7e491b389fab69c2f18285a1ebf7c2ea4269de SHA512 138072be98dea6e97ea38f3e562c8ee383626c2136ec1adb854a81315468cd484c4b994c3ccaf6a39327b3fe121f77d698bf85c2764ec4b6231828b8a9ec5460 WHIRLPOOL d85d74e6287ed9578bc565c5e699f7201fbf38cb55e6dfa487f1c8b4684c161b6c6a5c8cb06627575d7a417bf35b15c64d231878dab32b5bbcc8223b7356c32d
+DIST nspr-4.13.tar.gz 1136571 SHA256 19c33334bb3fa6d24800ffa65d7d806c54ad5f8c3758a5c11352ad43212ab181 SHA512 6af8671aa32d2dd08e900f235950c200e27c7052be2456651cbd8d508f376f60bdbdaa2ac984397027706618e0c794749c9dbf09c1972d9ba5280dadec37a562 WHIRLPOOL 5b93db16eb4bf1e8ee3e39b2df7f880cf42d80583a8b191395d5602090120eab83881eb2459869ff12de070cbd4be969f97d94445b40ac56ae810682008b16e3

diff --git a/dev-libs/nspr/files/nspr-4.10.6-solaris.patch b/dev-libs/nspr/files/nspr-4.10.6-solaris.patch
index 3ae8052..6ae04f4 100644
--- a/dev-libs/nspr/files/nspr-4.10.6-solaris.patch
+++ b/dev-libs/nspr/files/nspr-4.10.6-solaris.patch
@@ -1,7 +1,7 @@
 * drop Solaris linker stuff
 
---- nspr-4.7.4/mozilla/nsprpub/configure.in
-+++ nspr-4.7.4/mozilla/nsprpub/configure.in
+--- a/configure.in
++++ b/configure.in
 @@ -1988,26 +1988,14 @@
      CPU_ARCH=`uname -p`
      MDCPUCFG_H=_solaris.cfg

diff --git a/dev-libs/nspr/files/nspr-4.7.0-prtime.patch b/dev-libs/nspr/files/nspr-4.7.0-prtime.patch
index ac509ef..2de3ba3 100644
--- a/dev-libs/nspr/files/nspr-4.7.0-prtime.patch
+++ b/dev-libs/nspr/files/nspr-4.7.0-prtime.patch
@@ -1,5 +1,5 @@
---- mozilla/nsprpub/pr/src/misc/prtime.c.orig	2007-09-14 19:41:08.000000000 +0200
-+++ mozilla/nsprpub/pr/src/misc/prtime.c	2007-09-14 19:42:17.000000000 +0200
+--- a/pr/src/misc/prtime.c
++++ b/pr/src/misc/prtime.c
 @@ -1536,7 +1536,7 @@
                  case TT_EET: zone_offset =  2 * 60; break;
                  case TT_JST: zone_offset =  9 * 60; break;

diff --git a/dev-libs/nspr/files/nspr-4.7.1-solaris.patch b/dev-libs/nspr/files/nspr-4.7.1-solaris.patch
index 5d9e810..1afab1d 100644
--- a/dev-libs/nspr/files/nspr-4.7.1-solaris.patch
+++ b/dev-libs/nspr/files/nspr-4.7.1-solaris.patch
@@ -1,8 +1,8 @@
 Same magic as haubi did for glib compilation, which works again here
 resolving a linker problem on Solaris with GNU ld.  Bug #222625
 
---- mozilla/nsprpub/pr/src/Makefile.in.orig	2008-06-22 22:24:56.671065000 +0200
-+++ mozilla/nsprpub/pr/src/Makefile.in	2008-06-23 14:38:52.320417000 +0200
+--- a/pr/src/Makefile.in
++++ b/pr/src/Makefile.in
 @@ -95,7 +95,7 @@
  endif
  

diff --git a/dev-libs/nspr/files/nspr-4.8.4-darwin-install_name.patch b/dev-libs/nspr/files/nspr-4.8.4-darwin-install_name.patch
index 1258b60..4045e90 100644
--- a/dev-libs/nspr/files/nspr-4.8.4-darwin-install_name.patch
+++ b/dev-libs/nspr/files/nspr-4.8.4-darwin-install_name.patch
@@ -1,8 +1,8 @@
 Don't use @executable_path, it messed up linking against nspr from e.g.
 nss.
 
---- mozilla/nsprpub/configure.in
-+++ mozilla/nsprpub/configure.in
+--- a/configure.in
++++ b/configure.in
 @@ -1007,7 +1007,7 @@
              ;;
      esac
@@ -12,8 +12,8 @@ nss.
      _OPTIMIZE_FLAGS=-O2
      MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@'
      STRIP="$STRIP -x -S"
---- mozilla/nsprpub/configure
-+++ mozilla/nsprpub/configure
+--- a/configure
++++ b/configure
 @@ -1007,7 +1007,7 @@
              ;;
      esac

diff --git a/dev-libs/nspr/files/nspr-4.8.9-link-flags.patch b/dev-libs/nspr/files/nspr-4.8.9-link-flags.patch
index dd3b132..5d37018 100644
--- a/dev-libs/nspr/files/nspr-4.8.9-link-flags.patch
+++ b/dev-libs/nspr/files/nspr-4.8.9-link-flags.patch
@@ -5,8 +5,8 @@ autoparallelization).  Other flags are required when building and linking
 
 https://bugs.gentoo.org/365975
 
---- a/mozilla/nsprpub/config/autoconf.mk.in
-+++ b/mozilla/nsprpub/config/autoconf.mk.in
+--- a/config/autoconf.mk.in
++++ b/config/autoconf.mk.in
 @@ -81,6 +81,7 @@ OS_DLLFLAGS	= @OS_DLLFLAGS@
  DLLFLAGS	= @DLLFLAGS@
  EXEFLAGS  = @EXEFLAGS@
@@ -15,8 +15,8 @@ https://bugs.gentoo.org/365975
  
  PROFILE_GEN_CFLAGS  = @PROFILE_GEN_CFLAGS@
  PROFILE_GEN_LDFLAGS = @PROFILE_GEN_LDFLAGS@
---- a/mozilla/nsprpub/config/config.mk
-+++ b/mozilla/nsprpub/config/config.mk
+--- a/config/config.mk
++++ b/config/config.mk
 @@ -72,7 +72,7 @@ NOMD_CFLAGS	= $(CC_ONLY_FLAGS) $(OPTIMIZER) $(NOMD_OS_CFLAGS)\
  NOMD_CCFLAGS	= $(CCC_ONLY_FLAGS) $(OPTIMIZER) $(NOMD_OS_CFLAGS)\
  		  $(XP_DEFINE) $(DEFINES) $(INCLUDES) $(XCFLAGS)

diff --git a/dev-libs/nspr/files/nspr-4.9.5_nspr_config.patch b/dev-libs/nspr/files/nspr-4.9.5_nspr_config.patch
index d4f9a7e..a22b0b9 100644
--- a/dev-libs/nspr/files/nspr-4.9.5_nspr_config.patch
+++ b/dev-libs/nspr/files/nspr-4.9.5_nspr_config.patch
@@ -1,6 +1,5 @@
-diff -urN a/mozilla/nsprpub/config/nspr-config.in b/mozilla/nsprpub/config/nspr-config.in
---- a/mozilla/nsprpub/config/nspr-config.in	2012-03-06 07:13:39.000000000 -0600
-+++ b/mozilla/nsprpub/config/nspr-config.in	2013-02-16 20:53:53.893489345 -0600
+--- a/config/nspr-config.in
++++ b/config/nspr-config.in
 @@ -126,7 +126,7 @@
  fi
  

diff --git a/dev-libs/nspr/nspr-4.13.ebuild b/dev-libs/nspr/nspr-4.13.ebuild
new file mode 100644
index 00000000..cc2f965
--- /dev/null
+++ b/dev-libs/nspr/nspr-4.13.ebuild
@@ -0,0 +1,125 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+WANT_AUTOCONF="2.5"
+
+inherit autotools eutils multilib toolchain-funcs versionator multilib-minimal
+
+MIN_PV="$(get_version_component_range 2)"
+
+DESCRIPTION="Netscape Portable Runtime"
+HOMEPAGE="http://www.mozilla.org/projects/nspr/"
+SRC_URI="https://archive.mozilla.org/pub/nspr/releases/v${PV}/src/${P}.tar.gz"
+
+LICENSE="|| ( MPL-2.0 GPL-2 LGPL-2.1 )"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
+IUSE="debug"
+
+RDEPEND="
+	abi_x86_32? (
+		!<=app-emulation/emul-linux-x86-baselibs-20140508-r12
+		!app-emulation/emul-linux-x86-baselibs[-abi_x86_32(-)]
+	)"
+
+MULTILIB_CHOST_TOOLS=(
+	/usr/bin/nspr-config
+)
+
+PATCHES=(
+	"${FILESDIR}"/${PN}-4.7.0-prtime.patch
+	"${FILESDIR}"/${PN}-4.7.1-solaris.patch
+	"${FILESDIR}"/${PN}-4.10.6-solaris.patch
+	"${FILESDIR}"/${PN}-4.8.4-darwin-install_name.patch
+	"${FILESDIR}"/${PN}-4.8.9-link-flags.patch
+	# We do not need to pass -L$libdir via nspr-config --libs
+	"${FILESDIR}"/${PN}-4.9.5_nspr_config.patch
+)
+
+src_prepare() {
+	cd "${S}"/nspr || die
+
+	default
+
+	# rename configure.in to configure.ac for new autotools compatibility
+	if [[ -e "${S}"/nspr/configure.in ]] ; then
+		einfo "Renaming configure.in to configure.ac"
+		mv "${S}"/nspr/configure.{in,ac} || die
+	fi
+	# We must run eautoconf to regenerate configure
+	eautoconf
+
+	# make sure it won't find Perl out of Prefix
+	sed -i -e "s/perl5//g" "${S}"/nspr/configure || die
+
+	# Respect LDFLAGS
+	sed -i -e 's/\$(MKSHLIB) \$(OBJS)/\$(MKSHLIB) \$(LDFLAGS) \$(OBJS)/g' \
+		"${S}"/nspr/config/rules.mk || die
+}
+
+multilib_src_configure() {
+	# We use the standard BUILD_xxx but nspr uses HOST_xxx
+	tc-export_build_env BUILD_CC
+	export HOST_CC=${BUILD_CC} HOST_CFLAGS=${BUILD_CFLAGS} HOST_LDFLAGS=${BUILD_LDFLAGS}
+	tc-export AR CC CXX RANLIB
+	[[ ${CBUILD} != ${CHOST} ]] \
+		&& export CROSS_COMPILE=1 \
+		|| unset CROSS_COMPILE
+
+	local myconf=()
+
+	# The configure has some fancy --enable-{{n,x}32,64bit} switches
+	# that trigger some code conditional to platform & arch. This really
+	# matters for the few common arches (x86, ppc) but we pass a little
+	# more of them to be future-proof.
+
+	# use ABI first, this will work for most cases
+	case "${ABI}" in
+		alpha|arm|hppa|m68k|o32|ppc|s390|sh|sparc|x86) ;;
+		n32) myconf+=( --enable-n32 );;
+		x32) myconf+=( --enable-x32 );;
+		s390x|*64) myconf+=( --enable-64bit );;
+		default) # no abi actually set, fall back to old check
+			einfo "Running a short build test to determine 64bit'ness"
+			echo > "${T}"/test.c || die
+			${CC} ${CFLAGS} ${CPPFLAGS} -c "${T}"/test.c -o "${T}"/test.o || die
+			case $(file "${T}"/test.o) in
+				*32-bit*x86-64*) myconf+=( --enable-x32 );;
+				*64-bit*|*ppc64*|*x86_64*) myconf+=( --enable-64bit );;
+				*32-bit*|*ppc*|*i386*) ;;
+				*) die "Failed to detect whether your arch is 64bits or 32bits, disable distcc if you're using it, please";;
+			esac ;;
+		*) ;;
+	esac
+
+	# Ancient autoconf needs help finding the right tools.
+	LC_ALL="C" ECONF_SOURCE="${S}/nspr" \
+	ac_cv_path_AR="${AR}" \
+	econf \
+		--libdir="${EPREFIX}/usr/$(get_libdir)" \
+		$(use_enable debug) \
+		$(use_enable !debug optimize) \
+		"${myconf[@]}"
+}
+
+multilib_src_install() {
+	# Their build system is royally confusing, as usual
+	MINOR_VERSION=${MIN_PV} # Used for .so version
+	emake DESTDIR="${D}" install
+
+	einfo "removing static libraries as upstream has requested!"
+	rm -f "${ED}"/usr/$(get_libdir)/*.a || die "failed to remove static libraries."
+
+	# install nspr-config
+	dobin config/nspr-config
+
+	# Remove stupid files in /usr/bin
+	rm "${ED}"/usr/bin/prerr.properties || die
+
+	# This is used only to generate prerr.c and prerr.h at build time.
+	# No other projects use it, and we don't want to depend on perl.
+	# Talked to upstream and they agreed w/punting.
+	rm "${ED}"/usr/bin/compile-et.pl || die
+}


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-libs/nspr/, dev-libs/nspr/files/
@ 2019-03-20 19:12 Jory Pratt
  0 siblings, 0 replies; 5+ messages in thread
From: Jory Pratt @ 2019-03-20 19:12 UTC (permalink / raw
  To: gentoo-commits

commit:     b775a0d6d3e67c8dda78ae006fb733944d83f80e
Author:     Jory Pratt <anarchy <AT> gentoo <DOT> org>
AuthorDate: Wed Mar 20 19:06:17 2019 +0000
Commit:     Jory Pratt <anarchy <AT> gentoo <DOT> org>
CommitDate: Wed Mar 20 19:12:38 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b775a0d6

dev-libs/nspr: Add support for ipv6 on musl

Signed-off-by: Jory Pratt <anarchy <AT> gentoo.org>

 .../nspr/files/nspr-4.21-ipv6-musl-support.patch   | 53 ++++++++++++++++++++++
 dev-libs/nspr/nspr-4.21.ebuild                     |  4 +-
 2 files changed, 56 insertions(+), 1 deletion(-)

diff --git a/dev-libs/nspr/files/nspr-4.21-ipv6-musl-support.patch b/dev-libs/nspr/files/nspr-4.21-ipv6-musl-support.patch
new file mode 100644
index 00000000000..2c8ebd4ccbb
--- /dev/null
+++ b/dev-libs/nspr/files/nspr-4.21-ipv6-musl-support.patch
@@ -0,0 +1,53 @@
+From 8c57451f44d7ceb37bfb4ae6e457fc70b1f58d0a Mon Sep 17 00:00:00 2001
+From: Moritz Kick <gentoo@blackphoenix.de>
+Date: Wed, 20 Mar 2019 13:36:06 -0500
+Subject: [PATCH] Added IPv6 compatibility for musl libc
+
+Signed-off-by: Moritz Kick <gentoo@blackphoenix.de>
+Signed-off-by: Jory Pratt <anarchy@gentoo.org>
+---
+ pr/include/md/_linux.h | 13 +------------
+ 1 file changed, 1 insertion(+), 12 deletions(-)
+
+diff --git a/pr/include/md/_linux.h b/pr/include/md/_linux.h
+index 2370ab8..612184c 100644
+--- a/pr/include/md/_linux.h
++++ b/pr/include/md/_linux.h
+@@ -289,33 +289,22 @@ static inline PRInt32 _MD_ATOMIC_SET(PRInt32 *ptr, PRInt32 nv)
+ #endif /* __arm__ */
+ 
+ #define USE_SETJMP
+-#if (defined(__GLIBC__) && __GLIBC__ >= 2) || defined(ANDROID)
+ #define _PR_POLL_AVAILABLE
+-#endif
+ #undef _PR_USE_POLL
+ #define _PR_STAT_HAS_ONLY_ST_ATIME
+ #if defined(__alpha) || defined(__ia64__)
+ #define _PR_HAVE_LARGE_OFF_T
+-#elif (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) \
+-    || defined(ANDROID)
+-#define _PR_HAVE_OFF64_T
+ #else
+-#define _PR_NO_LARGE_FILES
++#define _PR_HAVE_OFF64_T
+ #endif
+-#if (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) \
+-    || defined(ANDROID)
+ #define _PR_INET6
+ #define _PR_HAVE_INET_NTOP
+ #define _PR_HAVE_GETHOSTBYNAME2
+ #define _PR_HAVE_GETADDRINFO
+ #define _PR_INET6_PROBE
+-#endif
+ #ifndef ANDROID
+ #define _PR_HAVE_SYSV_SEMAPHORES
+ #define PR_HAVE_SYSV_NAMED_SHARED_MEMORY
+-#endif
+-/* Android has gethostbyname_r but not gethostbyaddr_r or gethostbyname2_r. */
+-#if (__GLIBC__ >= 2) && defined(_PR_PTHREADS)
+ #define _PR_HAVE_GETHOST_R
+ #define _PR_HAVE_GETHOST_R_INT
+ #endif
+-- 
+2.21.0
+

diff --git a/dev-libs/nspr/nspr-4.21.ebuild b/dev-libs/nspr/nspr-4.21.ebuild
index 809295b31a1..dd4c8f167bb 100644
--- a/dev-libs/nspr/nspr-4.21.ebuild
+++ b/dev-libs/nspr/nspr-4.21.ebuild
@@ -14,7 +14,7 @@ SRC_URI="https://archive.mozilla.org/pub/nspr/releases/v${PV}/src/${P}.tar.gz"
 LICENSE="|| ( MPL-2.0 GPL-2 LGPL-2.1 )"
 SLOT="0"
 KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
-IUSE="debug"
+IUSE="debug elibc_musl"
 
 MULTILIB_CHOST_TOOLS=(
 	/usr/bin/nspr-config
@@ -35,6 +35,8 @@ src_prepare() {
 
 	default
 
+	use elibc_musl && eapply "${FILESDIR}"/${PN}-4.21-ipv6-musl-support.patch
+
 	# rename configure.in to configure.ac for new autotools compatibility
 	if [[ -e "${S}"/nspr/configure.in ]] ; then
 		einfo "Renaming configure.in to configure.ac"


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-libs/nspr/, dev-libs/nspr/files/
@ 2020-03-31 17:50 Thomas Deutschmann
  0 siblings, 0 replies; 5+ messages in thread
From: Thomas Deutschmann @ 2020-03-31 17:50 UTC (permalink / raw
  To: gentoo-commits

commit:     6458568d4caf17cc987048da66c6d7d1bf61b305
Author:     Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
AuthorDate: Tue Mar 31 17:50:25 2020 +0000
Commit:     Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
CommitDate: Tue Mar 31 17:50:39 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6458568d

dev-libs/nspr: drop old

Package-Manager: Portage-2.3.96, Repoman-2.3.22
Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org>

 dev-libs/nspr/Manifest                      |   3 -
 dev-libs/nspr/files/nspr-4.7.0-prtime.patch |  26 ------
 dev-libs/nspr/nspr-4.20.ebuild              | 118 ---------------------------
 dev-libs/nspr/nspr-4.22.ebuild              | 120 ---------------------------
 dev-libs/nspr/nspr-4.24.ebuild              | 122 ----------------------------
 5 files changed, 389 deletions(-)

diff --git a/dev-libs/nspr/Manifest b/dev-libs/nspr/Manifest
index 170622eaf18..131b1010eee 100644
--- a/dev-libs/nspr/Manifest
+++ b/dev-libs/nspr/Manifest
@@ -1,4 +1 @@
-DIST nspr-4.20.tar.gz 1140892 BLAKE2B 2cb96b7a40c307f904dac038f016b5c0e527aaf673463cbcb59d8bb6c9d0239219402587d624f48804e33f43abd4427c87f267bf1a88a0dacffcc408ac15dc49 SHA512 22fdf7627f450b0594ebccaee170098e1a8cd0f429fd44816f1322756002ced3d69cf686c3f69f7cb30b8132d3605a9fce5457ab99d0002e6af11a3408a5c949
-DIST nspr-4.22.tar.gz 1078701 BLAKE2B 8b37031ffebf79320c91ce674d7c3a0cfbef25bfb006cb9aaff44f090110b35ea2768f83dae4a793723f8e2f3aecabc1a4b8042cd1b0ab0aade30781e43f9d62 SHA512 d34271f0692905162f71b02cf6f62a8ebf779159335e4ed286ee8d51faaad633a61c9392bada86d976bca2b5aa47c8760085de30dbd13c9cfa423582c31db37b
-DIST nspr-4.24.tar.gz 1078825 BLAKE2B 3a773768c31334fa4f3f406d838d430dccfbcf5f7bd34dca422b199265f17fc08ef3d5d1e6df5468efeeeace8b5f8a38ece518e6bdbcdf811c2642d43be80c6c SHA512 b020031ed7a8997099c11e0772779c7b10d15b4f6b14e2b1832732943e8b8224afa952ce04a1914c1553af9d3973a6d9cacf08058ee6fff35102e3b2ec0943c1
 DIST nspr-4.25.tar.gz 1079633 BLAKE2B 377e5ec0e60cca13f1ee988adb10870bbb6cb9e4eb61e4434152418d4f8d446741a192d7019298ec2669b8e190cacb6a1ca9c4b2838e9b14dd3590ed40facdd2 SHA512 b9aa576e0da37e8729088fe559d94030cf18f277c1f7a30104d3088a804913343ed884645c0adb62144da475e20934b359f897bf3ae9a6ebb5f9daf283d5a562

diff --git a/dev-libs/nspr/files/nspr-4.7.0-prtime.patch b/dev-libs/nspr/files/nspr-4.7.0-prtime.patch
deleted file mode 100644
index 2de3ba34457..00000000000
--- a/dev-libs/nspr/files/nspr-4.7.0-prtime.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- a/pr/src/misc/prtime.c
-+++ b/pr/src/misc/prtime.c
-@@ -1536,7 +1536,7 @@
-                 case TT_EET: zone_offset =  2 * 60; break;
-                 case TT_JST: zone_offset =  9 * 60; break;
-                 default:
--                  PR_ASSERT (0);
-+                  return PR_FAILURE;
-                   break;
-                 }
-         }
-@@ -1578,11 +1578,12 @@
-           struct tm localTime;
-           time_t secs;
- 
--          PR_ASSERT(result->tm_month > -1 &&
-+          if (!(result->tm_month > -1 &&
-                     result->tm_mday > 0 &&
-                     result->tm_hour > -1 &&
-                     result->tm_min > -1 &&
--                    result->tm_sec > -1);
-+                    result->tm_sec > -1))
-+		    return PR_FAILURE;
- 
-             /*
-              * To obtain time_t from a tm structure representing the local

diff --git a/dev-libs/nspr/nspr-4.20.ebuild b/dev-libs/nspr/nspr-4.20.ebuild
deleted file mode 100644
index 7acc7bcb527..00000000000
--- a/dev-libs/nspr/nspr-4.20.ebuild
+++ /dev/null
@@ -1,118 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools toolchain-funcs multilib-minimal
-
-MIN_PV="$(ver_cut 2)"
-
-DESCRIPTION="Netscape Portable Runtime"
-HOMEPAGE="http://www.mozilla.org/projects/nspr/"
-SRC_URI="https://archive.mozilla.org/pub/nspr/releases/v${PV}/src/${P}.tar.gz"
-
-LICENSE="|| ( MPL-2.0 GPL-2 LGPL-2.1 )"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 hppa ia64 ~m68k ~mips ppc ppc64 s390 sparc x86 ~ppc-aix ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
-IUSE="debug"
-
-MULTILIB_CHOST_TOOLS=(
-	/usr/bin/nspr-config
-)
-
-PATCHES=(
-	"${FILESDIR}"/${PN}-4.7.0-prtime.patch
-	"${FILESDIR}"/${PN}-4.7.1-solaris.patch
-	"${FILESDIR}"/${PN}-4.10.6-solaris.patch
-	"${FILESDIR}"/${PN}-4.8.4-darwin-install_name.patch
-	"${FILESDIR}"/${PN}-4.8.9-link-flags.patch
-	# We do not need to pass -L$libdir via nspr-config --libs
-	"${FILESDIR}"/${PN}-4.9.5_nspr_config.patch
-)
-
-src_prepare() {
-	cd "${S}"/nspr || die
-
-	default
-
-	# rename configure.in to configure.ac for new autotools compatibility
-	if [[ -e "${S}"/nspr/configure.in ]] ; then
-		einfo "Renaming configure.in to configure.ac"
-		mv "${S}"/nspr/configure.{in,ac} || die
-	fi
-
-	# We must run eautoconf to regenerate configure
-	eautoconf
-
-	# make sure it won't find Perl out of Prefix
-	sed -i -e "s/perl5//g" "${S}"/nspr/configure || die
-
-	# Respect LDFLAGS
-	sed -i -e 's/\$(MKSHLIB) \$(OBJS)/\$(MKSHLIB) \$(LDFLAGS) \$(OBJS)/g' \
-		"${S}"/nspr/config/rules.mk || die
-}
-
-multilib_src_configure() {
-	# We use the standard BUILD_xxx but nspr uses HOST_xxx
-	tc-export_build_env BUILD_CC
-	export HOST_CC=${BUILD_CC} HOST_CFLAGS=${BUILD_CFLAGS} HOST_LDFLAGS=${BUILD_LDFLAGS}
-	tc-export AR CC CXX RANLIB
-	[[ ${CBUILD} != ${CHOST} ]] \
-		&& export CROSS_COMPILE=1 \
-		|| unset CROSS_COMPILE
-
-	local myconf=(
-		--libdir="${EPREFIX}/usr/$(get_libdir)"
-		$(use_enable debug)
-		$(use_enable !debug optimize)
-	)
-
-	# The configure has some fancy --enable-{{n,x}32,64bit} switches
-	# that trigger some code conditional to platform & arch. This really
-	# matters for the few common arches (x86, ppc) but we pass a little
-	# more of them to be future-proof.
-
-	# use ABI first, this will work for most cases
-	case "${ABI}" in
-		alpha|arm|hppa|m68k|o32|ppc|s390|sh|sparc|x86) ;;
-		n32) myconf+=( --enable-n32 );;
-		x32) myconf+=( --enable-x32 );;
-		s390x|*64) myconf+=( --enable-64bit );;
-		default) # no abi actually set, fall back to old check
-			einfo "Running a short build test to determine 64bit'ness"
-			echo > "${T}"/test.c || die
-			${CC} ${CFLAGS} ${CPPFLAGS} -c "${T}"/test.c -o "${T}"/test.o || die
-			case $(file "${T}"/test.o) in
-				*32-bit*x86-64*) myconf+=( --enable-x32 );;
-				*64-bit*|*ppc64*|*x86_64*) myconf+=( --enable-64bit );;
-				*32-bit*|*ppc*|*i386*) ;;
-				*) die "Failed to detect whether your arch is 64bits or 32bits, disable distcc if you're using it, please";;
-			esac ;;
-		*) ;;
-	esac
-
-	# Ancient autoconf needs help finding the right tools.
-	LC_ALL="C" ECONF_SOURCE="${S}/nspr" \
-	ac_cv_path_AR="${AR}" \
-	econf "${myconf[@]}"
-}
-
-multilib_src_install() {
-	# Their build system is royally confusing, as usual
-	MINOR_VERSION=${MIN_PV} # Used for .so version
-	emake DESTDIR="${D}" install
-
-	einfo "removing static libraries as upstream has requested!"
-	rm "${ED}"/usr/$(get_libdir)/*.a || die "failed to remove static libraries."
-
-	# install nspr-config
-	dobin config/nspr-config
-
-	# Remove stupid files in /usr/bin
-	rm "${ED}"/usr/bin/prerr.properties || die
-
-	# This is used only to generate prerr.c and prerr.h at build time.
-	# No other projects use it, and we don't want to depend on perl.
-	# Talked to upstream and they agreed w/punting.
-	rm "${ED}"/usr/bin/compile-et.pl || die
-}

diff --git a/dev-libs/nspr/nspr-4.22.ebuild b/dev-libs/nspr/nspr-4.22.ebuild
deleted file mode 100644
index 984ee7b34ca..00000000000
--- a/dev-libs/nspr/nspr-4.22.ebuild
+++ /dev/null
@@ -1,120 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools toolchain-funcs multilib-minimal
-
-MIN_PV="$(ver_cut 2)"
-
-DESCRIPTION="Netscape Portable Runtime"
-HOMEPAGE="http://www.mozilla.org/projects/nspr/"
-SRC_URI="https://archive.mozilla.org/pub/nspr/releases/v${PV}/src/${P}.tar.gz"
-
-LICENSE="|| ( MPL-2.0 GPL-2 LGPL-2.1 )"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~ppc-aix ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
-IUSE="debug elibc_musl"
-
-MULTILIB_CHOST_TOOLS=(
-	/usr/bin/nspr-config
-)
-
-PATCHES=(
-	"${FILESDIR}"/${PN}-4.7.0-prtime.patch
-	"${FILESDIR}"/${PN}-4.7.1-solaris.patch
-	"${FILESDIR}"/${PN}-4.10.6-solaris.patch
-	"${FILESDIR}"/${PN}-4.8.4-darwin-install_name.patch
-	"${FILESDIR}"/${PN}-4.8.9-link-flags.patch
-	# We do not need to pass -L$libdir via nspr-config --libs
-	"${FILESDIR}"/${PN}-4.9.5_nspr_config.patch
-)
-
-src_prepare() {
-	cd "${S}"/nspr || die
-
-	default
-
-	use elibc_musl && eapply "${FILESDIR}"/${PN}-4.21-ipv6-musl-support.patch
-
-	# rename configure.in to configure.ac for new autotools compatibility
-	if [[ -e "${S}"/nspr/configure.in ]] ; then
-		einfo "Renaming configure.in to configure.ac"
-		mv "${S}"/nspr/configure.{in,ac} || die
-	fi
-
-	# We must run eautoconf to regenerate configure
-	eautoconf
-
-	# make sure it won't find Perl out of Prefix
-	sed -i -e "s/perl5//g" "${S}"/nspr/configure || die
-
-	# Respect LDFLAGS
-	sed -i -e 's/\$(MKSHLIB) \$(OBJS)/\$(MKSHLIB) \$(LDFLAGS) \$(OBJS)/g' \
-		"${S}"/nspr/config/rules.mk || die
-}
-
-multilib_src_configure() {
-	# We use the standard BUILD_xxx but nspr uses HOST_xxx
-	tc-export_build_env BUILD_CC
-	export HOST_CC=${BUILD_CC} HOST_CFLAGS=${BUILD_CFLAGS} HOST_LDFLAGS=${BUILD_LDFLAGS}
-	tc-export AR CC CXX RANLIB
-	[[ ${CBUILD} != ${CHOST} ]] \
-		&& export CROSS_COMPILE=1 \
-		|| unset CROSS_COMPILE
-
-	local myconf=(
-		--libdir="${EPREFIX}/usr/$(get_libdir)"
-		$(use_enable debug)
-		$(use_enable !debug optimize)
-	)
-
-	# The configure has some fancy --enable-{{n,x}32,64bit} switches
-	# that trigger some code conditional to platform & arch. This really
-	# matters for the few common arches (x86, ppc) but we pass a little
-	# more of them to be future-proof.
-
-	# use ABI first, this will work for most cases
-	case "${ABI}" in
-		alpha|arm|hppa|m68k|o32|ppc|s390|sh|sparc|x86) ;;
-		n32) myconf+=( --enable-n32 );;
-		x32) myconf+=( --enable-x32 );;
-		s390x|*64) myconf+=( --enable-64bit );;
-		default) # no abi actually set, fall back to old check
-			einfo "Running a short build test to determine 64bit'ness"
-			echo > "${T}"/test.c || die
-			${CC} ${CFLAGS} ${CPPFLAGS} -c "${T}"/test.c -o "${T}"/test.o || die
-			case $(file "${T}"/test.o) in
-				*32-bit*x86-64*) myconf+=( --enable-x32 );;
-				*64-bit*|*ppc64*|*x86_64*) myconf+=( --enable-64bit );;
-				*32-bit*|*ppc*|*i386*) ;;
-				*) die "Failed to detect whether your arch is 64bits or 32bits, disable distcc if you're using it, please";;
-			esac ;;
-		*) ;;
-	esac
-
-	# Ancient autoconf needs help finding the right tools.
-	LC_ALL="C" ECONF_SOURCE="${S}/nspr" \
-	ac_cv_path_AR="${AR}" \
-	econf "${myconf[@]}"
-}
-
-multilib_src_install() {
-	# Their build system is royally confusing, as usual
-	MINOR_VERSION=${MIN_PV} # Used for .so version
-	emake DESTDIR="${D}" install
-
-	einfo "removing static libraries as upstream has requested!"
-	rm "${ED}"/usr/$(get_libdir)/*.a || die "failed to remove static libraries."
-
-	# install nspr-config
-	dobin config/nspr-config
-
-	# Remove stupid files in /usr/bin
-	rm "${ED}"/usr/bin/prerr.properties || die
-
-	# This is used only to generate prerr.c and prerr.h at build time.
-	# No other projects use it, and we don't want to depend on perl.
-	# Talked to upstream and they agreed w/punting.
-	rm "${ED}"/usr/bin/compile-et.pl || die
-}

diff --git a/dev-libs/nspr/nspr-4.24.ebuild b/dev-libs/nspr/nspr-4.24.ebuild
deleted file mode 100644
index 0c02c60c9fb..00000000000
--- a/dev-libs/nspr/nspr-4.24.ebuild
+++ /dev/null
@@ -1,122 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools toolchain-funcs multilib-minimal
-
-MIN_PV="$(ver_cut 2)"
-
-DESCRIPTION="Netscape Portable Runtime"
-HOMEPAGE="http://www.mozilla.org/projects/nspr/"
-SRC_URI="https://archive.mozilla.org/pub/nspr/releases/v${PV}/src/${P}.tar.gz"
-
-LICENSE="|| ( MPL-2.0 GPL-2 LGPL-2.1 )"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~ppc-aix ~amd64-linux ~x86-linux ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
-IUSE="debug elibc_musl"
-
-MULTILIB_CHOST_TOOLS=(
-	/usr/bin/nspr-config
-)
-
-PATCHES=(
-	"${FILESDIR}"/${PN}-4.23-prtime.patch
-	"${FILESDIR}"/${PN}-4.7.1-solaris.patch
-	"${FILESDIR}"/${PN}-4.10.6-solaris.patch
-	"${FILESDIR}"/${PN}-4.8.4-darwin-install_name.patch
-	"${FILESDIR}"/${PN}-4.8.9-link-flags.patch
-	# We do not need to pass -L$libdir via nspr-config --libs
-	"${FILESDIR}"/${PN}-4.9.5_nspr_config.patch
-)
-
-src_prepare() {
-	cd "${S}"/nspr || die
-
-	default
-
-	use elibc_musl && eapply "${FILESDIR}"/${PN}-4.21-ipv6-musl-support.patch
-
-	# rename configure.in to configure.ac for new autotools compatibility
-	if [[ -e "${S}"/nspr/configure.in ]] ; then
-		einfo "Renaming configure.in to configure.ac"
-		mv "${S}"/nspr/configure.{in,ac} || die
-	else
-		elog "configure.in rename logic can be removed from ebuild."
-	fi
-
-	# We must run eautoconf to regenerate configure
-	eautoconf
-
-	# make sure it won't find Perl out of Prefix
-	sed -i -e "s/perl5//g" "${S}"/nspr/configure || die
-
-	# Respect LDFLAGS
-	sed -i -e 's/\$(MKSHLIB) \$(OBJS)/\$(MKSHLIB) \$(LDFLAGS) \$(OBJS)/g' \
-		"${S}"/nspr/config/rules.mk || die
-}
-
-multilib_src_configure() {
-	# We use the standard BUILD_xxx but nspr uses HOST_xxx
-	tc-export_build_env BUILD_CC
-	export HOST_CC=${BUILD_CC} HOST_CFLAGS=${BUILD_CFLAGS} HOST_LDFLAGS=${BUILD_LDFLAGS}
-	tc-export AR CC CXX RANLIB
-	[[ ${CBUILD} != ${CHOST} ]] \
-		&& export CROSS_COMPILE=1 \
-		|| unset CROSS_COMPILE
-
-	local myconf=(
-		--libdir="${EPREFIX}/usr/$(get_libdir)"
-		$(use_enable debug)
-		$(use_enable !debug optimize)
-	)
-
-	# The configure has some fancy --enable-{{n,x}32,64bit} switches
-	# that trigger some code conditional to platform & arch. This really
-	# matters for the few common arches (x86, ppc) but we pass a little
-	# more of them to be future-proof.
-
-	# use ABI first, this will work for most cases
-	case "${ABI}" in
-		alpha|arm|hppa|m68k|o32|ppc|s390|sh|sparc|x86) ;;
-		n32) myconf+=( --enable-n32 );;
-		x32) myconf+=( --enable-x32 );;
-		s390x|*64) myconf+=( --enable-64bit );;
-		default) # no abi actually set, fall back to old check
-			einfo "Running a short build test to determine 64bit'ness"
-			echo > "${T}"/test.c || die
-			${CC} ${CFLAGS} ${CPPFLAGS} -c "${T}"/test.c -o "${T}"/test.o || die
-			case $(file "${T}"/test.o) in
-				*32-bit*x86-64*) myconf+=( --enable-x32 );;
-				*64-bit*|*ppc64*|*x86_64*) myconf+=( --enable-64bit );;
-				*32-bit*|*ppc*|*i386*) ;;
-				*) die "Failed to detect whether your arch is 64bits or 32bits, disable distcc if you're using it, please";;
-			esac ;;
-		*) ;;
-	esac
-
-	# Ancient autoconf needs help finding the right tools.
-	LC_ALL="C" ECONF_SOURCE="${S}/nspr" \
-	ac_cv_path_AR="${AR}" \
-	econf "${myconf[@]}"
-}
-
-multilib_src_install() {
-	# Their build system is royally confusing, as usual
-	MINOR_VERSION=${MIN_PV} # Used for .so version
-	emake DESTDIR="${D}" install
-
-	einfo "removing static libraries as upstream has requested!"
-	rm "${ED}"/usr/$(get_libdir)/*.a || die "failed to remove static libraries."
-
-	# install nspr-config
-	dobin config/nspr-config
-
-	# Remove stupid files in /usr/bin
-	rm "${ED}"/usr/bin/prerr.properties || die
-
-	# This is used only to generate prerr.c and prerr.h at build time.
-	# No other projects use it, and we don't want to depend on perl.
-	# Talked to upstream and they agreed w/punting.
-	rm "${ED}"/usr/bin/compile-et.pl || die
-}


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-libs/nspr/, dev-libs/nspr/files/
@ 2022-05-26  0:58 WANG Xuerui
  0 siblings, 0 replies; 5+ messages in thread
From: WANG Xuerui @ 2022-05-26  0:58 UTC (permalink / raw
  To: gentoo-commits

commit:     03b18997ede10a7dcb57b75af04448310d0772c2
Author:     WANG Xuerui <xen0n <AT> gentoo <DOT> org>
AuthorDate: Wed May 25 14:07:54 2022 +0000
Commit:     WANG Xuerui <xen0n <AT> gentoo <DOT> org>
CommitDate: Thu May 26 00:55:12 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=03b18997

dev-libs/nspr: fix build on loong

Patch applied here has been running on real loong hardware since late
2021, simple and no problems so far.

See: https://github.com/gentoo/gentoo/pull/25632
Acked-by: Joonas Niilola <juippis <AT> gentoo.org>
Signed-off-by: WANG Xuerui <xen0n <AT> gentoo.org>

 dev-libs/nspr/files/nspr-4.33-loong.patch | 100 ++++++++++++++++++++++++++++++
 dev-libs/nspr/nspr-4.33.ebuild            |   1 +
 2 files changed, 101 insertions(+)

diff --git a/dev-libs/nspr/files/nspr-4.33-loong.patch b/dev-libs/nspr/files/nspr-4.33-loong.patch
new file mode 100644
index 000000000000..96772a2767c0
--- /dev/null
+++ b/dev-libs/nspr/files/nspr-4.33-loong.patch
@@ -0,0 +1,100 @@
+https://phabricator.services.mozilla.com/D142407
+
+--- a/pr/include/md/_linux.h
++++ b/pr/include/md/_linux.h
+@@ -71,10 +71,12 @@
+ #define _PR_SI_ARCHITECTURE "microblaze"
+ #elif defined(__nds32__)
+ #define _PR_SI_ARCHITECTURE "nds32"
+ #elif defined(__xtensa__)
+ #define _PR_SI_ARCHITECTURE "xtensa"
++#elif defined(__loongarch64)
++#define _PR_SI_ARCHITECTURE "loongarch64"
+ #else
+ #error "Unknown CPU architecture"
+ #endif
+ #define PR_DLL_SUFFIX       ".so"
+ 
+@@ -139,10 +141,22 @@
+ #define _MD_ATOMIC_ADD                _PR_x86_64_AtomicAdd
+ extern PRInt32 _PR_x86_64_AtomicSet(PRInt32 *val, PRInt32 newval);
+ #define _MD_ATOMIC_SET                _PR_x86_64_AtomicSet
+ #endif
+ 
++#if defined(__loongarch__)
++#if defined(__GNUC__)
++/* Use GCC built-in functions */
++#define _PR_HAVE_ATOMIC_OPS
++#define _MD_INIT_ATOMIC()
++#define _MD_ATOMIC_INCREMENT(ptr) __sync_add_and_fetch(ptr, 1)
++#define _MD_ATOMIC_DECREMENT(ptr) __sync_sub_and_fetch(ptr, 1)
++#define _MD_ATOMIC_ADD(ptr, i) __sync_add_and_fetch(ptr, i)
++#define _MD_ATOMIC_SET(ptr, nv) __sync_lock_test_and_set(ptr, nv)
++#endif
++#endif
++
+ #if defined(__or1k__)
+ #if defined(__GNUC__)
+ /* Use GCC built-in functions */
+ #define _PR_HAVE_ATOMIC_OPS
+ #define _MD_INIT_ATOMIC()
+--- a/pr/include/md/_linux.cfg
++++ b/pr/include/md/_linux.cfg
+@@ -1253,10 +1253,56 @@
+ #define PR_ALIGN_OF_WORD    8
+ 
+ #define PR_BYTES_PER_WORD_LOG2  3
+ #define PR_BYTES_PER_DWORD_LOG2 3
+ 
++#elif defined(__loongarch64)
++
++#undef  IS_BIG_ENDIAN
++#define IS_LITTLE_ENDIAN 1
++#define IS_64
++
++#define PR_BYTES_PER_BYTE   1
++#define PR_BYTES_PER_SHORT  2
++#define PR_BYTES_PER_INT    4
++#define PR_BYTES_PER_INT64  8
++#define PR_BYTES_PER_LONG   8
++#define PR_BYTES_PER_FLOAT  4
++#define PR_BYTES_PER_DOUBLE 8
++#define PR_BYTES_PER_WORD   8
++#define PR_BYTES_PER_DWORD  8
++
++#define PR_BITS_PER_BYTE    8
++#define PR_BITS_PER_SHORT   16
++#define PR_BITS_PER_INT     32
++#define PR_BITS_PER_INT64   64
++#define PR_BITS_PER_LONG    64
++#define PR_BITS_PER_FLOAT   32
++#define PR_BITS_PER_DOUBLE  64
++#define PR_BITS_PER_WORD    64
++
++#define PR_BITS_PER_BYTE_LOG2   3
++#define PR_BITS_PER_SHORT_LOG2  4
++#define PR_BITS_PER_INT_LOG2    5
++#define PR_BITS_PER_INT64_LOG2  6
++#define PR_BITS_PER_LONG_LOG2   6
++#define PR_BITS_PER_FLOAT_LOG2  5
++#define PR_BITS_PER_DOUBLE_LOG2 6
++#define PR_BITS_PER_WORD_LOG2   6
++
++#define PR_ALIGN_OF_SHORT   2
++#define PR_ALIGN_OF_INT     4
++#define PR_ALIGN_OF_LONG    8
++#define PR_ALIGN_OF_INT64   8
++#define PR_ALIGN_OF_FLOAT   4
++#define PR_ALIGN_OF_DOUBLE  8
++#define PR_ALIGN_OF_POINTER 8
++#define PR_ALIGN_OF_WORD    8
++
++#define PR_BYTES_PER_WORD_LOG2  3
++#define PR_BYTES_PER_DWORD_LOG2 3
++
+ #else
+ 
+ #error "Unknown CPU architecture"
+ 
+ #endif
+

diff --git a/dev-libs/nspr/nspr-4.33.ebuild b/dev-libs/nspr/nspr-4.33.ebuild
index 7be0ae41e449..679f81b80400 100644
--- a/dev-libs/nspr/nspr-4.33.ebuild
+++ b/dev-libs/nspr/nspr-4.33.ebuild
@@ -28,6 +28,7 @@ PATCHES=(
 	"${FILESDIR}"/${PN}-4.8.9-link-flags.patch
 	# We do not need to pass -L$libdir via nspr-config --libs
 	"${FILESDIR}"/${PN}-4.9.5_nspr_config.patch
+	"${FILESDIR}"/${PN}-4.33-loong.patch
 )
 
 src_prepare() {


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: dev-libs/nspr/, dev-libs/nspr/files/
@ 2023-05-09 13:16 Joonas Niilola
  0 siblings, 0 replies; 5+ messages in thread
From: Joonas Niilola @ 2023-05-09 13:16 UTC (permalink / raw
  To: gentoo-commits

commit:     af8fbdf37728cc694b65e7b297acc21374755934
Author:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
AuthorDate: Tue May  9 13:16:03 2023 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Tue May  9 13:16:03 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=af8fbdf3

dev-libs/nspr: musl fixes

Closes: https://bugs.gentoo.org/905998
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 dev-libs/nspr/files/nspr-4.35-bgo-905998-lfs64-musl.patch | 15 +++++++++++++++
 dev-libs/nspr/nspr-4.35-r1.ebuild                         |  7 +++++--
 2 files changed, 20 insertions(+), 2 deletions(-)

diff --git a/dev-libs/nspr/files/nspr-4.35-bgo-905998-lfs64-musl.patch b/dev-libs/nspr/files/nspr-4.35-bgo-905998-lfs64-musl.patch
new file mode 100644
index 000000000000..d834c3e0b295
--- /dev/null
+++ b/dev-libs/nspr/files/nspr-4.35-bgo-905998-lfs64-musl.patch
@@ -0,0 +1,15 @@
+needed since https://github.com/bminor/musl/commit/25e6fee27f4a293728dd15b659170e7b9c7db9bc
+--
+diff --git a/nspr/pr/include/md/_unixos.h b/nspr/pr/include/md/_unixos.h
+index 7d444cd..0099d2c 100644
+--- a/nspr/pr/include/md/_unixos.h
++++ b/nspr/pr/include/md/_unixos.h
+@@ -589,7 +589,7 @@ typedef off64_t _MDOff64_t;
+ 
+ #elif defined(_PR_HAVE_OFF64_T)
+ typedef struct stat64 _MDStat64;
+-typedef off64_t _MDOff64_t;
++typedef off_t _MDOff64_t;
+ #elif defined(_PR_HAVE_LARGE_OFF_T)
+ typedef struct stat _MDStat64;
+ typedef off_t _MDOff64_t;

diff --git a/dev-libs/nspr/nspr-4.35-r1.ebuild b/dev-libs/nspr/nspr-4.35-r1.ebuild
index 878f4793dffd..88c8c77686a0 100644
--- a/dev-libs/nspr/nspr-4.35-r1.ebuild
+++ b/dev-libs/nspr/nspr-4.35-r1.ebuild
@@ -21,9 +21,9 @@ MULTILIB_CHOST_TOOLS=(
 )
 
 PATCHES=(
+	"${FILESDIR}"/${PN}-4.10.6-solaris.patch
 	"${FILESDIR}"/${PN}-4.23-prtime.patch
 	"${FILESDIR}"/${PN}-4.7.1-solaris.patch
-	"${FILESDIR}"/${PN}-4.10.6-solaris.patch
 	"${FILESDIR}"/${PN}-4.8.4-darwin-install_name.patch
 	"${FILESDIR}"/${PN}-4.8.9-link-flags.patch
 	# We do not need to pass -L$libdir via nspr-config --libs
@@ -37,7 +37,10 @@ src_prepare() {
 
 	default
 
-	use elibc_musl && eapply "${FILESDIR}"/${PN}-4.21-ipv6-musl-support.patch
+	if use elibc_musl; then
+		eapply "${FILESDIR}"/${PN}-4.21-ipv6-musl-support.patch
+		eapply "${FILESDIR}"/nspr-4.35-bgo-905998-lfs64-musl.patch
+	fi
 
 	# rename configure.in to configure.ac for new autotools compatibility
 	if [[ -e "${S}"/nspr/configure.in ]] ; then


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-05-09 13:16 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-05-26  0:58 [gentoo-commits] repo/gentoo:master commit in: dev-libs/nspr/, dev-libs/nspr/files/ WANG Xuerui
  -- strict thread matches above, loose matches on Subject: below --
2023-05-09 13:16 Joonas Niilola
2020-03-31 17:50 Thomas Deutschmann
2019-03-20 19:12 Jory Pratt
2016-09-28 10:09 Lars Wendler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox