[Buildroot] [PATCH v2, 2/2] package/boost: threads needs date-time

Arnout Vandecappelle arnout at mind.be
Mon Nov 22 20:53:18 UTC 2021



On 21/11/2021 20:43, Thomas Petazzoni wrote:
> On Fri, 19 Nov 2021 18:55:53 +0100
> Fabrice Fontaine <fontaine.fabrice at gmail.com> wrote:
> 
>> Fix the following build failure with gcc >= 7 raised since commit
>> 4e267a7d3d5d350710a81ada188a1629348e4b4a because until cmake 3.21.3 and
>> https://github.com/Kitware/CMake/commit/1ad0c5ae53fc0c4f774166337f0e9c93c578cf9b,
>> cmake assumed that boost threads depends on boost date-time. As, we
>> can't patch all cmake in the field, just select boost date-time.
>>
>> -- Found Boost: /home/buildroot/autobuild/instance-3/output-1/host/sh4-buildroot-linux-uclibc/sysroot/usr/include (found version "1.77.0") found components: thread chrono atomic missing components: date_time
>>
>> Fixes:
>>   - http://autobuild.buildroot.org/results/e7443e3bc955e7eddd7bed63e2728880dabb31a7
> 
> So just to work-around a CMake < 3.21.3 bug, we force this select in
> Boost? This doesn't feel like a very good solution :-/
> 
> Even in Buildroot, we're still using CMake 3.16.9.

  So what we could do instead is to bump CMake to 3.22, and set our mininum 
CMake version to 3.21.3. This is going to hurt the build time for some people, 
but I guess it's better than forcing boost date-time?

  On the other hand, boost date-time probably has a very small additional size 
cost compared to the rest of boost, so this patch is probably a better ad hoc 
solution. I'd just add a comment in the Config.in file to explain that this is 
just a workaround, with a longer explanation in the commit message.


  Regards,
  Arnout


More information about the buildroot mailing list