I am building boost, and in particular boost-python, for emscripten. My detailed setup is given below. When I run b2, it is clear that the address-model is correctly detected:
Performing configuration checks
- default address-model : 32-bit (cached) [1]
- default architecture : none (cached) [1]
[1] clang-emscripten
However, in the installed cmake config files, I see this:
# Generated by Boost 1.90.0
if(CMAKE_SIZEOF_VOID_P EQUAL 4)
_BOOST_SKIPPED("libboost_python313.a" "64 bit, need 32")
return()
endif()
which is weird because the generated libraries are indeed 32-bit, not 64-bit. I checked:
$ emar x ../boost-install/lib/libboost_python313.a exec.o
$ file exec.o
exec.o: WebAssembly (wasm) binary module version 0x1 (MVP)
I'm not sure how to debug how these cmake files are created, but something is going wrong. This is preventing further use of cmake with these libraries, since they are wrongly rejected:
No suitable build variant has been found.
The following variants have been tried and rejected:
* libboost_python313.a (64 bit, need 32)
Details
The compilation line is:
./b2 variant=release toolset=clang-emscripten link=static threading=single --layout=system --prefix=/Users/fx/Desktop/pyodide/boost-install -d2 install
The jam file is standard, but I have added:
using clang : emscripten : emcc : <archiver>emar <ranlib>emranlib <linker>emlink ;
using python : 3.13 : python3.13 : /Users/fx/Library/Caches/.pyodide-xbuildenv-0.33.0/0.29.3/xbuildenv/pyodide-root/cpython/installs/python-3.13.2/include/python3.13 : ;
I am building boost, and in particular boost-python, for emscripten. My detailed setup is given below. When I run
b2, it is clear that the address-model is correctly detected:However, in the installed cmake config files, I see this:
which is weird because the generated libraries are indeed 32-bit, not 64-bit. I checked:
I'm not sure how to debug how these cmake files are created, but something is going wrong. This is preventing further use of cmake with these libraries, since they are wrongly rejected:
Details
The compilation line is:The jam file is standard, but I have added: