Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building boost to web assembly fails #329

Open
3 tasks done
bruno-j-nicoletti opened this issue Sep 1, 2023 · 1 comment
Open
3 tasks done

Building boost to web assembly fails #329

bruno-j-nicoletti opened this issue Sep 1, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@bruno-j-nicoletti
Copy link

bruno-j-nicoletti commented Sep 1, 2023

Make sure you completed the following tasks

Environment and version details

  • Operating System+version: MacOS 12.6.7 (reproducible on Linux as well), building to emsdk/3.1.44
  • Compiler+version: emcc
  • Shell: bash
  • B2 Version: B2 4.9-git
  • B2 Configuration: NA
NA

Brief problem description

When attempting to build boost libraries via conan to webassembly, boost fails to build with the following message...

Error: ambiguity found when searching for best transformation
Trying to produce type 'SEARCHED_LIB' from: 
Generators that succeeded:
 -  searched-lib-generator
 -  emscripten.searched-lib-generator
First generator produced: 
 -  { %.no-action-z.SEARCHED_LIB }
Second generator produced: 
 -  { %.no-action-z.SEARCHED_LIB }

The issue can be fixed by patching the b2 jamfile src/tools/emscripten.jam that boost 1.83.0 depends on as follows....

9d8
< import generators ;
55,57d53
< generators.override builtin.lib-generator : emscripten.prebuilt ;
< generators.override emscripten.searched-lib-generator : searched-lib-generator ;
<

That patch can't be applied to src/tools/emscripten.jam as the file on the main branch has moved on.

Steps to reproduce the issue

With conan2 installed, and the following conanfile.py...

from conan import ConanFile

class BorkingBoostBuildConan(ConanFile):
    name = "BNS"
    version = "0.0.1"
    settings = "os", "compiler", "build_type", "arch"
    generators = "CMakeToolchain", "CMakeDeps"

    def requirements(self) :
        self.requires("boost/1.83.0")

The following file ./emsdkProfile

settings]
arch=wasm
compiler=clang
compiler.cppstd=23
compiler.libcxx=libc++
compiler.version=16
os=Emscripten
build_type=Debug

[tool_requires]
*: emsdk/3.1.44

[conf]
tools.build:cxxflags=["-fwasm-exceptions", "-pthread"]

[buildenv]
LDFLAGS="-fwasm-exceptions", "-pthread", "-s PROXY_TO_PTHREAD", "-sALLOW_MEMORY_GROWTH"

and the following file macosRelease

os=Macos
arch=x86_64
compiler=apple-clang
compiler.version=14
compiler.cppstd=17
compiler.libcxx=libc++

the command...

conan install --output-folder=build --build=missing -pr:b ./macosRelease -pr:h ./emsdkProfile ./conanfile.py -o boost/\*:with_stacktrace_backtrace=False

results in the following output...

