Github messages for voidlinux
 help / color / Atom feed
* [PR PATCH] nss: update to 3.53.
@ 2020-06-02  2:02 sgn
  0 siblings, 0 replies; only message in thread
From: sgn @ 2020-06-02  2:02 UTC (permalink / raw)
  To: ml


[-- Attachment #1: Type: text/plain, Size: 457 bytes --]

There is a new pull request by sgn against master on the void-packages repository

https://github.com/sgn/void-packages nss-3.53
https://github.com/void-linux/void-packages/pull/22509

nss: update to 3.53.
- Automated test is running for `x86_64`.
- Manual test haven't done yet.
- Planning a test on qemu-x86_64 without avx2

---
@q66 please check for PowerPC

A patch file from https://github.com/void-linux/void-packages/pull/22509.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-nss-3.53-22509.patch --]
[-- Type: text/x-diff, Size: 5357 bytes --]

From 6545b495dc73212d7bea4fdf89efd6fa3e6b37b7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
 <congdanhqx@gmail.com>
Date: Sun, 31 May 2020 10:10:03 +0700
Subject: [PATCH] nss: update to 3.53.

---
 ...-enable-AVX2-if-applicable-on-x86_64.patch | 80 +++++++++++++++++++
 srcpkgs/nss/template                          | 13 ++-
 2 files changed, 85 insertions(+), 8 deletions(-)
 create mode 100644 srcpkgs/nss/patches/0001-enable-AVX2-if-applicable-on-x86_64.patch

diff --git a/srcpkgs/nss/patches/0001-enable-AVX2-if-applicable-on-x86_64.patch b/srcpkgs/nss/patches/0001-enable-AVX2-if-applicable-on-x86_64.patch
new file mode 100644
index 00000000000..f410c8ad855
--- /dev/null
+++ b/srcpkgs/nss/patches/0001-enable-AVX2-if-applicable-on-x86_64.patch
@@ -0,0 +1,80 @@
+From f8d9ecea60d99c6143dcb9e2f8fe41c8e17e4d0f Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?=C4=90o=C3=A0n=20Tr=E1=BA=A7n=20C=C3=B4ng=20Danh?=
+ <congdanhqx@gmail.com>
+Date: Sun, 31 May 2020 12:13:08 +0700
+Subject: [PATCH] enable AVX2 if applicable on x86_64
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+There's a runtime check for AVX2 before using, see:
+
+	lib/freebl/chacha20poly1305.c:140
+	lib/freebl/blinit.c:117
+
+Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com>
+---
+ nss/coreconf/arch.mk    | 1 +
+ nss/coreconf/config.mk  | 2 ++
+ nss/lib/freebl/Makefile | 9 +++++++--
+ 3 files changed, 10 insertions(+), 2 deletions(-)
+
+diff --git nss/coreconf/arch.mk nss/coreconf/arch.mk
+index 790372d..cc13ced 100644
+--- nss/coreconf/arch.mk
++++ nss/coreconf/arch.mk
+@@ -116,6 +116,7 @@ ifeq ($(OS_ARCH),Linux)
+ 	OS_RELEASE := $(word 1,$(OS_RELEASE)).$(word 2,$(OS_RELEASE))
+     endif
+     KERNEL = Linux
++    include $(CORE_DEPTH)/coreconf/Linux.mk
+ endif
+ 
+ # Since all uses of OS_ARCH that follow affect only userland, we can
+diff --git nss/coreconf/config.mk nss/coreconf/config.mk
+index 39f755d..b65e684 100644
+--- nss/coreconf/config.mk
++++ nss/coreconf/config.mk
+@@ -149,8 +149,10 @@ DEFINES += -DNSS_DISABLE_DBM
+ endif
+ 
+ ifdef NSS_DISABLE_AVX2
++ifneq ($(NSS_DISABLE_AVX2),0)
+ DEFINES += -DNSS_DISABLE_AVX2
+ endif
++endif
+ 
+ ifdef NSS_DISABLE_CHACHAPOLY
+ DEFINES += -DNSS_DISABLE_CHACHAPOLY
+diff --git nss/lib/freebl/Makefile nss/lib/freebl/Makefile
+index 5f73844..8b98370 100644
+--- nss/lib/freebl/Makefile
++++ nss/lib/freebl/Makefile
+@@ -552,10 +552,12 @@ endif
+ ifndef NSS_DISABLE_CHACHAPOLY
+     ifeq ($(CPU_ARCH),x86_64)
+         ifndef NSS_DISABLE_AVX2
++            NSS_DISABLE_AVX2 = 0
++        endif
++        ifeq ($(NSS_DISABLE_AVX2),0)
+             EXTRA_SRCS += Hacl_Poly1305_256.c Hacl_Chacha20_Vec256.c Hacl_Chacha20Poly1305_256.c
+-        else
+-            EXTRA_SRCS += Hacl_Poly1305_128.c Hacl_Chacha20_Vec128.c Hacl_Chacha20Poly1305_128.c
+         endif # NSS_DISABLE_AVX2
++        EXTRA_SRCS += Hacl_Poly1305_128.c Hacl_Chacha20_Vec128.c Hacl_Chacha20Poly1305_128.c
+     endif # x86_64
+ 
+     VERIFIED_SRCS += Hacl_Poly1305_32.c Hacl_Chacha20.c Hacl_Chacha20Poly1305_32.c
+@@ -737,6 +739,9 @@ $(OBJDIR)/$(PROG_PREFIX)Hacl_Chacha20Poly1305_128$(OBJ_SUFFIX): CFLAGS += -mssse
+ $(OBJDIR)/$(PROG_PREFIX)Hacl_Poly1305_128$(OBJ_SUFFIX): CFLAGS += -mssse3 -msse4.1 -msse4.2 -mavx -maes -mpclmul
+ 
+ ifndef NSS_DISABLE_AVX2
++    NSS_DISABLE_AVX2 = 0
++endif
++ifeq ($(NSS_DISABLE_AVX2),0)
+ $(OBJDIR)/$(PROG_PREFIX)Hacl_Chacha20Poly1305_256$(OBJ_SUFFIX): CFLAGS += -mssse3 -msse4.1 -msse4.2 -mavx2 -maes
+ $(OBJDIR)/$(PROG_PREFIX)Hacl_Chacha20_Vec256$(OBJ_SUFFIX): CFLAGS += -mssse3 -msse4.1 -msse4.2 -mavx -mavx2 -maes
+ $(OBJDIR)/$(PROG_PREFIX)Hacl_Poly1305_256$(OBJ_SUFFIX): CFLAGS += -mssse3 -msse4.1 -msse4.2 -mavx -mavx2 -maes -mpclmul
+-- 
+2.26.2.672.g232c24e857
+
diff --git a/srcpkgs/nss/template b/srcpkgs/nss/template
index e7d616e8732..38d2dcde14f 100644
--- a/srcpkgs/nss/template
+++ b/srcpkgs/nss/template
@@ -3,17 +3,17 @@
 _nsprver=4.25
 
 pkgname=nss
-version=3.52.1
+version=3.53
 revision=1
 hostmakedepends="perl"
 makedepends="nspr-devel sqlite-devel zlib-devel"
 depends="nspr>=${_nsprver}"
 short_desc="Mozilla Network Security Services"
-maintainer="Doan Tran Cong Danh <congdanhqx@gmail.com>"
+maintainer="Đoàn Trần Công Danh <congdanhqx@gmail.com>"
 license="MPL-2.0"
 homepage="https://www.mozilla.org/projects/security/pki/nss"
 distfiles="${MOZILLA_SITE}/security/nss/releases/NSS_${version//\./_}_RTM/src/nss-${version}.tar.gz"
-checksum=bcc81ac33aeb4ecad182dc21e34d2c97bcc148fd7b9e76f85bebb892405a9278
+checksum=08d36dc1a56325f02e626626d4eeab9c4d126dbd99dfaf419b91d0a696f58917
 
 do_build() {
 	local _native_use64 _target_use64
@@ -75,17 +75,14 @@ do_build() {
 		export XCFLAGS="${CFLAGS}"
 
 		make CROSS_COMPILE=1 OS_TEST="${_ARCH}" NSINSTALL="${wrksrc}/nsinstall" \
-			CC="$CC" CCC="$CXX" RANLIB="$RANLIB" ${_target_use64} -C lib/dbm
-		make CROSS_COMPILE=1 OS_TEST="${_ARCH}" NSINSTALL="${wrksrc}/nsinstall" \
-			CC="$CC" CCC="$CXX" RANLIB="$RANLIB" ${_target_use64}
+			CC="$CC" CCC="$CXX" RANLIB="$RANLIB" ${_target_use64} all
 	else
 		# native build
 		export NSPR_INCLUDE_DIR=/usr/include/nspr
 		export NSPR_LIB_DIR=/usr/lib
 		export XCFLAGS="${CFLAGS}"
 
-		make ${_native_use64} -C lib/dbm
-		make ${_native_use64}
+		make ${_native_use64} all
 	fi
 }
 

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, back to index

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-02  2:02 [PR PATCH] nss: update to 3.53 sgn

Github messages for voidlinux

Archives are clonable: git clone --mirror http://inbox.vuxu.org/voidlinux-github

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://inbox.vuxu.org/vuxu.github.voidlinux


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git