diff options
| -rw-r--r-- | meta/recipes-support/nss/nss/0001-Bug-1493916-Fix-ppc64-inline-assembler-for-clang-r-j.patch | 35 | ||||
| -rw-r--r-- | meta/recipes-support/nss/nss/0001-freebl-add-a-configure-option-to-disable-ARM-HW-cryp.patch | 35 | ||||
| -rw-r--r-- | meta/recipes-support/nss/nss/nss-fix-nsinstall-build.patch | 2 | ||||
| -rw-r--r-- | meta/recipes-support/nss/nss_3.49.1.bb (renamed from meta/recipes-support/nss/nss_3.45.bb) | 13 |
4 files changed, 44 insertions, 41 deletions
diff --git a/meta/recipes-support/nss/nss/0001-Bug-1493916-Fix-ppc64-inline-assembler-for-clang-r-j.patch b/meta/recipes-support/nss/nss/0001-Bug-1493916-Fix-ppc64-inline-assembler-for-clang-r-j.patch deleted file mode 100644 index 59e44e6841..0000000000 --- a/meta/recipes-support/nss/nss/0001-Bug-1493916-Fix-ppc64-inline-assembler-for-clang-r-j.patch +++ /dev/null | |||
| @@ -1,35 +0,0 @@ | |||
| 1 | From 6b351dbb049b3b3ab6c0d51aa3c1c7fb3c9df80c Mon Sep 17 00:00:00 2001 | ||
| 2 | From: =?UTF-8?q?Dan=20Hor=C3=A1k?= <dan@danny.cz> | ||
| 3 | Date: Mon, 22 Jul 2019 11:07:41 -0700 | ||
| 4 | Subject: [PATCH] Bug 1493916 - Fix ppc64 inline assembler for clang r=jcj | ||
| 5 | Seems clang's inline assembler doesn't want registers to be prefixed with | ||
| 6 | "r", while gcc accepts both - r0 and 0 for GPR0. | ||
| 7 | |||
| 8 | tested with clang 6.0 and gcc 8.1 | ||
| 9 | |||
| 10 | --HG-- | ||
| 11 | extra : amend_source : 87e09bb59c78bdb25b9573b9f29511e10b9db6fa | ||
| 12 | extra : histedit_source : 9b3fad70ac2851bf7de14d42c34db4a5fba41710 | ||
| 13 | |||
| 14 | Upstream-Status: Backport [https://github.com/nss-dev/nss/commit/671d89b6c4a6f41707bb044534751098e2e3f211] | ||
| 15 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
| 16 | --- | ||
| 17 | nss/lib/freebl/mpi/mpcpucache.c | 2 +- | ||
| 18 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
| 19 | |||
| 20 | diff --git a/nss/lib/freebl/mpi/mpcpucache.c b/nss/lib/freebl/mpi/mpcpucache.c | ||
| 21 | index 336b4cc..2ad291f 100644 | ||
| 22 | --- a/nss/lib/freebl/mpi/mpcpucache.c | ||
| 23 | +++ b/nss/lib/freebl/mpi/mpcpucache.c | ||
| 24 | @@ -727,7 +727,7 @@ static inline void | ||
| 25 | dcbzl(char *array) | ||
| 26 | { | ||
| 27 | register char *a asm("r2") = array; | ||
| 28 | - __asm__ __volatile__("dcbzl %0,r0" | ||
| 29 | + __asm__ __volatile__("dcbzl %0,0" | ||
| 30 | : "=r"(a) | ||
| 31 | : "0"(a)); | ||
| 32 | } | ||
| 33 | -- | ||
| 34 | 2.24.0 | ||
| 35 | |||
diff --git a/meta/recipes-support/nss/nss/0001-freebl-add-a-configure-option-to-disable-ARM-HW-cryp.patch b/meta/recipes-support/nss/nss/0001-freebl-add-a-configure-option-to-disable-ARM-HW-cryp.patch new file mode 100644 index 0000000000..fe29d19882 --- /dev/null +++ b/meta/recipes-support/nss/nss/0001-freebl-add-a-configure-option-to-disable-ARM-HW-cryp.patch | |||
| @@ -0,0 +1,35 @@ | |||
| 1 | From 5595e9651aca39af945931c73eb524a0f8bd130d Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Alexander Kanavin <alex.kanavin@gmail.com> | ||
| 3 | Date: Wed, 18 Dec 2019 12:29:50 +0100 | ||
| 4 | Subject: [PATCH] freebl: add a configure option to disable ARM HW crypto | ||
| 5 | |||
| 6 | Not all current hardware supports it, particularly anything | ||
| 7 | prior to armv8 does not. | ||
| 8 | |||
| 9 | Upstream-Status: Pending | ||
| 10 | Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> | ||
| 11 | --- | ||
| 12 | nss/lib/freebl/Makefile | 3 +++ | ||
| 13 | 1 file changed, 3 insertions(+) | ||
| 14 | |||
| 15 | diff --git a/nss/lib/freebl/Makefile b/nss/lib/freebl/Makefile | ||
| 16 | index 06506f0..a8b015d 100644 | ||
| 17 | --- a/nss/lib/freebl/Makefile | ||
| 18 | +++ b/nss/lib/freebl/Makefile | ||
| 19 | @@ -125,6 +125,8 @@ else | ||
| 20 | DEFINES += -DNSS_X86 | ||
| 21 | endif | ||
| 22 | endif | ||
| 23 | + | ||
| 24 | +ifdef NSS_USE_ARM_HW_CRYPTO | ||
| 25 | ifeq ($(CPU_ARCH),aarch64) | ||
| 26 | DEFINES += -DUSE_HW_AES | ||
| 27 | EXTRA_SRCS += aes-armv8.c gcm-aarch64.c | ||
| 28 | @@ -145,6 +147,7 @@ ifeq ($(CPU_ARCH),arm) | ||
| 29 | endif | ||
| 30 | endif | ||
| 31 | endif | ||
| 32 | +endif | ||
| 33 | |||
| 34 | ifeq ($(OS_TARGET),OSF1) | ||
| 35 | DEFINES += -DMP_ASSEMBLY_MULTIPLY -DMP_NO_MP_WORD | ||
diff --git a/meta/recipes-support/nss/nss/nss-fix-nsinstall-build.patch b/meta/recipes-support/nss/nss/nss-fix-nsinstall-build.patch index 181c69adb0..43c09d13ea 100644 --- a/meta/recipes-support/nss/nss/nss-fix-nsinstall-build.patch +++ b/meta/recipes-support/nss/nss/nss-fix-nsinstall-build.patch | |||
| @@ -29,7 +29,7 @@ Index: nss-3.24/nss/coreconf/nsinstall/Makefile | |||
| 29 | +# to clean the '-m64' from ARCHFLAG and LDFLAGS. | 29 | +# to clean the '-m64' from ARCHFLAG and LDFLAGS. |
| 30 | +ARCHFLAG = | 30 | +ARCHFLAG = |
| 31 | +LDFLAGS = | 31 | +LDFLAGS = |
| 32 | +CFLAGS = | 32 | +# CFLAGS = |
| 33 | + | 33 | + |
| 34 | ifeq (,$(filter-out OS2 WIN%,$(OS_TARGET))) | 34 | ifeq (,$(filter-out OS2 WIN%,$(OS_TARGET))) |
| 35 | PROGRAM = | 35 | PROGRAM = |
diff --git a/meta/recipes-support/nss/nss_3.45.bb b/meta/recipes-support/nss/nss_3.49.1.bb index c8005a5b3a..94f4b88fa5 100644 --- a/meta/recipes-support/nss/nss_3.45.bb +++ b/meta/recipes-support/nss/nss_3.49.1.bb | |||
| @@ -25,17 +25,17 @@ SRC_URI = "http://ftp.mozilla.org/pub/mozilla.org/security/nss/releases/${VERSIO | |||
| 25 | file://0001-nss-fix-support-cross-compiling.patch \ | 25 | file://0001-nss-fix-support-cross-compiling.patch \ |
| 26 | file://nss-no-rpath-for-cross-compiling.patch \ | 26 | file://nss-no-rpath-for-cross-compiling.patch \ |
| 27 | file://nss-fix-incorrect-shebang-of-perl.patch \ | 27 | file://nss-fix-incorrect-shebang-of-perl.patch \ |
| 28 | file://nss-fix-nsinstall-build.patch \ | ||
| 29 | file://disable-Wvarargs-with-clang.patch \ | 28 | file://disable-Wvarargs-with-clang.patch \ |
| 30 | file://pqg.c-ULL_addend.patch \ | 29 | file://pqg.c-ULL_addend.patch \ |
| 31 | file://0001-Bug-1493916-Fix-ppc64-inline-assembler-for-clang-r-j.patch \ | ||
| 32 | file://blank-cert9.db \ | 30 | file://blank-cert9.db \ |
| 33 | file://blank-key4.db \ | 31 | file://blank-key4.db \ |
| 34 | file://system-pkcs11.txt \ | 32 | file://system-pkcs11.txt \ |
| 33 | file://nss-fix-nsinstall-build.patch \ | ||
| 34 | file://0001-freebl-add-a-configure-option-to-disable-ARM-HW-cryp.patch \ | ||
| 35 | " | 35 | " |
| 36 | 36 | ||
| 37 | SRC_URI[md5sum] = "f1752d7223ee9d910d551e57264bafa8" | 37 | SRC_URI[md5sum] = "6b92ac02dcf9e9e44df5390f6814c157" |
| 38 | SRC_URI[sha256sum] = "112f05223d1fde902c170966bfc6f011b24a838be16969b110ecf2bb7bc24e8b" | 38 | SRC_URI[sha256sum] = "d9aa42e49e02bb0dc0a2f164604cfc718e11a2a06ddb266cd676376ac21b026e" |
| 39 | 39 | ||
| 40 | UPSTREAM_CHECK_URI = "https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/NSS_Releases" | 40 | UPSTREAM_CHECK_URI = "https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/NSS_Releases" |
| 41 | UPSTREAM_CHECK_REGEX = "NSS_(?P<pver>.+)_release_notes" | 41 | UPSTREAM_CHECK_REGEX = "NSS_(?P<pver>.+)_release_notes" |
| @@ -69,7 +69,8 @@ do_compile_prepend_class-native() { | |||
| 69 | do_compile() { | 69 | do_compile() { |
| 70 | export CROSS_COMPILE=1 | 70 | export CROSS_COMPILE=1 |
| 71 | export NATIVE_CC="${BUILD_CC}" | 71 | export NATIVE_CC="${BUILD_CC}" |
| 72 | export NATIVE_FLAGS="${BUILD_CFLAGS}" | 72 | # Additional defines needed on Centos 7 |
| 73 | export NATIVE_FLAGS="${BUILD_CFLAGS} -DLINUX -Dlinux" | ||
| 73 | export BUILD_OPT=1 | 74 | export BUILD_OPT=1 |
| 74 | 75 | ||
| 75 | export FREEBL_NO_DEPEND=1 | 76 | export FREEBL_NO_DEPEND=1 |
| @@ -81,6 +82,8 @@ do_compile() { | |||
| 81 | export NSS_USE_SYSTEM_SQLITE=1 | 82 | export NSS_USE_SYSTEM_SQLITE=1 |
| 82 | export NSS_ENABLE_ECC=1 | 83 | export NSS_ENABLE_ECC=1 |
| 83 | 84 | ||
| 85 | ${@bb.utils.contains("TUNE_FEATURES", "crypto", "export NSS_USE_ARM_HW_CRYPTO=1", "", d)} | ||
| 86 | |||
| 84 | export OS_RELEASE=3.4 | 87 | export OS_RELEASE=3.4 |
| 85 | export OS_TARGET=Linux | 88 | export OS_TARGET=Linux |
| 86 | export OS_ARCH=Linux | 89 | export OS_ARCH=Linux |
