-
Notifications
You must be signed in to change notification settings - Fork 446
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
Enable @examples//ffi/rust_calling_c/... on MacOS CI #621
Comments
One issue here (other than the local_libstdcpp issue above) is that no install name is used by bazel when compiling dynamic libraries on macOS. This results in binaries produced by rust_* using relative search paths for dynamic libraries, which are not appropriate for the produced binary. The cc actions take the additional step of patching up their binaries using install_name_tool to work around this (see: https://cs.opensource.google/bazel/bazel/+/master:tools/cpp/osx_cc_wrapper.sh). A new flag has been added to bazel that will fix this behavior: --incompatible_macos_set_install_name. It is currently broken, but will be fixed by bazelbuild/bazel#13427. Once that lands, _compute_rpaths will need to be updated here: https://github.com/bazelbuild/rules_rust/blob/main/rust/private/rustc.bzl#L715. This method should be updated to use the simpler |
My |
It looks like #741 covers the |
Building these targets generates a build failure
The examples should be updated (or potentially the underlying rust_bindgen rules) to support MacOS.
The text was updated successfully, but these errors were encountered: