Closed stefan-floeren closed 1 year ago
core conan, for not aggregating the sub-component system-libraries
You can open an issue in conan client repo. It's not clear from conan documentaton to know whether it's a bug or not.
From source code, it seems that the canonical conan v2 way to get all system libs of a dependency, regardless of whether it has components or not, is:
self.dependencies["icu"].cpp_info.aggregated_components().system_libs
But it's not documented in https://docs.conan.io/en/latest/reference/conanfile/dependencies.html, and IMHO it's way too confusing for consumers.
@stefan-floeren can you tell me whether https://github.com/conan-io/conan-center-index/pull/14819 fixes your issue?
Description
Since the update for Conan v2 support (https://github.com/conan-io/conan-center-index/commit/c679b7c6f5642fc49b6a2b1cbb9ecf2f05dbf3c6), Boost no longer builds with the ICU backend.
With the simplest
conanfile.txt
:The boost-internal configuration fails to find ICU:
On investigating the culprit, I suspect the change switching from
self.deps_cpp_info["icu"].system_libs
toself.dependencies["icu"].cpp_info.system_libs
.deps_cpp_info
contains['pthread', 'm', 'dl', 'stdc++']
, thedependencies
-entry is empty, although the systemlibs are added to the subcomponents:Same for Windows with
advapi32.lib
vs nothing, with the lib also being mapped toicu-uc
.It seems there is a inconsistency on which lib is expected where and how to use it between v1 and v2.
I'm not sure where this bug actually belongs to:
Package and Environment Details
Conan profile
[settings] os=Linux os_build=Linux arch=x86_64 arch_build=x86_64 compiler=clang compiler.version=11 compiler.libcxx=libstdc++11 build_type=Release [options] [conf] [build_requires] [env]
Steps to reproduce
conan install -u -r conancenter .. --build missing
Logs
Click to expand log
``` Configuration: [settings] arch=x86_64 arch_build=x86_64 build_type=Release compiler=clang compiler.libcxx=libstdc++11 compiler.version=11 os=Linux os_build=Linux [options] [build_requires] [env] icu/72.1: WARN: Can't update, no package in remote boost/1.80.0: WARN: Package binary is corrupted, removing: ffcab2917057cd788768d1cd2861de62394e2516 b2/4.9.2: WARN: Current package is newer than remote upstream one conanfile.txt: Installing package Requirements boost/1.80.0 from 'conancenter' - Cache bzip2/1.0.8 from 'conancenter' - Cache icu/72.1 from 'conancenter' - Cache libbacktrace/cci.20210118 from 'conancenter' - Cache zlib/1.2.13 from 'conancenter' - Cache Packages boost/1.80.0:ffcab2917057cd788768d1cd2861de62394e2516 - Build bzip2/1.0.8:a0279858937b0968952a9784938616e26eb7c2dd - Cache icu/72.1:5a34a782404158bcf48232306a20a330c64df076 - Cache libbacktrace/cci.20210118:d988447fa516eac7400b2f34e2d4b89e42b4b1a8 - Cache zlib/1.2.13:d988447fa516eac7400b2f34e2d4b89e42b4b1a8 - Cache Build requirements b2/4.9.2 from 'conancenter' - Cache Build requirements packages b2/4.9.2:4db1be536558d833e52e862fd84d64d75c2b3656 - Cache Installing (downloading, building) binaries... b2/4.9.2: Already installed! bzip2/1.0.8: Already installed! icu/72.1: Already installed! libbacktrace/cci.20210118: Already installed! zlib/1.2.13: Already installed! boost/1.80.0: Applying build-requirement: b2/4.9.2 boost/1.80.0: WARN: Build folder is dirty, removing it: /home/conan/.conan/data/boost/1.80.0/_/_/build/ffcab2917057cd788768d1cd2861de62394e2516 boost/1.80.0: Building your package in /home/conan/.conan/data/boost/1.80.0/_/_/build/ffcab2917057cd788768d1cd2861de62394e2516 boost/1.80.0: Generator txt created conanbuildinfo.txt boost/1.80.0: Calling generate() boost/1.80.0: Aggregating env generators boost/1.80.0: Calling build() boost/1.80.0: WARN: replace_in_file didn't find pattern '/* thread_local */' in '/home/conan/.conan/data/boost/1.80.0/_/_/source/src/boost/stacktrace/detail/libbacktrace_impls.hpp' file. boost/1.80.0: WARN: replace_in_file didn't find pattern '/* static __thread */' in '/home/conan/.conan/data/boost/1.80.0/_/_/source/src/boost/stacktrace/detail/libbacktrace_impls.hpp' file. boost/1.80.0: WARN: replace_in_file didn't find pattern 'local generic-os = [ set.difference $(all-os) : aix darwin vxworks solaris osf hpux ] ;' in '/home/conan/.conan/data/boost/1.80.0/_/_/source/src/tools/build/src/tools/gcc.jam' file. boost/1.80.0: WARN: replace_in_file didn't find pattern 'local no-threading = android beos haiku sgi darwin vxworks ;' in '/home/conan/.conan/data/boost/1.80.0/_/_/source/src/tools/build/src/tools/gcc.jam' file. boost/1.80.0: WARN: replace_in_file didn't find pattern '