* [Buildroot] [PATCH] openssl: fix static build
@ 2015-07-07 10:37 Benoît Thébaudeau
2015-07-09 6:53 ` Peter Korsgaard
0 siblings, 1 reply; 2+ messages in thread
From: Benoît Thébaudeau @ 2015-07-07 10:37 UTC (permalink / raw)
To: buildroot
If configured with no-dso, the openssl binary still gets linked with
-ldl, while libdl is not available for static-only builds. The OpenSSL
framework does not support automatically dropping -ldl with no-dso, so
-ldl has to be removed from Makefile after calling ./Configure.
Fixes http://autobuild.buildroot.org/results/cbb35f2582f1cfeb3d11cb4952a80784ff660baf
Signed-off-by: Beno?t Th?baudeau <benoit@wsystem.com>
---
package/openssl/openssl.mk | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/package/openssl/openssl.mk b/package/openssl/openssl.mk
index 4068cf1..37c640d 100644
--- a/package/openssl/openssl.mk
+++ b/package/openssl/openssl.mk
@@ -90,6 +90,14 @@ define OPENSSL_CONFIGURE_CMDS
$(SED) "s: build_tests::" $(@D)/Makefile
endef
+# libdl is not available in a static build, and this is not implied by no-dso
+ifeq ($(BR2_STATIC_LIBS),y)
+define OPENSSL_FIXUP_STATIC_MAKEFILE
+ $(SED) 's/-ldl//g' $(@D)/Makefile
+endef
+OPENSSL_POST_CONFIGURE_HOOKS += OPENSSL_FIXUP_STATIC_MAKEFILE
+endif
+
define HOST_OPENSSL_BUILD_CMDS
$(MAKE1) -C $(@D)
endef
--
2.1.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [Buildroot] [PATCH] openssl: fix static build
2015-07-07 10:37 [Buildroot] [PATCH] openssl: fix static build Benoît Thébaudeau
@ 2015-07-09 6:53 ` Peter Korsgaard
0 siblings, 0 replies; 2+ messages in thread
From: Peter Korsgaard @ 2015-07-09 6:53 UTC (permalink / raw)
To: buildroot
>>>>> "Beno?t" == Beno?t Th?baudeau <benoit@wsystem.com> writes:
> If configured with no-dso, the openssl binary still gets linked with
> -ldl, while libdl is not available for static-only builds. The OpenSSL
> framework does not support automatically dropping -ldl with no-dso, so
> -ldl has to be removed from Makefile after calling ./Configure.
> Fixes http://autobuild.buildroot.org/results/cbb35f2582f1cfeb3d11cb4952a80784ff660baf
> Signed-off-by: Beno?t Th?baudeau <benoit@wsystem.com>
Committed, thanks.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-07-09 6:53 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-07 10:37 [Buildroot] [PATCH] openssl: fix static build Benoît Thébaudeau
2015-07-09 6:53 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox