Bug 242104 - security/nss: fails to build on aarch64 13-current
Summary: security/nss: fails to build on aarch64 13-current
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: arm64 Any
: --- Affects Only Me
Assignee: freebsd-gecko (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-11-20 10:52 UTC by Mikael Urankar
Modified: 2019-11-24 00:53 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (gecko)


Attachments
patch (2.38 KB, patch)
2019-11-20 10:52 UTC, Mikael Urankar
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Comment 1 Mikael Urankar freebsd_committer freebsd_triage 2019-11-23 10:40:14 UTC
http://thunderx1.nyi.freebsd.org/data/head-arm64-default/p518178_s355024/logs/errors/nss-3.47.1.log


cc -o FreeBSD13.0_OPT.OBJ/FreeBSD_SINGLE_SHLIB/blinit.o -c -O2 -pipe  -I/usr/local/include/nspr -fstack-protector-strong -fno-strict-aliasing   -fPIC -Wall -Wno-switch -DFREEBSD -DHAVE_STRERROR -DHAVE_BSD_FLOCK -Wall -Wshadow -Qunused-arguments -Wno-parentheses-equality -Wno-array-bounds -Wno-unevaluated-expression -Werror -DXP_UNIX -UDEBUG -DNDEBUG -D_THREAD_SAFE -D_REENTRANT -DNSS_NO_INIT_SUPPORT -DUSE_UTIL_DIRECTLY -DNO_NSPR_10_SUPPORT -DSSL_DISABLE_DEPRECATED_CIPHER_SUITE_NAMES -I./../dist/FreeBSD13.0_OPT.OBJ/include -I./../dist/public/ -I./../dist/private/   -fPIC -Wall -Wno-switch -DFREEBSD -DHAVE_STRERROR -DHAVE_BSD_FLOCK -Wall -Wshadow -Qunused-arguments -Wno-parentheses-equality -Wno-array-bounds -Wno-unevaluated-expression -Werror -DXP_UNIX -UDEBUG -DNDEBUG -D_THREAD_SAFE -D_REENTRANT -DNSS_NO_INIT_SUPPORT -DUSE_UTIL_DIRECTLY -DNO_NSPR_10_SUPPORT -DSSL_DISABLE_DEPRECATED_CIPHER_SUITE_NAMES -I../../dist/FreeBSD13.0_OPT.OBJ/include -I../../dist/public/ -I../../dist/private/   -fPIC -Wall -Wno-switch -DFREEBSD -DHAVE_STRERROR -DHAVE_BSD_FLOCK -Wall -Wshadow -Qunused-arguments -Wno-parentheses-equality -Wno-array-bounds -Wno-unevaluated-expression -Werror -DXP_UNIX -DSHLIB_SUFFIX=\"so\" -DSHLIB_PREFIX=\"lib\" -DSHLIB_VERSION=\"3\" -DSOFTOKEN_SHLIB_VERSION=\"3\" -DRIJNDAEL_INCLUDE_TABLES -UDEBUG -DNDEBUG -D_THREAD_SAFE -D_REENTRANT -DNSS_NO_INIT_SUPPORT -DUSE_UTIL_DIRECTLY -DNO_NSPR_10_SUPPORT -DSSL_DISABLE_DEPRECATED_CIPHER_SUITE_NAMES -DNSS_USE_64 -DFREEBL_LOWHASH -DUSE_HW_AES -DHAVE_INT128_SUPPORT -DMP_API_COMPATIBLE -I../../../dist/FreeBSD13.0_OPT.OBJ/include -I../../../dist/public/nss -I../../../dist/private/nss -Impi -Iecl -Iverified   -fPIC -Wall -Wno-switch -DFREEBSD -DHAVE_STRERROR -DHAVE_BSD_FLOCK -Wall -Wshadow -Qunused-arguments -Wno-parentheses-equality -Wno-array-bounds -Wno-unevaluated-expression -Werror -DXP_UNIX -DSHLIB_SUFFIX=\"so\" -DSHLIB_PREFIX=\"lib\" -DSHLIB_VERSION=\"3\" -DSOFTOKEN_SHLIB_VERSION=\"3\" -DRIJNDAEL_INCLUDE_TABLES -UDEBUG -DNDEBUG -D_THREAD_SAFE -D_REENTRANT -DNSS_NO_INIT_SUPPORT -DUSE_UTIL_DIRECTLY -DNO_NSPR_10_SUPPORT -DSSL_DISABLE_DEPRECATED_CIPHER_SUITE_NAMES -DNSS_USE_64 -DFREEBL_LOWHASH -DUSE_HW_AES -DHAVE_INT128_SUPPORT -DMP_API_COMPATIBLE -I../../../dist/FreeBSD13.0_OPT.OBJ/include -I../../../dist/public/nss -I../../../dist/private/nss -Impi -Iecl -Iverified  -std=gnu99 blinit.c
blinit.c:160:28: error: implicit declaration of function 'ID_AA64ISAR0_AES' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
        arm_aes_support_ = ID_AA64ISAR0_AES(id_aa64isar0) >= ID_AA64ISAR0_AES_BASE && disable_hw_aes == NULL;
                           ^
blinit.c:162:29: error: implicit declaration of function 'ID_AA64ISAR0_SHA1' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
        arm_sha1_support_ = ID_AA64ISAR0_SHA1(id_aa64isar0) == ID_AA64ISAR0_SHA1_BASE;
                            ^
blinit.c:162:29: note: did you mean 'ID_AA64ISAR0_AES'?
blinit.c:160:28: note: 'ID_AA64ISAR0_AES' declared here
        arm_aes_support_ = ID_AA64ISAR0_AES(id_aa64isar0) >= ID_AA64ISAR0_AES_BASE && disable_hw_aes == NULL;
                           ^
blinit.c:163:29: error: implicit declaration of function 'ID_AA64ISAR0_SHA2' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
        arm_sha2_support_ = ID_AA64ISAR0_SHA2(id_aa64isar0) >= ID_AA64ISAR0_SHA2_BASE;
                            ^
blinit.c:163:29: note: did you mean 'ID_AA64ISAR0_SHA1'?
blinit.c:162:29: note: 'ID_AA64ISAR0_SHA1' declared here
        arm_sha1_support_ = ID_AA64ISAR0_SHA1(id_aa64isar0) == ID_AA64ISAR0_SHA1_BASE;
                            ^
3 errors generated.
Comment 2 commit-hook freebsd_committer freebsd_triage 2019-11-24 00:52:00 UTC
A commit references this bug:

Author: jbeich
Date: Sun Nov 24 00:51:29 UTC 2019
New revision: 518282
URL: https://svnweb.freebsd.org/changeset/ports/518282

Log:
  security/nss: unbreak aarch64 on -CURRENT

  blinit.c:159:24: error: expected readable system register
          id_aa64isar0 = READ_SPECIALREG(ID_AA64ISAR0_EL1);
                         ^
  /usr/include/machine/armreg.h:61:19: note: expanded from macro 'READ_SPECIALREG'
          __asm __volatile("mrs   %0, " __STRING(reg) : "=&r" (_val));    \
                           ^
  <inline asm>:1:10: note: instantiated into assembly here
          mrs     x8, (((3) << 19) | ((0) << 16) | ((0) << 12) | ((6) << 8) | ((0) << 5))
                      ^
  blinit.c:160:28: error: implicit declaration of function 'ID_AA64ISAR0_AES' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
          arm_aes_support_ = ID_AA64ISAR0_AES(id_aa64isar0) >= ID_AA64ISAR0_AES_BASE && disable_hw_aes == NULL;
                             ^
  blinit.c:162:29: error: implicit declaration of function 'ID_AA64ISAR0_SHA1' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
          arm_sha1_support_ = ID_AA64ISAR0_SHA1(id_aa64isar0) == ID_AA64ISAR0_SHA1_BASE;
                              ^
  blinit.c:162:29: note: did you mean 'ID_AA64ISAR0_AES'?
  blinit.c:160:28: note: 'ID_AA64ISAR0_AES' declared here
          arm_aes_support_ = ID_AA64ISAR0_AES(id_aa64isar0) >= ID_AA64ISAR0_AES_BASE && disable_hw_aes == NULL;
                             ^
  blinit.c:163:29: error: implicit declaration of function 'ID_AA64ISAR0_SHA2' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
          arm_sha2_support_ = ID_AA64ISAR0_SHA2(id_aa64isar0) >= ID_AA64ISAR0_SHA2_BASE;
                              ^
  blinit.c:163:29: note: did you mean 'ID_AA64ISAR0_SHA1'?
  blinit.c:162:29: note: 'ID_AA64ISAR0_SHA1' declared here
          arm_sha1_support_ = ID_AA64ISAR0_SHA1(id_aa64isar0) == ID_AA64ISAR0_SHA1_BASE;
                              ^

  PR:		242104
  Reported by:	pkg-fallout
  Submitted by:	Mika?l Urankar

Changes:
  head/security/nss/files/patch-bug1575843
  head/security/nss/files/patch-lib_freebl_blinit.c