======== Input profiles ========
Profile host:
[settings]
arch=wasm
build_type=Debug
compiler=clang
compiler.cppstd=23
compiler.libcxx=libc++
compiler.version=16
os=Emscripten
[options]
boost/*:with_stacktrace_backtrace=False
[tool_requires]
*: emsdk/3.1.44
[conf]
tools.build:cxxflags=['-fwasm-exceptions', '-pthread']
[buildenv]
LDFLAGS="-fwasm-exceptions", "-pthread", "-s PROXY_TO_PTHREAD", "-sALLOW_MEMORY_GROWTH"

Profile build:
[settings]
arch=x86_64
build_type=Release
compiler=apple-clang
compiler.cppstd=17
compiler.libcxx=libc++
compiler.version=14
os=Macos


======== Computing dependency graph ========
boost/1.83.0: Not found in local cache, looking in remotes...
boost/1.83.0: Checking remote: conancenter
boost/1.83.0: Downloaded recipe revision 8be129e9ab6e00b3d74810626cdbea9c
Graph root
    conanfile.py (BNS/0.0.1): /Users/bruno/Work/boostHell/conanfile.py
Requirements
    boost/1.83.0#8be129e9ab6e00b3d74810626cdbea9c - Downloaded (conancenter)
    bzip2/1.0.8#411fc05e80d47a89045edc1ee6f23c1d - Cache
    zlib/1.2.13#e377bee636333ae348d51ca90874e353 - Cache
Build requirements
    b2/4.9.6#53783bdbbdbb6c13732b25f1f6ea6c58 - Cache
    emsdk/3.1.44#a6d941a26a1c416d25e3505805703a58 - Cache
    nodejs/16.3.0#fbb644235845086644bebd53e452595b - Cache

======== Computing necessary packages ========
boost/1.83.0: Checking 9 compatible configurations:
boost/1.83.0: '8ccee61c8b07220fbe5a5fe74c8fdd6ec574193c': compiler.cppstd=11
boost/1.83.0: 'a3ec0237a73d4381ea6d8f5d310312c8472605be': compiler.cppstd=gnu11
boost/1.83.0: '9a14321c477848010eaa8836bc2fa137e41157bd': compiler.cppstd=14
boost/1.83.0: '32a6f7ecb44b2c50fdf25e2885ef3924125749ca': compiler.cppstd=gnu14
boost/1.83.0: '51e93e6472834c7b40fed494ecae8a37f4cc58c8': compiler.cppstd=17
boost/1.83.0: 'e90c8db2bb1ba4b86fba99ea6a9829bc29ace775': compiler.cppstd=gnu17
boost/1.83.0: '40b8a4ed65a40d9ee6e119cf4858e306fd7c96c7': compiler.cppstd=20
boost/1.83.0: '7240f756ad186990dabe01380fea1b68d3c1588c': compiler.cppstd=gnu20
boost/1.83.0: 'c8188ef9f0ca923334a404e7bce08a82ac81e945': compiler.cppstd=gnu23
Requirements
    boost/1.83.0#8be129e9ab6e00b3d74810626cdbea9c:aaaec01a32da69642eb212b65576d882d068e126 - Build
    bzip2/1.0.8#411fc05e80d47a89045edc1ee6f23c1d:6d96f99e9965a4797bd36a3301a7da9699f8681c#0492a23ca06d25192089e02bdba7c31a - Cache
    zlib/1.2.13#e377bee636333ae348d51ca90874e353:e3fac8d3f9347da32209118b429e89851f8a417d#51e5027420bc1deea4d32449691dbf65 - Cache
Build requirements
    b2/4.9.6#53783bdbbdbb6c13732b25f1f6ea6c58:82339cc4d6db7990c1830d274cd12e7c91ab18a1#f375c196e601fb716b2bd5018c871c78 - Cache
    emsdk/3.1.44#a6d941a26a1c416d25e3505805703a58:82339cc4d6db7990c1830d274cd12e7c91ab18a1#8dbf4ab5c71e04b6ea14e90c5640f80f - Cache
    nodejs/16.3.0#fbb644235845086644bebd53e452595b:82339cc4d6db7990c1830d274cd12e7c91ab18a1#d0751e90bacaaf8eed3c0c2b10bd05eb - Cache

======== Installing packages ========
b2/4.9.6: Already installed! (1 of 6)
nodejs/16.3.0: Already installed! (2 of 6)
nodejs/16.3.0: Appending PATH environment variable: /Users/bruno/.conan2/p/nodejf10c1d8c12c70/p/bin
nodejs/16.3.0: Appending PATH environment variable: /Users/bruno/.conan2/p/nodejf10c1d8c12c70/p/bin
bzip2/1.0.8: Already installed! (3 of 6)
zlib/1.2.13: Already installed! (4 of 6)
emsdk/3.1.44: Already installed! (5 of 6)
boost/1.83.0: Sources downloaded from 'conancenter'
boost/1.83.0: Calling source() in /Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src
boost/1.83.0: Downloading 122.9MB boost_1_83_0.tar.bz2
boost/1.83.0: Downloaded 85.7MB 69% boost_1_83_0.tar.bz2
boost/1.83.0: Apply patch (conan): Optional flag to specify iconv from either libc of libiconv

-------- Installing package boost/1.83.0 (6 of 6) --------
boost/1.83.0: Building from source
boost/1.83.0: Package boost/1.83.0:aaaec01a32da69642eb212b65576d882d068e126
boost/1.83.0: Building your package in /Users/bruno/.conan2/p/b/boost8525b86d413ba/b
boost/1.83.0: Calling generate()
boost/1.83.0: Generators folder: /Users/bruno/.conan2/p/b/boost8525b86d413ba/b/build-debug/conan
boost/1.83.0: Generating aggregated env files
boost/1.83.0: Generated aggregated env files: ['conanbuild.sh', 'conanrun.sh']
boost/1.83.0: Calling build()
boost/1.83.0: WARN: replace_in_file didn't find pattern '/* thread_local */' in '/Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src/boost/stacktrace/detail/libbacktrace_impls.hpp' file.
boost/1.83.0: WARN: replace_in_file didn't find pattern '/* static __thread */' in '/Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src/boost/stacktrace/detail/libbacktrace_impls.hpp' file.
boost/1.83.0: WARN: replace_in_file didn't find pattern 'local generic-os = [ set.difference $(all-os) : aix darwin vxworks solaris osf hpux ] ;' in '/Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src/tools/build/src/tools/gcc.jam' file.
boost/1.83.0: WARN: replace_in_file didn't find pattern 'local no-threading = android beos haiku sgi darwin vxworks ;' in '/Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src/tools/build/src/tools/gcc.jam' file.
boost/1.83.0: WARN: Patching user-config.jam
boost/1.83.0: WARN: 
using zlib : 1.2.13 : <include>"/Users/bruno/.conan2/p/b/zlib92366dd24ff76/p/include" <search>"/Users/bruno/.conan2/p/b/zlib92366dd24ff76/p/lib" <name>z ;
using bzip2 : 1.0.8 : <include>"/Users/bruno/.conan2/p/b/bzip2e5e0f698f6100/p/include" <search>"/Users/bruno/.conan2/p/b/bzip2e5e0f698f6100/p/lib" <name>bz2 ;
using "emscripten" :  :  "/Users/bruno/.conan2/p/b/emsdk8fd9873fdac27/p/bin/upstream/emscripten/em++" : 
<archiver>"/Users/bruno/.conan2/p/b/emsdk8fd9873fdac27/p/bin/upstream/emscripten/emar" <ranlib>"/Users/bruno/.conan2/p/b/emsdk8fd9873fdac27/p/bin/upstream/emscripten/emranlib" <cxxflags>"-fwasm-exceptions -pthread"  ;
boost/1.83.0: Cross building, detecting compiler...
boost/1.83.0: Cross building flags: []
boost/1.83.0: WARN: b2 -q numa=on address-model=32 --layout=system --user-config=/Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src/tools/build/user-config.jam -sNO_ZLIB=0 -sNO_BZIP2=0 -sNO_LZMA=1 -sNO_ZSTD=1 boost.locale.icu=off --disable-icu boost.locale.iconv=on boost.locale.iconv.lib=libc threading=multi visibility=hidden link=static variant=debug --with-atomic --with-chrono --with-container --with-context --with-contract --with-coroutine --with-date_time --with-exception --with-fiber --with-filesystem --with-graph --with-iostreams --with-json --with-locale --with-log --with-math --with-nowide --with-program_options --with-random --with-regex --with-serialization --with-stacktrace --with-system --with-test --with-thread --with-timer --with-type_erasure --with-url --with-wave toolset=emscripten cxxflags=-std=c++2b pch=on linkflags="" cxxflags="-fPIC -DBOOST_STACKTRACE_ADDR2LINE_LOCATION=/usr/bin/addr2line" install --prefix=/Users/bruno/.conan2/p/b/boost8525b86d413ba/p -j16 --abbreviate-paths -d0 --debug-configuration --build-dir="/Users/bruno/.conan2/p/b/boost8525b86d413ba/b/build-debug"
boost/1.83.0: RUN: b2 -q numa=on address-model=32 --layout=system --user-config=/Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src/tools/build/user-config.jam -sNO_ZLIB=0 -sNO_BZIP2=0 -sNO_LZMA=1 -sNO_ZSTD=1 boost.locale.icu=off --disable-icu boost.locale.iconv=on boost.locale.iconv.lib=libc threading=multi visibility=hidden link=static variant=debug --with-atomic --with-chrono --with-container --with-context --with-contract --with-coroutine --with-date_time --with-exception --with-fiber --with-filesystem --with-graph --with-iostreams --with-json --with-locale --with-log --with-math --with-nowide --with-program_options --with-random --with-regex --with-serialization --with-stacktrace --with-system --with-test --with-thread --with-timer --with-type_erasure --with-url --with-wave toolset=emscripten cxxflags=-std=c++2b pch=on linkflags="" cxxflags="-fPIC -DBOOST_STACKTRACE_ADDR2LINE_LOCATION=/usr/bin/addr2line" install --prefix=/Users/bruno/.conan2/p/b/boost8525b86d413ba/p -j16 --abbreviate-paths -d0 --debug-configuration --build-dir="/Users/bruno/.conan2/p/b/boost8525b86d413ba/b/build-debug"
notice: found boost-build.jam at /Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src/boost-build.jam
notice: loading B2 from /Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/kernel/bootstrap.jam
notice: Searching '/etc' '/Users/bruno' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/kernel' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/util' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/build' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/tools' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/contrib' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/.' for site-config configuration file 'site-config.jam'.
notice: Configuration file 'site-config.jam' not found in '/etc' '/Users/bruno' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/kernel' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/util' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/build' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/tools' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/contrib' '/Users/bruno/.conan2/p/b24bd1c02e3b59e/p/bin/.b2/.'.
notice: Loading explicitly specified user configuration file:
    /Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src/tools/build/user-config.jam
notice: Searching '/Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src/tools/build' for user-config configuration file 'user-config.jam'.
notice: Loading user-config configuration file 'user-config.jam' from '/Users/bruno/.conan2/p/boostf43c9e9f0bf53/s/src/tools/build'.
notice: [zlib] Using pre-installed library
notice: [zlib] Condition
notice: [bzip2] Using pre-installed library
notice: [bzip2] Condition
notice: will use '/Users/bruno/.conan2/p/b/emsdk8fd9873fdac27/p/bin/upstream/emscripten/em++' for emscripten, condition <toolset>emscripten-3.1.44
notice: [zlib] zlib is already configured
notice: [bzip2] bzip is already configured
notice: iostreams: not using lzma compression 
notice: iostreams: not using zstd compression 
notice: [python-cfg] Configuring python...
notice: [python-cfg] Checking interpreter command "python"...
notice: [python-cfg] running command 'python -c "from sys import *; print('version=%d.%d\nplatform=%s\nprefix=%s\nexec_prefix=%s\nexecutable=%s' % (version_info[0],version_info[1],platform,prefix,exec_prefix,executable))" 2>&1'
notice: [python-cfg] ...requested configuration matched!
notice: [python-cfg] Details of this Python configuration:
notice: [python-cfg]   interpreter command: "python"
notice: [python-cfg]   include path: "/Users/bruno/venv3_11/include/python3.11"
notice: [python-cfg]   library path: "/Users/bruno/venv3_11/lib/python3.11/config" "/Users/bruno/venv3_11/lib"
notice: [python-cfg] Checking for NumPy...
notice: [python-cfg] running command 'python -c "import sys; sys.stderr = sys.stdout; import numpy; print(numpy.get_include())"'
notice: [python-cfg] NumPy enabled
notice: [python-cfg] no framework directory found; using library path
Performing configuration checks

    - default address-model    : 32-bit [1]
    - default architecture     : none [1]
    - x86                      : no [2]
    - arm                      : no [2]
    - mips1                    : no [2]
    - power                    : no [2]
    - sparc                    : no [2]
