All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/wolfssl: all features needs dynamic library
@ 2022-04-20  8:19 Fabrice Fontaine
  2022-04-23 15:24 ` Arnout Vandecappelle
  2022-05-26  8:20 ` Peter Korsgaard
  0 siblings, 2 replies; 3+ messages in thread
From: Fabrice Fontaine @ 2022-04-20  8:19 UTC (permalink / raw)
  To: buildroot; +Cc: Jianhui Zhao, Sergio Prado, Matt Weber, Fabrice Fontaine

Add dynamic library dependency to BR2_PACKAGE_WOLFSSL_ALL to fix the
following static build failure with ibrdtnd, a "wolfssl all"-enabled
libcurl and openssl:

/nvmedata/autobuild/instance-5/output-1/per-package/ibrdtnd/host/opt/ext-toolchain/bin/../lib/gcc/sh4aeb-buildroot-linux-musl/11.2.0/../../../../sh4aeb-buildroot-linux-musl/bin/ld: /nvmedata/autobuild/instance-5/output-1/per-package/ibrdtnd/host/bin/../sh4aeb-buildroot-linux-musl/sysroot/usr/lib/libssl.a(ssl_ciph.o): in function `SSL_COMP_get_compression_methods':
ssl_ciph.c:(.text+0x25ac): multiple definition of `SSL_COMP_get_compression_methods'; /nvmedata/autobuild/instance-5/output-1/per-package/ibrdtnd/host/sh4aeb-buildroot-linux-musl/sysroot/usr/lib/libwolfssl.a(libwolfssl_la-ssl.o):ssl.c:(.text+0x1ca60): first defined here

Fixes:
 - http://autobuild.buildroot.org/results/be1d327ed4c91a6280a88906a399dfe146f0b64e

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 package/libcurl/Config.in      | 5 +++++
 package/libuhttpd/Config.in    | 3 ++-
 package/libuhttpd/libuhttpd.mk | 2 +-
 package/wolfssl/Config.in      | 4 ++++
 4 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/package/libcurl/Config.in b/package/libcurl/Config.in
index f2ddce6e81..84ad18211a 100644
--- a/package/libcurl/Config.in
+++ b/package/libcurl/Config.in
@@ -78,8 +78,13 @@ config BR2_PACKAGE_LIBCURL_MBEDTLS
 config BR2_PACKAGE_LIBCURL_WOLFSSL
 	bool "WolfSSL"
 	depends on BR2_PACKAGE_WOLFSSL
+	depends on !BR2_STATIC_LIBS # wolfssl-all
 	select BR2_PACKAGE_WOLFSSL_ALL
 
+comment "WolfSSL needs a toolchain w/ dynamic library"
+	depends on BR2_PACKAGE_WOLFSSL
+	depends on BR2_STATIC_LIBS
+
 endchoice
 
 comment "A TLS library is needed for SSL/TLS support"
diff --git a/package/libuhttpd/Config.in b/package/libuhttpd/Config.in
index 97fc984ea0..a552a88f0c 100644
--- a/package/libuhttpd/Config.in
+++ b/package/libuhttpd/Config.in
@@ -3,7 +3,8 @@ config BR2_PACKAGE_LIBUHTTPD
 	depends on BR2_USE_MMU # fork()
 	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
 	select BR2_PACKAGE_LIBEV
-	select BR2_PACKAGE_WOLFSSL_ALL if BR2_PACKAGE_WOLFSSL
+	select BR2_PACKAGE_WOLFSSL_ALL if BR2_PACKAGE_WOLFSSL && \
+		!BR2_STATIC_LIBS
 	help
 	  A lightweight and fully asynchronous HTTP server
 	  library based on libev
diff --git a/package/libuhttpd/libuhttpd.mk b/package/libuhttpd/libuhttpd.mk
index b8cf935d01..0d5306c6dd 100644
--- a/package/libuhttpd/libuhttpd.mk
+++ b/package/libuhttpd/libuhttpd.mk
@@ -18,7 +18,7 @@ LIBUHTTPD_CONF_OPTS += \
 	-DUSE_MBEDTLS=OFF \
 	-DUSE_OPENSSL=ON \
 	-DUSE_WOLFSSL=OFF
-else ifeq ($(BR2_PACKAGE_WOLFSSL),y)
+else ifeq ($(BR2_PACKAGE_WOLFSSL_ALL),y)
 LIBUHTTPD_DEPENDENCIES += wolfssl
 LIBUHTTPD_CONF_OPTS += \
 	-DSSL_SUPPORT=ON \
diff --git a/package/wolfssl/Config.in b/package/wolfssl/Config.in
index 3c6d68f592..3a97125e8d 100644
--- a/package/wolfssl/Config.in
+++ b/package/wolfssl/Config.in
@@ -13,9 +13,13 @@ if BR2_PACKAGE_WOLFSSL
 
 config BR2_PACKAGE_WOLFSSL_ALL
 	bool "enable all features, except SSLv3"
+	depends on !BR2_STATIC_LIBS
 	help
 	  Enable all wolfSSL features, except SSL version 3.0 support.
 
+comment "all features, except SSLv3 needs a toolchain w/ dynamic library"
+	depends on BR2_STATIC_LIBS
+
 config BR2_PACKAGE_WOLFSSL_SSLV3
 	bool "enable SSLv3"
 	help
-- 
2.35.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/wolfssl: all features needs dynamic library
  2022-04-20  8:19 [Buildroot] [PATCH 1/1] package/wolfssl: all features needs dynamic library Fabrice Fontaine
@ 2022-04-23 15:24 ` Arnout Vandecappelle
  2022-05-26  8:20 ` Peter Korsgaard
  1 sibling, 0 replies; 3+ messages in thread
From: Arnout Vandecappelle @ 2022-04-23 15:24 UTC (permalink / raw)
  To: Fabrice Fontaine, buildroot; +Cc: Sergio Prado, Jianhui Zhao, Matt Weber



On 20/04/2022 10:19, Fabrice Fontaine wrote:
> Add dynamic library dependency to BR2_PACKAGE_WOLFSSL_ALL to fix the
> following static build failure with ibrdtnd, a "wolfssl all"-enabled
> libcurl and openssl:
> 
> /nvmedata/autobuild/instance-5/output-1/per-package/ibrdtnd/host/opt/ext-toolchain/bin/../lib/gcc/sh4aeb-buildroot-linux-musl/11.2.0/../../../../sh4aeb-buildroot-linux-musl/bin/ld: /nvmedata/autobuild/instance-5/output-1/per-package/ibrdtnd/host/bin/../sh4aeb-buildroot-linux-musl/sysroot/usr/lib/libssl.a(ssl_ciph.o): in function `SSL_COMP_get_compression_methods':
> ssl_ciph.c:(.text+0x25ac): multiple definition of `SSL_COMP_get_compression_methods'; /nvmedata/autobuild/instance-5/output-1/per-package/ibrdtnd/host/sh4aeb-buildroot-linux-musl/sysroot/usr/lib/libwolfssl.a(libwolfssl_la-ssl.o):ssl.c:(.text+0x1ca60): first defined here
> 
> Fixes:
>   - http://autobuild.buildroot.org/results/be1d327ed4c91a6280a88906a399dfe146f0b64e
> 
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

  Applied to master, thanks.

  Regards,
  Arnout

