[PATCH] D28791: [compiler-rt][crt] Simple crtbegin and crtend implementation
Matthew Bauer via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 1 11:43:40 PST 2019
matthewbauer added a comment.
In D28791#1414633 <https://reviews.llvm.org/D28791#1414633>, @phosek wrote:
> In D28791#1414044 <https://reviews.llvm.org/D28791#1414044>, @matthewbauer wrote:
>
> > I was trying to build compiler-rt with WebAssembly and forgot I still had this patched applied. But it looks like it breaks when doing this and things work if you disble crt. You probably just don't want to build crt with WebAssembly targets?
>
>
> Does WebAssembly build set `OS_NAME` to `"Linux`" and architecture to one of x86, x86-64, ARM and ARM64? See `config-ix.cmake`, specifically this line `if (CRT_SUPPORTED_ARCH AND OS_NAME MATCHES "Linux")` should ensure that this is only built on Linux and `set(ALL_CRT_SUPPORTED_ARCH ${X86} ${X86_64} ${ARM32} ${ARM64})` should ensure that it's only built for x86, x86-64, ARM and ARM64.
Ah ok, yeah this was my issue. CMake defaults to CMAKE_HOST_SYSTEM_NAME when no CMAKE_SYSTEM_NAME is provided. So it assumed I was targeting "wasm32-unknown-linux-gnu" not "wasm32-unknown-unknown-wasm".
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D28791/new/
https://reviews.llvm.org/D28791
More information about the llvm-commits
mailing list