error: No best alternative for libs/context/build/asm_sources with <abi>sysv <address-model>32 <asynch-exceptions>off <binary-format>mach-o <boost.locale.iconv.lib>libc <boost.locale.iconv>on <boost.locale.icu>off <closure>off <context-impl>fcontext <coverage>off <debug-symbols>on <deduced-address-model>32 <embind>off <exception-handling>on <extern-c-nothrow>off <inlining>off <link-optimization>off <link>static <numa>on <optimization>off <os>MACOSX <pch>on <preserve-test-targets>on <profiling>off <python-debugging>off <python>3.11 <relevant>abi <relevant>address-model <relevant>architecture <relevant>binary-format <relevant>toolset <rtti>on <runtime-debugging>on <runtime-link>shared <stdlib>native <strip>off <target-os>darwin <testing.execute>on <threadapi>pthread <threading>multi <toolset-emscripten:version>3.1.44 <toolset>emscripten <variant>debug <vectorize>off <visibility>hidden <warnings-as-errors>off <warnings>on
    no match: <abi>aapcs <address-model>32 <architecture>arm <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>aapcs <address-model>32 <architecture>arm <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>aapcs <address-model>32 <architecture>arm <binary-format>elf <threading>multi <toolset>qcc
    no match: <abi>aapcs <address-model>32 <architecture>arm <binary-format>mach-o <threading>multi <toolset>clang
    no match: <abi>aapcs <address-model>32 <architecture>arm <binary-format>mach-o <threading>multi <toolset>darwin
    no match: <abi>aapcs <address-model>32 <architecture>arm <binary-format>pe <threading>multi <toolset>msvc
    no match: <abi>aapcs <address-model>64 <architecture>arm <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>aapcs <address-model>64 <architecture>arm <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>aapcs <address-model>64 <architecture>arm <binary-format>mach-o <threading>multi <toolset>clang
    no match: <abi>aapcs <address-model>64 <architecture>arm <binary-format>mach-o <threading>multi <toolset>darwin
    no match: <abi>aapcs <address-model>64 <architecture>arm <binary-format>pe <threading>multi <toolset>msvc
    no match: <abi>sysv <address-model>64 <architecture>loongarch <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>o32 <address-model>32 <architecture>mips <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>o32 <address-model>32 <architecture>mips <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>n64 <address-model>64 <architecture>mips <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>n64 <address-model>64 <architecture>mips <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>32 <architecture>power <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>32 <architecture>power <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>32 <architecture>power <binary-format>mach-o <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>32 <architecture>power <binary-format>mach-o <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>32 <architecture>power <binary-format>mach-o <threading>multi <toolset>darwin
    no match: <abi>sysv <address-model>32 <architecture>power <binary-format>xcoff <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>32 <architecture>power <binary-format>xcoff <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>64 <architecture>power <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>64 <architecture>power <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>64 <architecture>power <binary-format>mach-o <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>64 <architecture>power <binary-format>mach-o <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>64 <architecture>power <binary-format>mach-o <threading>multi <toolset>darwin
    no match: <abi>sysv <address-model>64 <architecture>power <binary-format>xcoff <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>64 <architecture>power <binary-format>xcoff <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>32_64 <architecture>power <binary-format>mach-o <threading>multi
    no match: <abi>sysv <address-model>64 <architecture>riscv <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>64 <architecture>riscv <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>64 <architecture>s390x <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>64 <architecture>s390x <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>32 <architecture>x86 <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>32 <architecture>x86 <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>32 <architecture>x86 <binary-format>elf <threading>multi <toolset>intel
    no match: <abi>sysv <address-model>32 <architecture>x86 <binary-format>mach-o <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>32 <architecture>x86 <binary-format>mach-o <threading>multi <toolset>darwin
    no match: <abi>ms <address-model>32 <architecture>x86 <binary-format>pe <threading>multi <toolset>clang
    no match: <abi>ms <address-model>32 <architecture>x86 <binary-format>pe <threading>multi <toolset>clang-win
    no match: <abi>ms <address-model>32 <architecture>x86 <binary-format>pe <threading>multi <toolset>gcc
    no match: <abi>ms <address-model>32 <architecture>x86 <binary-format>pe <threading>multi <toolset>intel
    no match: <abi>ms <address-model>32 <architecture>x86 <binary-format>pe <threading>multi <toolset>msvc
    no match: <abi>ms <address-model>32 <architecture>x86 <binary-format>pe <threading>multi <toolset>embarcadero
    no match: <abi>ms <address-model>32 <architecture>x86 <binary-format>pe <threading>multi <toolset>borland
    no match: <abi>sysv <address-model>64 <architecture>x86 <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>64 <architecture>x86 <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>64 <architecture>x86 <binary-format>elf <threading>multi <toolset>intel
    no match: <abi>sysv <address-model>64 <architecture>x86 <binary-format>mach-o <threading>multi <toolset>clang
    no match: <abi>sysv <address-model>64 <architecture>x86 <binary-format>mach-o <threading>multi <toolset>gcc
    no match: <abi>sysv <address-model>64 <architecture>x86 <binary-format>mach-o <threading>multi <toolset>darwin
    no match: <abi>sysv <address-model>64 <architecture>x86 <binary-format>mach-o <threading>multi <toolset>intel
    no match: <abi>ms <address-model>64 <architecture>x86 <binary-format>pe <threading>multi <toolset>clang
    no match: <abi>ms <address-model>64 <architecture>x86 <binary-format>pe <threading>multi <toolset>clang-win
    no match: <abi>ms <address-model>64 <architecture>x86 <binary-format>pe <threading>multi <toolset>gcc
    no match: <abi>ms <address-model>64 <architecture>x86 <binary-format>pe <threading>multi <toolset>intel
    no match: <abi>ms <address-model>64 <architecture>x86 <binary-format>pe <threading>multi <toolset>msvc
    no match: <abi>ms <address-model>64 <architecture>x86 <binary-format>pe <threading>multi <toolset>embarcadero
    no match: <abi>x32 <address-model>32 <architecture>x86 <binary-format>elf <threading>multi <toolset>clang
    no match: <abi>x32 <address-model>32 <architecture>x86 <binary-format>elf <threading>multi <toolset>gcc
    no match: <abi>x32 <address-model>32 <architecture>x86 <binary-format>elf <threading>multi <toolset>intel
    no match: <abi>sysv <address-model>32_64 <architecture>x86 <binary-format>mach-o <threading>multi
    no match: <abi>sysv <architecture>arm+x86 <binary-format>mach-o <threading>multi
    - has std::atomic_ref      : no [2]
    - has statx                : no [2]
    - has statx syscall        : no [2]
    - has init_priority attribute : yes [2]
    - has stat::st_blksize     : yes [2]
    - has stat::st_mtim        : yes [2]
    - has stat::st_mtimensec   : no [2]
    - has stat::st_mtimespec   : no [2]
    - has stat::st_birthtim    : no [2]
    - has stat::st_birthtimensec : no [2]
    - has stat::st_birthtimespec : no [2]
    - has fdopendir(O_NOFOLLOW) : yes [2]
    - has dirent::d_type       : yes [2]
    - has POSIX *at APIs       : yes [2]
    - cxx11_auto_declarations  : yes [2]
    - cxx11_constexpr          : yes [2]
    - cxx11_defaulted_functions : yes [2]
    - cxx11_final              : yes [2]
    - cxx11_hdr_mutex          : yes [2]
    - cxx11_hdr_tuple          : yes [2]
    - cxx11_lambdas            : yes [2]
    - cxx11_noexcept           : yes [2]
    - cxx11_nullptr            : yes [2]
    - cxx11_rvalue_references  : yes [2]
    - cxx11_template_aliases   : yes [2]
    - cxx11_thread_local       : yes [2]
    - cxx11_variadic_templates : yes [2]
    - has_icu builds           : no [2]
