* [Buildroot] [PATCH] package/bctoolbox: disable mbedtls support
@ 2025-07-09 21:16 Thomas Petazzoni via buildroot
2025-07-10 8:10 ` Thomas Perale via buildroot
0 siblings, 1 reply; 6+ messages in thread
From: Thomas Petazzoni via buildroot @ 2025-07-09 21:16 UTC (permalink / raw)
To: buildroot; +Cc: Thomas Petazzoni
Since mbedtls was bumped to version 3.6.3.1 in commit
3481a9643fc7223e400ed877f08ade34d44e6b78, the build of bctoolbox fails
as its mbedtls support is not compatible with mbedtls 3.x.
This issue is known upstream:
https://github.com/BelledonneCommunications/bctoolbox/issues/19
and is not fixed, even in newer version of bctoolbox. So for the time
being, simply disable mbedtls support in bctoolbox.
Fixes:
https://autobuild.buildroot.org/results/7af784cb60b0ec5e5bd0e0915ce6827f69f4bb97/
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
---
Note: the bctoolbox has no maintainer in the DEVELOPERS file, and
hasn't been bumped since November 2020, despite upstream having
released multiple versions. Candidate for removal?
---
package/bctoolbox/bctoolbox.mk | 14 ++++++--------
1 file changed, 6 insertions(+), 8 deletions(-)
diff --git a/package/bctoolbox/bctoolbox.mk b/package/bctoolbox/bctoolbox.mk
index ac9361026f..db545311fd 100644
--- a/package/bctoolbox/bctoolbox.mk
+++ b/package/bctoolbox/bctoolbox.mk
@@ -12,25 +12,23 @@ BCTOOLBOX_INSTALL_STAGING = YES
# Set CMAKE_SKIP_RPATH to prevent bctoolbox from adding the rpath to
# shared library.
+
+# We have to disable mbedtls support even though we have a mbedtls
+# package because bctoolbox is not compatible with mbedtls 3.x as of
+# version 4.4.8.
BCTOOLBOX_CONF_OPTS = \
-DENABLE_POLARSSL=OFF \
-DENABLE_STRICT=OFF \
-DENABLE_TESTS_COMPONENT=OFF \
-DENABLE_TESTS=OFF \
- -DCMAKE_SKIP_RPATH=ON
+ -DCMAKE_SKIP_RPATH=ON \
+ -DENABLE_MBEDTLS=OFF
ifeq ($(BR2_PACKAGE_LIBICONV),y)
BCTOOLBOX_DEPENDENCIES += libiconv
BCTOOLBOX_CONF_OPTS += -DCMAKE_CXX_FLAGS="$(TARGET_CXXFLAGS) -liconv"
endif
-ifeq ($(BR2_PACKAGE_MBEDTLS),y)
-BCTOOLBOX_DEPENDENCIES += mbedtls
-BCTOOLBOX_CONF_OPTS += -DENABLE_MBEDTLS=ON
-else
-BCTOOLBOX_CONF_OPTS += -DENABLE_MBEDTLS=OFF
-endif
-
ifeq ($(BR2_STATIC_LIBS),y)
BCTOOLBOX_CONF_OPTS += -DENABLE_SHARED=OFF -DENABLE_STATIC=ON
else ifeq ($(BR2_SHARED_STATIC_LIBS),y)
--
2.49.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [Buildroot] [PATCH] package/bctoolbox: disable mbedtls support
2025-07-09 21:16 [Buildroot] [PATCH] package/bctoolbox: disable mbedtls support Thomas Petazzoni via buildroot
@ 2025-07-10 8:10 ` Thomas Perale via buildroot
2025-07-10 8:28 ` Thomas Petazzoni via buildroot
2025-08-29 21:55 ` Thomas Petazzoni via buildroot
0 siblings, 2 replies; 6+ messages in thread
From: Thomas Perale via buildroot @ 2025-07-10 8:10 UTC (permalink / raw)
To: Thomas Petazzoni; +Cc: Thomas Perale, buildroot
Hi Thomas,
In reply of:
> Since mbedtls was bumped to version 3.6.3.1 in commit
> 3481a9643fc7223e400ed877f08ade34d44e6b78, the build of bctoolbox fails
> as its mbedtls support is not compatible with mbedtls 3.x.
>
> This issue is known upstream:
>
> https://github.com/BelledonneCommunications/bctoolbox/issues/19
>
> and is not fixed, even in newer version of bctoolbox. So for the time
> being, simply disable mbedtls support in bctoolbox.
>
> Fixes:
>
> https://autobuild.buildroot.org/results/7af784cb60b0ec5e5bd0e0915ce6827f69f4bb97/
>
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
They did add support for mbedtls 3.6 in commit [1]. I would prefer to not
deprecate it on the LTS branch so I tried to bump to the latest version but I
get the following error linked to mbedtls:
crypto/mbedtls.cc: In constructor ‘bctoolbox::{anonymous}::mbedtlsStaticContexts::mbedtlsStaticContexts()’:
crypto/mbedtls.cc:83:17: error: ‘mbedtls_threading_set_alt’ was not declared in this scope; did you mean ‘mbedtls_threading_mutex_t’?
83 | mbedtls_threading_set_alt(threading_mutex_init_cpp, threading_mutex_free_cpp, threading_mutex_lock_cpp,
| ^~~~~~~~~~~~~~~~~~~~~~~~~
| mbedtls_threading_mutex_t
crypto/mbedtls.cc: In destructor ‘bctoolbox::{anonymous}::mbedtlsStaticContexts::~mbedtlsStaticContexts()’:
crypto/mbedtls.cc:95:17: error: ‘mbedtls_threading_free_alt’ was not declared in this scope; did you mean ‘mbedtls_threading_mutex_t’?
95 | mbedtls_threading_free_alt();
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
| mbedtls_threading_mutex_t
If anyone could look into this, I would appreciate it. I tried to change the
mbedtls_config.h to enable the ALT threading function but without success.
This package and mongrel2 are the last packages that doesn't have compat with
mbedtls 3.6.
For mongrel2 though the package is not maintained anymore and there isn't any
port upstream.
[1] https://github.com/BelledonneCommunications/bctoolbox/commit/e0ee04a21eb15d6f4a22b2dd1a4599cd3492e5d7
Regards,
Thomas
> ---
> Note: the bctoolbox has no maintainer in the DEVELOPERS file, and
> hasn't been bumped since November 2020, despite upstream having
> released multiple versions. Candidate for removal?
> ---
> package/bctoolbox/bctoolbox.mk | 14 ++++++--------
> 1 file changed, 6 insertions(+), 8 deletions(-)
>
> diff --git a/package/bctoolbox/bctoolbox.mk b/package/bctoolbox/bctoolbox.mk
> index ac9361026f..db545311fd 100644
> --- a/package/bctoolbox/bctoolbox.mk
> +++ b/package/bctoolbox/bctoolbox.mk
> @@ -12,25 +12,23 @@ BCTOOLBOX_INSTALL_STAGING = YES
>
> # Set CMAKE_SKIP_RPATH to prevent bctoolbox from adding the rpath to
> # shared library.
> +
> +# We have to disable mbedtls support even though we have a mbedtls
> +# package because bctoolbox is not compatible with mbedtls 3.x as of
> +# version 4.4.8.
> BCTOOLBOX_CONF_OPTS = \
> -DENABLE_POLARSSL=OFF \
> -DENABLE_STRICT=OFF \
> -DENABLE_TESTS_COMPONENT=OFF \
> -DENABLE_TESTS=OFF \
> - -DCMAKE_SKIP_RPATH=ON
> + -DCMAKE_SKIP_RPATH=ON \
> + -DENABLE_MBEDTLS=OFF
>
> ifeq ($(BR2_PACKAGE_LIBICONV),y)
> BCTOOLBOX_DEPENDENCIES += libiconv
> BCTOOLBOX_CONF_OPTS += -DCMAKE_CXX_FLAGS="$(TARGET_CXXFLAGS) -liconv"
> endif
>
> -ifeq ($(BR2_PACKAGE_MBEDTLS),y)
> -BCTOOLBOX_DEPENDENCIES += mbedtls
> -BCTOOLBOX_CONF_OPTS += -DENABLE_MBEDTLS=ON
> -else
> -BCTOOLBOX_CONF_OPTS += -DENABLE_MBEDTLS=OFF
> -endif
> -
> ifeq ($(BR2_STATIC_LIBS),y)
> BCTOOLBOX_CONF_OPTS += -DENABLE_SHARED=OFF -DENABLE_STATIC=ON
> else ifeq ($(BR2_SHARED_STATIC_LIBS),y)
> --
> 2.49.0
>
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [Buildroot] [PATCH] package/bctoolbox: disable mbedtls support
2025-07-10 8:10 ` Thomas Perale via buildroot
@ 2025-07-10 8:28 ` Thomas Petazzoni via buildroot
2025-08-29 21:55 ` Thomas Petazzoni via buildroot
1 sibling, 0 replies; 6+ messages in thread
From: Thomas Petazzoni via buildroot @ 2025-07-10 8:28 UTC (permalink / raw)
To: Thomas Perale; +Cc: buildroot
Hello,
On Thu, 10 Jul 2025 10:10:58 +0200
Thomas Perale <thomas.perale@mind.be> wrote:
> They did add support for mbedtls 3.6 in commit [1].
Ah, I missed that, thanks for spotting it! I found the issue about
mbedtls 3.x in their bug tracker, and since the issue was open I
assumed it wasn't fixed.
> This package and mongrel2 are the last packages that doesn't have compat with
> mbedtls 3.6.
> For mongrel2 though the package is not maintained anymore and there isn't any
> port upstream.
I have no problem with dropping packages that are unmaintained, either
upstream or in Buildroot. So feel free to drop mongrel2 and even
bctoolbox.
Thomas
--
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Buildroot] [PATCH] package/bctoolbox: disable mbedtls support
2025-07-10 8:10 ` Thomas Perale via buildroot
2025-07-10 8:28 ` Thomas Petazzoni via buildroot
@ 2025-08-29 21:55 ` Thomas Petazzoni via buildroot
2025-08-29 21:59 ` Thomas Petazzoni via buildroot
1 sibling, 1 reply; 6+ messages in thread
From: Thomas Petazzoni via buildroot @ 2025-08-29 21:55 UTC (permalink / raw)
To: Thomas Perale via buildroot; +Cc: Thomas Perale
Hello Thomas,
On Thu, 10 Jul 2025 10:10:58 +0200
Thomas Perale via buildroot <buildroot@buildroot.org> wrote:
> They did add support for mbedtls 3.6 in commit [1]. I would prefer to not
> deprecate it on the LTS branch so I tried to bump to the latest version but I
> get the following error linked to mbedtls:
>
> crypto/mbedtls.cc: In constructor ‘bctoolbox::{anonymous}::mbedtlsStaticContexts::mbedtlsStaticContexts()’:
> crypto/mbedtls.cc:83:17: error: ‘mbedtls_threading_set_alt’ was not declared in this scope; did you mean ‘mbedtls_threading_mutex_t’?
> 83 | mbedtls_threading_set_alt(threading_mutex_init_cpp, threading_mutex_free_cpp, threading_mutex_lock_cpp,
> | ^~~~~~~~~~~~~~~~~~~~~~~~~
> | mbedtls_threading_mutex_t
> crypto/mbedtls.cc: In destructor ‘bctoolbox::{anonymous}::mbedtlsStaticContexts::~mbedtlsStaticContexts()’:
> crypto/mbedtls.cc:95:17: error: ‘mbedtls_threading_free_alt’ was not declared in this scope; did you mean ‘mbedtls_threading_mutex_t’?
> 95 | mbedtls_threading_free_alt();
> | ^~~~~~~~~~~~~~~~~~~~~~~~~~
> | mbedtls_threading_mutex_t
>
> If anyone could look into this, I would appreciate it. I tried to change the
> mbedtls_config.h to enable the ALT threading function but without success.
Nobody stepped up to fix this issue, so I suggest that we apply my
patch disabling MbedTLS support in bctoolbox for the time being. If
someone, one day, needs MbedTLS support in bctoolbox, that someone can
always fix it up.
I'm personally not interested in bctoolbox/C++/MbedTLS debugging, so I
won't investigate this build issue.
Best regards,
Thomas
--
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [Buildroot] [PATCH] package/bctoolbox: disable mbedtls support
2025-08-29 21:55 ` Thomas Petazzoni via buildroot
@ 2025-08-29 21:59 ` Thomas Petazzoni via buildroot
2025-08-30 7:16 ` Thomas Perale via buildroot
0 siblings, 1 reply; 6+ messages in thread
From: Thomas Petazzoni via buildroot @ 2025-08-29 21:59 UTC (permalink / raw)
To: Thomas Perale via buildroot; +Cc: Thomas Perale
On Fri, 29 Aug 2025 23:55:11 +0200
Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote:
> Nobody stepped up to fix this issue, so I suggest that we apply my
> patch disabling MbedTLS support in bctoolbox for the time being. If
> someone, one day, needs MbedTLS support in bctoolbox, that someone can
> always fix it up.
One gotcha though is that crypto support in bctoolbox is needed for
belle-sip, which in turn is needed for linphone.
But oh well, if nobody maintains this stuff, we could also just drop
it. None of bctoolbox, linphone or belle-sip have a maintainer
according to our DEVELOPERS file.
Thomas
--
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [Buildroot] [PATCH] package/bctoolbox: disable mbedtls support
2025-08-29 21:59 ` Thomas Petazzoni via buildroot
@ 2025-08-30 7:16 ` Thomas Perale via buildroot
0 siblings, 0 replies; 6+ messages in thread
From: Thomas Perale via buildroot @ 2025-08-30 7:16 UTC (permalink / raw)
To: Thomas Petazzoni, Thomas Perale via buildroot; +Cc: Fabrice Fontaine
Hi,
Agree.
I'm adding Fabrice Fontaine in CC to the thread as a last hope. He's
listed in the DEVELOPERS entry for 'belr' and 'belle-sip' which depends
on bctoolbox.
PERALE Thomas
On 8/29/25 11:59 PM, Thomas Petazzoni wrote:
> On Fri, 29 Aug 2025 23:55:11 +0200
> Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote:
>
>> Nobody stepped up to fix this issue, so I suggest that we apply my
>> patch disabling MbedTLS support in bctoolbox for the time being. If
>> someone, one day, needs MbedTLS support in bctoolbox, that someone can
>> always fix it up.
> One gotcha though is that crypto support in bctoolbox is needed for
> belle-sip, which in turn is needed for linphone.
>
> But oh well, if nobody maintains this stuff, we could also just drop
> it. None of bctoolbox, linphone or belle-sip have a maintainer
> according to our DEVELOPERS file.
>
> Thomas
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2025-08-30 7:16 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-09 21:16 [Buildroot] [PATCH] package/bctoolbox: disable mbedtls support Thomas Petazzoni via buildroot
2025-07-10 8:10 ` Thomas Perale via buildroot
2025-07-10 8:28 ` Thomas Petazzoni via buildroot
2025-08-29 21:55 ` Thomas Petazzoni via buildroot
2025-08-29 21:59 ` Thomas Petazzoni via buildroot
2025-08-30 7:16 ` Thomas Perale via buildroot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox