Skip to content

Commit

Permalink
Log Bazel version, fix library path's referring to itself for Bazel b…
Browse files Browse the repository at this point in the history
…uild output, and use macOS 12 images.

CI build types: macos-x86_64
  • Loading branch information
mbautin committed Sep 15, 2023
1 parent 46c925f commit b08468f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ jobs:
# ---------------------------------------------------------------------------------------

- name: macos-x86_64
os: macos-11
os: macos-12
docker_image:
build_thirdparty_args:

Expand Down
6 changes: 6 additions & 0 deletions python/yugabyte_db_thirdparty/builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -801,6 +801,8 @@ def build_with_bazel(
if not bazel_path:
raise IOError("Could not find bazel or bazelisk executable")
log("Using bazelisk wrapper instead of bazel: %s", bazel_path)
bazel_version = subprocess.check_call([bazel_path, '--version'])
log("Bazel version: %s", bazel_version)

if should_clean:
self.log_output(log_prefix, [bazel_path, 'clean', '--expunge'])
Expand Down Expand Up @@ -869,6 +871,10 @@ def install_bazel_build_output(
self.log_output(log_prefix, ['chmod', '755' if is_shared else '644', src_path])
self.log_output(log_prefix, ['cp', src_path, dest_path])

# Fix library's path referring to itself (LC_ID_DYLIB).
if is_shared and is_macos():
self.log_output(log_prefix, ['install_name_tool', '-id', dest_path, dest_path])

def validate_build_output(self) -> None:
if is_macos():
target_arch = get_target_arch()
Expand Down

0 comments on commit b08468f

Please sign in to comment.