Open lightupmemory opened 2 years ago
I got a similar problem when cross building for Android. The cause seems to be that the build script detects addr2line and libbacktrace by trying to compile and run some C++ code
Unfortunately, as we are cross compiling, the code is built for the target system and won't run on host system.
Error log from config.log:
/bin/sh: 2: <redacted>/boost/bin.v2/libs/stacktrace/build/clng-lnx-7/dbg/lnk-sttc/nm-on/trgt-os-andrd/thrd-mlt/vsblt-hdn/ libbacktrace_exe: Exec format error
...removing <redacted>/boost/bin.v2/libs/stacktrace/build/clng-lnx-7/dbg/lnk-sttc/nm-on/trgt-os-andrd/thrd-mlt/vsblt-hdn/ libbacktrace.output
...failed updating 1 target...
/bin/sh: 2: <redacted>/boost/bin.v2/libs/stacktrace/build/clng-lnx-7/dbg/lnk-sttc/nm-on/trgt-os-andrd/thrd-mlt/vsblt-hdn/ addr2line_exe: Exec format error
...removing <redacted>/boost/bin.v2/libs/stacktrace/build/clng-lnx-7/dbg/lnk-sttc/nm-on/trgt-os-andrd/thrd-mlt/vsblt-hdn/ addr2line.output
...failed updating 1 target...
Hello, I'm trying to cross build boost for M1 on an Intel mac. Everything goes fine, except addr2line does not build. From the configuration check, it shows
below is my script
building environment
It seems that macOS doesn't have addr2line at /usr/bin/addr2line. I'm wondering how does boost check for addr2line builds. Moreover, building boost natively (either on intel or M1) and cross building for x86_64 on M1 all generate boost_stacktrace_addr2line. Is it the limitation on intel mac for cross building?