Bug 16346 - Dropping "system" from boost also drops "system" cmake files
Summary: Dropping "system" from boost also drops "system" cmake files
Status: NEW
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: unspecified
Hardware: All Multiple
: Medium+ normal
Target Milestone: 6.1 M3
Assignee: Siva Balasubramanian
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2026-07-03 07:22 UTC by Jens Georg
Modified: 2026-07-09 14:46 UTC (History)
4 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jens Georg 2026-07-03 07:22:43 UTC
Commit 4981f3087a3006e230a182ba87be2301014cc073 drops the system part from BOOST_LIBS, because it is no longer a shared library. This also casues the CMake files for "system" not to be installed anymore and software looking for it explicitly fails and needs to be patched.
Comment 1 Siva Balasubramanian 2026-07-03 10:06:26 UTC
Patch submitted to the openembedded-core mailing list:

[OE-core][PATCH] boost: install CMake config for header-only system library
Message-Id: 20260703095925.265641-1-sivakumar.bs@gmail.com
https://patchwork.yoctoproject.org/project/oe-core/patch/20260703095925.265641-1-sivakumar.bs@gmail.com/

Note that simply re-adding "system" to BOOST_LIBS does not work: in
1.91.0 boost-system became a header-only modular library with no
old-style build, so it can no longer be named in --with-<library> and
b2 aborts the build with:

error: wrong library name 'system' in the --with-<library> option.

Root cause: the recipe's b2 install only ships CMake configs for the
libraries selected via --with-<library>. When "system" was dropped
from BOOST_LIBS in 4981f3087a30, its lib/cmake/boost_system-<ver>/
config stopped being installed, so find_package(Boost COMPONENTS
system) fails downstream. (The same is true for the other header-only
modular libs, but "system" is the one commonly requested as a
component.)

The fix installs the modular libs/system//install target explicitly
from do_install. It is header-only, so no library is built or
packaged — only the CMake config is restored.

Verified with a from-scratch build:


boost_system-config.cmake is packaged into boost-dev again
a real find_package(Boost REQUIRED COMPONENTS system) against the
installed tree now succeeds (Boost_system_FOUND=1), whereas on
current master the config is absent