summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Strogin <steils@gentoo.org>2020-11-02 11:27:49 +0200
committerStefan Strogin <steils@gentoo.org>2020-11-02 11:55:24 +0200
commit4f4eb2c0233265332d3725e4658f5c616936148e (patch)
tree1eb7c5ef8139be8f0650da4c472738c812a6af26 /dev-libs/libressl
parentsys-kernel/pf-sources: bump to 5.9-pf2 (diff)
downloadgentoo-4f4eb2c0233265332d3725e4658f5c616936148e.tar.gz
gentoo-4f4eb2c0233265332d3725e4658f5c616936148e.tar.bz2
gentoo-4f4eb2c0233265332d3725e4658f5c616936148e.zip
dev-libs/libressl: fix building with USE=-static-libs
Closes: https://bugs.gentoo.org/751532 Package-Manager: Portage-3.0.8, Repoman-3.0.2 Signed-off-by: Stefan Strogin <steils@gentoo.org>
Diffstat (limited to 'dev-libs/libressl')
-rw-r--r--dev-libs/libressl/files/libressl-3.2.2-build.patch56
-rw-r--r--dev-libs/libressl/libressl-3.2.2.ebuild1
2 files changed, 57 insertions, 0 deletions
diff --git a/dev-libs/libressl/files/libressl-3.2.2-build.patch b/dev-libs/libressl/files/libressl-3.2.2-build.patch
new file mode 100644
index 000000000000..586e7a7a423a
--- /dev/null
+++ b/dev-libs/libressl/files/libressl-3.2.2-build.patch
@@ -0,0 +1,56 @@
+From 9abd36e3af5876f67c633f27496ad5660ab7fe24 Mon Sep 17 00:00:00 2001
+From: Brent Cook <busterb@gmail.com>
+Date: Sun, 18 Oct 2020 22:14:03 -0500
+Subject: [PATCH] modify nc build to link libcompat objects directly
+
+Rather than assuming the static version of libcrypto exists for pulling in the compatibility functions, link the compat objects directly. This modifies the object file generation script a bit to handle the empty-case properly as well.
+---
+ apps/nc/Makefile.am | 8 ++++++--
+ crypto/Makefile.am | 4 ++--
+ 2 files changed, 8 insertions(+), 4 deletions(-)
+
+diff --git a/apps/nc/Makefile.am b/apps/nc/Makefile.am
+index d678f1eda..58b5c0118 100644
+--- a/apps/nc/Makefile.am
++++ b/apps/nc/Makefile.am
+@@ -1,5 +1,7 @@
+ include $(top_srcdir)/Makefile.am.common
+
++-include $(abs_top_builddir)/crypto/libcrypto_la_objects.mk
++
+ if BUILD_NC
+
+ if ENABLE_NC
+@@ -12,11 +14,13 @@ endif
+ EXTRA_DIST = nc.1
+ EXTRA_DIST += CMakeLists.txt
+
+-nc_LDFLAGS = $(abs_top_builddir)/crypto/.libs/libcrypto.a
+-
+ nc_LDADD = $(abs_top_builddir)/tls/libtls.la
+ nc_LDADD += $(PLATFORM_LDADD) $(PROG_LDADD)
+
++nc_LDADD += $(libcrypto_la_objects)
++nc_LDADD += $(libcompat_la_objects)
++nc_LDADD += $(libcompatnoopt_la_objects)
++
+ AM_CPPFLAGS += -I$(top_srcdir)/apps/nc/compat
+
+ nc_SOURCES = atomicio.c
+diff --git a/crypto/Makefile.am b/crypto/Makefile.am
+index 97a84e1a7..e32ca96c3 100644
+--- a/crypto/Makefile.am
++++ b/crypto/Makefile.am
+@@ -99,10 +99,10 @@ libcrypto_la_objects.mk: Makefile
+ | sed 's/ */ $$\(abs_top_builddir\)\/crypto\//g' \
+ > libcrypto_la_objects.mk
+ @echo "libcompat_la_objects= $(libcompat_la_OBJECTS)" \
+- | sed 's/ */ $$\(abs_top_builddir\)\/crypto\//g' \
++ | sed 's/compat\// $$\(abs_top_builddir\)\/crypto\/&/g' \
+ >> libcrypto_la_objects.mk
+ @echo "libcompatnoopt_la_objects= $(libcompatnoopt_la_OBJECTS)" \
+- | sed 's/ */ $$\(abs_top_builddir\)\/crypto\//g' \
++ | sed 's/compat\// $$\(abs_top_builddir\)\/crypto\/&/g' \
+ >> libcrypto_la_objects.mk
+
+ libcrypto_la_LDFLAGS = -version-info @LIBCRYPTO_VERSION@ -no-undefined -export-symbols crypto_portable.sym
diff --git a/dev-libs/libressl/libressl-3.2.2.ebuild b/dev-libs/libressl/libressl-3.2.2.ebuild
index ab31f2041689..d6e5a198531c 100644
--- a/dev-libs/libressl/libressl-3.2.2.ebuild
+++ b/dev-libs/libressl/libressl-3.2.2.ebuild
@@ -42,6 +42,7 @@ src_prepare() {
fi
eapply "${FILESDIR}"/${PN}-2.8.3-solaris10.patch
+ eapply "${FILESDIR}"/${PN}-3.2.2-build.patch
eapply_user
elibtoolize # for Solaris