> ---
>   package/libcurl/Config.in      | 5 +++++
>   package/libuhttpd/Config.in    | 3 ++-
>   package/libuhttpd/libuhttpd.mk | 2 +-
>   package/wolfssl/Config.in      | 4 ++++
>   4 files changed, 12 insertions(+), 2 deletions(-)
> 
> diff --git a/package/libcurl/Config.in b/package/libcurl/Config.in
> index f2ddce6e81..84ad18211a 100644
> --- a/package/libcurl/Config.in
> +++ b/package/libcurl/Config.in
> @@ -78,8 +78,13 @@ config BR2_PACKAGE_LIBCURL_MBEDTLS
>   config BR2_PACKAGE_LIBCURL_WOLFSSL
>   	bool "WolfSSL"
>   	depends on BR2_PACKAGE_WOLFSSL
> +	depends on !BR2_STATIC_LIBS # wolfssl-all
>   	select BR2_PACKAGE_WOLFSSL_ALL
>   
> +comment "WolfSSL needs a toolchain w/ dynamic library"
> +	depends on BR2_PACKAGE_WOLFSSL
> +	depends on BR2_STATIC_LIBS
> +
>   endchoice
>   
>   comment "A TLS library is needed for SSL/TLS support"
> diff --git a/package/libuhttpd/Config.in b/package/libuhttpd/Config.in
> index 97fc984ea0..a552a88f0c 100644
> --- a/package/libuhttpd/Config.in
> +++ b/package/libuhttpd/Config.in
> @@ -3,7 +3,8 @@ config BR2_PACKAGE_LIBUHTTPD
>   	depends on BR2_USE_MMU # fork()
>   	depends on BR2_TOOLCHAIN_GCC_AT_LEAST_4_9
>   	select BR2_PACKAGE_LIBEV
> -	select BR2_PACKAGE_WOLFSSL_ALL if BR2_PACKAGE_WOLFSSL
> +	select BR2_PACKAGE_WOLFSSL_ALL if BR2_PACKAGE_WOLFSSL && \
> +		!BR2_STATIC_LIBS
>   	help
>   	  A lightweight and fully asynchronous HTTP server
>   	  library based on libev
> diff --git a/package/libuhttpd/libuhttpd.mk b/package/libuhttpd/libuhttpd.mk
> index b8cf935d01..0d5306c6dd 100644
> --- a/package/libuhttpd/libuhttpd.mk
> +++ b/package/libuhttpd/libuhttpd.mk
> @@ -18,7 +18,7 @@ LIBUHTTPD_CONF_OPTS += \
>   	-DUSE_MBEDTLS=OFF \
>   	-DUSE_OPENSSL=ON \
>   	-DUSE_WOLFSSL=OFF
> -else ifeq ($(BR2_PACKAGE_WOLFSSL),y)
> +else ifeq ($(BR2_PACKAGE_WOLFSSL_ALL),y)
>   LIBUHTTPD_DEPENDENCIES += wolfssl
>   LIBUHTTPD_CONF_OPTS += \
>   	-DSSL_SUPPORT=ON \
> diff --git a/package/wolfssl/Config.in b/package/wolfssl/Config.in
> index 3c6d68f592..3a97125e8d 100644
> --- a/package/wolfssl/Config.in
> +++ b/package/wolfssl/Config.in
> @@ -13,9 +13,13 @@ if BR2_PACKAGE_WOLFSSL
>   
>   config BR2_PACKAGE_WOLFSSL_ALL
>   	bool "enable all features, except SSLv3"
> +	depends on !BR2_STATIC_LIBS
>   	help
>   	  Enable all wolfSSL features, except SSL version 3.0 support.
>   
> +comment "all features, except SSLv3 needs a toolchain w/ dynamic library"
> +	depends on BR2_STATIC_LIBS
> +
>   config BR2_PACKAGE_WOLFSSL_SSLV3
>   	bool "enable SSLv3"
>   	help
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/wolfssl: all features needs dynamic library
  2022-04-20  8:19 [Buildroot] [PATCH 1/1] package/wolfssl: all features needs dynamic library Fabrice Fontaine
  2022-04-23 15:24 ` Arnout Vandecappelle
@ 2022-05-26  8:20 ` Peter Korsgaard
  1 sibling, 0 replies; 3+ messages in thread
From: Peter Korsgaard @ 2022-05-26  8:20 UTC (permalink / raw)
  To: Fabrice Fontaine; +Cc: Sergio Prado, Jianhui Zhao, Matt Weber, buildroot

>>>>> "Fabrice" == Fabrice Fontaine <fontaine.fabrice@gmail.com> writes:

 > Add dynamic library dependency to BR2_PACKAGE_WOLFSSL_ALL to fix the
 > following static build failure with ibrdtnd, a "wolfssl all"-enabled
 > libcurl and openssl:

 > /nvmedata/autobuild/instance-5/output-1/per-package/ibrdtnd/host/opt/ext-toolchain/bin/../lib/gcc/sh4aeb-buildroot-linux-musl/11.2.0/../../../../sh4aeb-buildroot-linux-musl/bin/ld:
 > /nvmedata/autobuild/instance-5/output-1/per-package/ibrdtnd/host/bin/../sh4aeb-buildroot-linux-musl/sysroot/usr/lib/libssl.a(ssl_ciph.o):
 > in function `SSL_COMP_get_compression_methods':
 > ssl_ciph.c:(.text+0x25ac): multiple definition of
 > `SSL_COMP_get_compression_methods';
 > /nvmedata/autobuild/instance-5/output-1/per-package/ibrdtnd/host/sh4aeb-buildroot-linux-musl/sysroot/usr/lib/libwolfssl.a(libwolfssl_la-ssl.o):ssl.c:(.text+0x1ca60):
 > first defined here

 > Fixes:
 >  - http://autobuild.buildroot.org/results/be1d327ed4c91a6280a88906a399dfe146f0b64e

 > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

Committed to 2022.02.x, thanks.

-- 
Bye, Peter Korsgaard
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-05-26  8:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-20  8:19 [Buildroot] [PATCH 1/1] package/wolfssl: all features needs dynamic library Fabrice Fontaine
2022-04-23 15:24 ` Arnout Vandecappelle
2022-05-26  8:20 ` Peter Korsgaard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.