pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/security/openssl Fix c++17 and openssl on solaris/illumos



details:   https://anonhg.NetBSD.org/pkgsrc/rev/99bdbf360e36
branches:  trunk
changeset: 450820:99bdbf360e36
user:      nros <nros%pkgsrc.org@localhost>
date:      Thu Apr 22 09:32:39 2021 +0000

description:
Fix c++17 and openssl on solaris/illumos

gcc on solaris/illumos defines __STDC_VERSION__ in c++ mode where _Noreturn
does not exist.
This causes breakage when building c++17 programs that use openssl.

diffstat:

 security/openssl/distinfo                               |   3 +-
 security/openssl/patches/patch-include_openssl_e__os2.h |  19 +++++++++++++++++
 2 files changed, 21 insertions(+), 1 deletions(-)

diffs (37 lines):

diff -r 66add751b278 -r 99bdbf360e36 security/openssl/distinfo
--- a/security/openssl/distinfo Thu Apr 22 09:23:58 2021 +0000
+++ b/security/openssl/distinfo Thu Apr 22 09:32:39 2021 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.149 2021/03/25 16:36:19 jperkin Exp $
+$NetBSD: distinfo,v 1.150 2021/04/22 09:32:39 nros Exp $
 
 SHA1 (openssl-1.1.1k.tar.gz) = bad9dc4ae6dcc1855085463099b5dacb0ec6130b
 RMD160 (openssl-1.1.1k.tar.gz) = 5c9fbbeae7d115e59be705162e58195517a37cae
@@ -7,3 +7,4 @@
 SHA1 (patch-Configurations_shared-info.pl) = 0e835f6e343b5d05ef9a0e6ef2a195201262d15c
 SHA1 (patch-Configurations_unix-Makefile.tmpl) = cf6b46c6e10e84100beb468bbe6f85c5e62cbe7a
 SHA1 (patch-Configure) = 479f1bc826f7721f6b44d6b5a6cf460432924bf2
+SHA1 (patch-include_openssl_e__os2.h) = d2f08d50fe44da37c6399665c09abe0e1f06429b
diff -r 66add751b278 -r 99bdbf360e36 security/openssl/patches/patch-include_openssl_e__os2.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/security/openssl/patches/patch-include_openssl_e__os2.h   Thu Apr 22 09:32:39 2021 +0000
@@ -0,0 +1,19 @@
+$NetBSD: patch-include_openssl_e__os2.h,v 1.1 2021/04/22 09:32:40 nros Exp $
+
+* gcc on Solaris/lllumos defines __STDC_VERSION__ in c++ mode where _Noreturn
+  does not exist, this breaks c++17 builds that use openssl.
+
+  filed upstream: https://github.com/openssl/openssl/pull/14944
+
+--- include/openssl/e_os2.h.orig       2021-04-22 08:37:49.922502161 +0000
++++ include/openssl/e_os2.h
+@@ -279,7 +279,8 @@ typedef unsigned __int64 uint64_t;
+ #  define ossl_inline inline
+ # endif
+ 
+-# if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L
++# if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L && \
++     !defined(__cplusplus)
+ #  define ossl_noreturn _Noreturn
+ # elif defined(__GNUC__) && __GNUC__ >= 2
+ #  define ossl_noreturn __attribute__((noreturn))



Home | Main Index | Thread Index | Old Index