Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions grain/oss/build_whl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,17 @@ main() {
# Enable host OS specific configs. For instance, "build:linux" will be used
# automatically when building on Linux.
write_to_bazelrc "build --enable_platform_specific_config"
write_to_bazelrc "build --verbose_failures"
# Bazel 7.0.0 no longer supports dynamic symbol lookup on macOS. To resolve
# undefined symbol errors in macOS arm64 builds, explicitly add the necessary
# linker flags until dependencies are well defined. See
# https://github.com/bazelbuild/bazel/issues/19730.
write_to_bazelrc "build:macos --linkopt=-Wl,-undefined,dynamic_lookup"
write_to_bazelrc "build:macos --host_linkopt=-Wl,-undefined,dynamic_lookup"
# Force clang on macos. Otherwise we get linker errors described in
# https://github.com/bazelbuild/bazel/issues/20838.
write_to_bazelrc "build:macos --action_env=CC=clang"
write_to_bazelrc "build:macos --action_env=CXX=clang++"

write_to_bazelrc "build --@rules_python//python/config_settings:python_version=${PYTHON_VERSION}"
# Set platform-wise file extension for extension modules.
Expand Down
Loading