commit: ec20c088969d214dbd02053e974ca3186fe5148b Author: Jory A. Pratt <anarchy <AT> gentoo <DOT> org> AuthorDate: Tue Jun 5 13:30:51 2018 +0000 Commit: Jory Pratt <anarchy <AT> gentoo <DOT> org> CommitDate: Tue Jun 5 13:30:51 2018 +0000 URL: https://gitweb.gentoo.org/proj/mozilla.git/commit/?id=ec20c088
dev-libs/nss: Use upstream fix for bug #655636 .../nss-3.37-Fstar.c-when-intl128-disabled.patch | 105 +++++++++++++++++++++ .../files/nss-3.37-fix-fstar-missing-symbols.patch | 34 ------- dev-libs/nss/nss-3.37.1.ebuild | 2 +- 3 files changed, 106 insertions(+), 35 deletions(-) diff --git a/dev-libs/nss/files/nss-3.37-Fstar.c-when-intl128-disabled.patch b/dev-libs/nss/files/nss-3.37-Fstar.c-when-intl128-disabled.patch new file mode 100644 index 0000000..efcaba9 --- /dev/null +++ b/dev-libs/nss/files/nss-3.37-Fstar.c-when-intl128-disabled.patch @@ -0,0 +1,105 @@ +From 1d98ff04bb2ca5f1f7daaf3e118dacf7172425d4 Mon Sep 17 00:00:00 2001 +From: Mike Hommey <[email protected]> +Date: Mon, 28 May 2018 07:36:46 +0900 +Subject: [PATCH] Bug 1432455 - Build FStar.c when not building with int128 + support. r?fkiefer + +--- + lib/freebl/Makefile | 6 +++++- + lib/freebl/freebl.gyp | 29 +++++++++++++++++------------ + lib/freebl/freebl_base.gypi | 4 +++- + 3 files changed, 25 insertions(+), 14 deletions(-) + +diff --git a/lib/freebl/Makefile b/lib/freebl/Makefile +index e6a94d35c4..bff11c7c8e 100644 +--- a/lib/freebl/Makefile ++++ b/lib/freebl/Makefile +@@ -535,12 +535,16 @@ ifeq (,$(filter-out i386 x386 x86 x86_64 aarch64,$(CPU_ARCH))) + # All intel architectures get the 64 bit version + # With custom uint128 if necessary (faster than generic 32 bit version). + ECL_SRCS += curve25519_64.c +- VERIFIED_SRCS += Hacl_Curve25519.c FStar.c ++ VERIFIED_SRCS += Hacl_Curve25519.c + else + # All non intel architectures get the generic 32 bit implementation (slow!) + ECL_SRCS += curve25519_32.c + endif + ++ifndef HAVE_INT128_SUPPORT ++ VERIFIED_SRCS += FStar.c ++endif ++ + ####################################################################### + # (5) Execute "global" rules. (OPTIONAL) # + ####################################################################### +diff --git a/lib/freebl/freebl.gyp b/lib/freebl/freebl.gyp +index 3760102ad8..004807483e 100644 +--- a/lib/freebl/freebl.gyp ++++ b/lib/freebl/freebl.gyp +@@ -277,18 +277,10 @@ + 'MP_IS_LITTLE_ENDIAN', + ], + }], +- [ 'OS!="win"', { +- 'conditions': [ +- [ 'target_arch=="x64" or target_arch=="arm64" or target_arch=="aarch64"', { +- 'defines': [ +- # The Makefile does version-tests on GCC, but we're not doing that here. +- 'HAVE_INT128_SUPPORT', +- ], +- }, { +- 'defines': [ +- 'KRML_NOUINT128', +- ], +- }], ++ [ 'have_int128_support==1', { ++ 'defines': [ ++ # The Makefile does version-tests on GCC, but we're not doing that here. ++ 'HAVE_INT128_SUPPORT', + ], + }, { + 'defines': [ +@@ -350,5 +342,18 @@ + }, + 'variables': { + 'module': 'nss', ++ 'conditions': [ ++ [ 'OS!="win"', { ++ 'conditions': [ ++ [ 'target_arch=="x64" or target_arch=="arm64" or target_arch=="aarch64"', { ++ 'have_int128_support%': 1, ++ }, { ++ 'have_int128_support%': 0, ++ }], ++ ], ++ }, { ++ 'have_int128_support%': 0, ++ }], ++ ], + } + } +diff --git a/lib/freebl/freebl_base.gypi b/lib/freebl/freebl_base.gypi +index 850c327c26..1372994f4c 100644 +--- a/lib/freebl/freebl_base.gypi ++++ b/lib/freebl/freebl_base.gypi +@@ -60,7 +60,6 @@ + 'shvfy.c', + 'sysrand.c', + 'tlsprfalg.c', +- 'verified/FStar.c', + ], + 'conditions': [ + [ 'OS=="linux" or OS=="android"', { +@@ -220,6 +219,9 @@ + }], + ], + }], ++ [ 'have_int128_support==0', { ++ 'sources': [ 'verified/FStar.c' ], ++ }], + ], + 'ldflags': [ + '-Wl,-Bsymbolic' +-- +2.17.0 + diff --git a/dev-libs/nss/files/nss-3.37-fix-fstar-missing-symbols.patch b/dev-libs/nss/files/nss-3.37-fix-fstar-missing-symbols.patch deleted file mode 100644 index 4a6be4e..0000000 --- a/dev-libs/nss/files/nss-3.37-fix-fstar-missing-symbols.patch +++ /dev/null @@ -1,34 +0,0 @@ -# HG changeset patch -# User Jan Beich <[email protected]> -# Date 1525728934 0 -# Node ID 259444458a1a7f2ce1813ebe88d924173d5daf0c -# Parent 5db9e969c74a2a02c4b1d918792827014d1a9d5e -Bug 1459739 - Build FStar.o on 32-bit ARM even with make. r=fkiefer - - -diff --git a/lib/freebl/Makefile b/lib/freebl/Makefile ---- a/lib/freebl/Makefile -+++ b/lib/freebl/Makefile -@@ -534,16 +534,19 @@ endif # NSS_DISABLE_CHACHAPOLY - ifeq (,$(filter-out i386 x386 x86 x86_64 aarch64,$(CPU_ARCH))) - # All intel architectures get the 64 bit version - # With custom uint128 if necessary (faster than generic 32 bit version). - ECL_SRCS += curve25519_64.c - VERIFIED_SRCS += Hacl_Curve25519.c FStar.c - else - # All non intel architectures get the generic 32 bit implementation (slow!) - ECL_SRCS += curve25519_32.c -+ifndef NSS_DISABLE_CHACHAPOLY -+ VERIFIED_SRCS += FStar.c -+endif - endif - - ####################################################################### - # (5) Execute "global" rules. (OPTIONAL) # - ####################################################################### - - include $(CORE_DEPTH)/coreconf/rules.mk - - - - diff --git a/dev-libs/nss/nss-3.37.1.ebuild b/dev-libs/nss/nss-3.37.1.ebuild index 15bc70a..b7972ad 100644 --- a/dev-libs/nss/nss-3.37.1.ebuild +++ b/dev-libs/nss/nss-3.37.1.ebuild @@ -43,7 +43,7 @@ PATCHES=( "${FILESDIR}/${PN}-3.32-gentoo-fixups.patch" "${FILESDIR}/${PN}-3.21-gentoo-fixup-warnings.patch" "${FILESDIR}/${PN}-3.23-hppa-byte_order.patch" - "${FILESDIR}/${PN}-3.37-fix-fstar-missing-symbols.patch" + "${FILESDIR}/${PN}-3.37-Fstar.c-when-intl128-disabled.patch" ) src_unpack() {
