Meson support was merged in #986, but appears to not have support for cross compilation. I am concluding this from a use case where I am trying to cross compile using the Emscripten compiler. For this to work, a cross file should be provided to meson setup, however there is no logic for passing cross file as can be seen here:
Meson support was merged in #986, but appears to not have support for cross compilation. I am concluding this from a use case where I am trying to cross compile using the Emscripten compiler. For this to work, a cross file should be provided to
meson setup
, however there is no logic for passing cross file as can be seen here:https://github.com/bazelbuild/rules_foreign_cc/blob/9d5727d5e51bf1be8423dff7996bdb4d847b47e6/foreign_cc/meson.bzl#L113-L119
I think this should be solved by generating a cross file for Meson mirroring what is done for the CMake toolchain file here:
https://github.com/bazelbuild/rules_foreign_cc/blob/9d5727d5e51bf1be8423dff7996bdb4d847b47e6/foreign_cc/private/cmake_script.bzl#L197-L230
What do you think @jheaff1, @jsharpe, and @edison-moreland?