Module Name: src Committed By: maya Date: Tue Nov 20 07:30:18 UTC 2018
Modified Files: src/crypto/external/bsd/openssl/dist/crypto: armcap.c ppccap.c Log Message: Don't expose a getauxval symbol. The code already knows how to handle it, but it assumes anyone who uses GCC or clang might resolve the getauxval function to something eventually. The only time we will expose getauxval is if a package tries to substitute getauxval too, and then code will start having mysterious failures. getauxval is purely a linux function (as far as I can see), so limit it to that. PR pkg/53387, PR port-arm/53386 To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.8 src/crypto/external/bsd/openssl/dist/crypto/armcap.c cvs rdiff -u -r1.8 -r1.9 src/crypto/external/bsd/openssl/dist/crypto/ppccap.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/crypto/external/bsd/openssl/dist/crypto/armcap.c diff -u src/crypto/external/bsd/openssl/dist/crypto/armcap.c:1.7 src/crypto/external/bsd/openssl/dist/crypto/armcap.c:1.8 --- src/crypto/external/bsd/openssl/dist/crypto/armcap.c:1.7 Sun Sep 23 13:32:55 2018 +++ src/crypto/external/bsd/openssl/dist/crypto/armcap.c Tue Nov 20 07:30:17 2018 @@ -70,7 +70,7 @@ void OPENSSL_cpuid_setup(void) __attribu * Use a weak reference to getauxval() so we can use it if it is available but * don't break the build if it is not. */ -# if defined(__GNUC__) && __GNUC__>=2 && defined(__ELF__) +# if defined(__linux__) extern unsigned long getauxval(unsigned long type) __attribute__ ((weak)); # else static unsigned long (*getauxval) (unsigned long) = NULL; Index: src/crypto/external/bsd/openssl/dist/crypto/ppccap.c diff -u src/crypto/external/bsd/openssl/dist/crypto/ppccap.c:1.8 src/crypto/external/bsd/openssl/dist/crypto/ppccap.c:1.9 --- src/crypto/external/bsd/openssl/dist/crypto/ppccap.c:1.8 Sun Sep 23 13:32:55 2018 +++ src/crypto/external/bsd/openssl/dist/crypto/ppccap.c Tue Nov 20 07:30:17 2018 @@ -178,7 +178,7 @@ void OPENSSL_madd300_probe(void); * feature detection, not *run-time*. In other words if we link with * symbol present, it's expected to be present even at run-time. */ -#if defined(__GNUC__) && __GNUC__>=2 && defined(__ELF__) +#if defined(__linux__) extern unsigned long getauxval(unsigned long type) __attribute__ ((weak)); #else static unsigned long (*getauxval) (unsigned long) = NULL;