Error: ambiguity found when searching for best transformation
Trying to produce type 'SEARCHED_LIB' from: 
Generators that succeeded:
 -  searched-lib-generator
 -  emscripten.searched-lib-generator
First generator produced: 
 -  { %.no-action-z.SEARCHED_LIB }
Second generator produced: 
 -  { %.no-action-z.SEARCHED_LIB }


boost/1.83.0: ERROR: 
Package 'aaaec01a32da69642eb212b65576d882d068e126' build failed
boost/1.83.0: WARN: Build folder /Users/bruno/.conan2/p/b/boost8525b86d413ba/b/build-debug
*********************************************************
Recipe 'boost/1.83.0' cannot build its binary
It is possible that this recipe is not Conan 2.0 ready
If the recipe comes from ConanCenter check: https://conan.io/cci-v2.html
If it is your recipe, check if it is updated to 2.0
*********************************************************

ERROR: boost/1.83.0: Error in build() method, line 887
	self.run(full_command)
	ConanException: Error 1 while executing

Actual behavior summary

Boost fails to build vai conan when compiling to webassembly.

Attach, or place here, log output showing the bug including running
with the options: -d2 --debug-configuration

Expected behavior summary

It should build to web assembly and not fail.

@bruno-j-nicoletti bruno-j-nicoletti added the bug Something isn't working label Sep 1, 2023
@Kojoley
Copy link
Contributor

Kojoley commented Mar 24, 2024

Error: ambiguity found when searching for best transformation
Trying to produce type 'SEARCHED_LIB' from: 
Generators that succeeded:
 -  searched-lib-generator
 -  emscripten.searched-lib-generator
First generator produced: 
 -  { %.no-action-z.SEARCHED_LIB }
Second generator produced: 
 -  { %.no-action-z.SEARCHED_LIB }

The issue can be fixed by patching the b2 jamfile src/tools/emscripten.jam that boost 1.83.0 depends on as follows....

This has been fixed in #225 and emscripten support overhaul happened in #310

error: No best alternative for libs/context/build/asm_sources with sysv 32 off mach-o <boost.locale.iconv.lib>libc <boost.locale.iconv>on <boost.locale.icu>off off fcontext off on 32 off on off off off static on off MACOSX on on off off 3.11 abi address-model architecture binary-format toolset on on shared native off darwin <testing.execute>on pthread multi toolset-emscripten:version3.1.44 emscripten debug off hidden off on

It's not a b2 issue. AFAIK emscripten is not supported by Boost.Context, file an issue there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants