summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt A. Tobin <email@mattatobin.com>2022-04-09 01:20:24 -0500
committerMatt A. Tobin <email@mattatobin.com>2022-04-09 01:20:24 -0500
commitcb30ae76259a4d4fbdae48504c73e9bc67da9cd7 (patch)
treed982b967e8ef84fea3497989ca1a5b02a92f90e0
parent2d2c741e3f5e658bec668c74915f427f72b98b3c (diff)
downloadaura-central-cb30ae76259a4d4fbdae48504c73e9bc67da9cd7.tar.gz
[NSS] Get NSS 3.64 gyp to understand disabling avx2 in freebl
-rw-r--r--libs/nss/patches/README2
-rw-r--r--libs/nss/src/coreconf/config.gypi6
-rw-r--r--libs/nss/src/lib/freebl/freebl.gyp4
3 files changed, 8 insertions, 4 deletions
diff --git a/libs/nss/patches/README b/libs/nss/patches/README
deleted file mode 100644
index 788bf6a53..000000000
--- a/libs/nss/patches/README
+++ /dev/null
@@ -1,2 +0,0 @@
-This directory contains patches that were added locally
-on top of the NSS release.
diff --git a/libs/nss/src/coreconf/config.gypi b/libs/nss/src/coreconf/config.gypi
index 951e9abd1..07837b09b 100644
--- a/libs/nss/src/coreconf/config.gypi
+++ b/libs/nss/src/coreconf/config.gypi
@@ -104,6 +104,7 @@
'disable_deprecated_seed%': 0,
'disable_deprecated_rc2%': 0,
'disable_dbm%': 1,
+ 'disable_avx2%': 1,
'disable_libpkix%': 1,
'disable_werror%': 0,
'disable_altivec%': 0,
@@ -573,6 +574,11 @@
'NSS_DISABLE_DBM',
],
}],
+ [ 'disable_avx2==1', {
+ 'defines': [
+ 'NSS_DISABLE_AVX2',
+ ],
+ }],
[ 'enable_draft_hpke==1', {
'defines': [
'NSS_ENABLE_DRAFT_HPKE',
diff --git a/libs/nss/src/lib/freebl/freebl.gyp b/libs/nss/src/lib/freebl/freebl.gyp
index 865f89232..43dd753fb 100644
--- a/libs/nss/src/lib/freebl/freebl.gyp
+++ b/libs/nss/src/lib/freebl/freebl.gyp
@@ -129,7 +129,7 @@
'<(DEPTH)/exports.gyp:nss_exports'
],
'conditions': [
- [ 'target_arch=="x64"', {
+ [ 'target_arch=="x64" and disable_avx2==0', {
'cflags': [
'-mssse3',
'-msse4.1',
@@ -179,7 +179,7 @@
'-mfpu=neon'
],
}],
- [ 'target_arch=="x64"', {
+ [ 'target_arch=="x64" and disable_avx2==0', {
'sources': [
'verified/Hacl_Poly1305_256.c',
'verified/Hacl_Chacha20_Vec256.c',