]> rtime.felk.cvut.cz Git - coffee/buildroot.git/blob - package/libnss/0003-Build-Hacl_Poly1305_64_o_on_Aarch64.patch
libnss: add upstream patch fixing build on aarch64
[coffee/buildroot.git] / package / libnss / 0003-Build-Hacl_Poly1305_64_o_on_Aarch64.patch
1 # HG changeset patch
2 # User Daiki Ueno <dueno@redhat.com>
3 # Date 1516710574 -3600
4 # Node ID 1668fafc1db4f739d5d15fbc94283858f842deb5
5 # Parent  c3702e37a048e386f88e7c50a228d27669332725
6 Bug 1432455, Build Hacl_Poly1305_64.o on AArch64 even with make, r=fkiefer
7
8 [Upstream: https://hg.mozilla.org/projects/nss/rev/1668fafc1db4
9  Peter: adjust paths for tarball]
10 Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
11 diff --git a/nss/lib/freebl/Makefile b/nss/lib/freebl/Makefile
12 --- a/nss/lib/freebl/Makefile
13 +++ b/nss/lib/freebl/Makefile
14 @@ -522,17 +522,22 @@ ifndef NSS_DISABLE_CHACHAPOLY
15  
16          ifneq (1,$(CC_IS_GCC))
17              EXTRA_SRCS += chacha20.c
18              VERIFIED_SRCS += Hacl_Chacha20.c
19          else
20              EXTRA_SRCS += chacha20_vec.c
21          endif
22      else
23 -        EXTRA_SRCS += poly1305.c
24 +        ifeq ($(CPU_ARCH),aarch64)
25 +            EXTRA_SRCS += Hacl_Poly1305_64.c
26 +        else
27 +            EXTRA_SRCS += poly1305.c
28 +        endif
29 +
30          EXTRA_SRCS += chacha20.c
31          VERIFIED_SRCS += Hacl_Chacha20.c
32      endif # x86_64
33  endif # NSS_DISABLE_CHACHAPOLY
34  
35  ifeq (,$(filter-out i386 x386 x86 x86_64 aarch64,$(CPU_ARCH)))
36      # All intel architectures get the 64 bit version
37      # With custom uint128 if necessary (faster than generic 32 bit version).
38