Skip to content

Commit

Permalink
Use the Xcode command-line tools instead of Xcode in Mac release work…
Browse files Browse the repository at this point in the history
…flows (#5678)

Signed-off-by: Brentley Jones <[email protected]>
  • Loading branch information
brentleyjones authored Jan 9, 2024
1 parent f7f7dd9 commit 1d9b17d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,8 @@ common --nolegacy_important_outputs

# Use a static PATH variable to prevent unnecessary rebuilds of dependencies like protobuf.
common --incompatible_strict_action_env
common:macos --action_env=DEVELOPER_DIR
common:macos --host_action_env=DEVELOPER_DIR

# rules_nodejs needs runfiles to be explicitly enabled.
common:linux --enable_runfiles
Expand Down Expand Up @@ -203,6 +205,9 @@ common:windows --cxxopt=/std:c++17
# This flag is a workaround to silence the linker warnings.
common:macos --linkopt="-Wl,-no_warn_duplicate_libraries"

# Ensure that we don't use the apple_support cc_toolchain
common:macos --repo_env=BAZEL_NO_APPLE_CPP_TOOLCHAIN=1

# Run Webdriver tests with --config=webdriver-debug to debug webdriver tests locally.
# See server/testutil/webtester/webtester.go for more details.
common:webdriver-debug --test_arg=-webdriver_debug
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-m1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
export DEVELOPER_DIR=/Applications/Xcode_12.4.app/Contents/Developer
export DEVELOPER_DIR=/Library/Developer/CommandLineTools
"${GITHUB_WORKSPACE}/bin/bazel" build --config=release-m1 --remote_header=x-buildbuddy-api-key=${{ secrets.BUILDBUDDY_ORG_API_KEY }} //enterprise/server/cmd/executor:executor
cp bazel-bin/enterprise/server/cmd/**/**/executor executor-enterprise-darwin-arm64
gh release upload ${{ steps.vars.outputs.tag }} executor-enterprise-darwin-arm64 --clobber
2 changes: 1 addition & 1 deletion .github/workflows/release-mac.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ jobs:
- name: Build and Upload Artifacts
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
XCODE_VERSION: 12.4
run: |
export DEVELOPER_DIR=/Library/Developer/CommandLineTools
"${GITHUB_WORKSPACE}/bin/bazel" build --config=release-mac --remote_header=x-buildbuddy-api-key=${{ secrets.BUILDBUDDY_ORG_API_KEY }} //server/cmd/buildbuddy:buildbuddy //enterprise/server/cmd/server:buildbuddy //enterprise/server/cmd/executor:executor
cp bazel-bin/server/cmd/**/**/buildbuddy buildbuddy-darwin-amd64
cp bazel-bin/enterprise/server/cmd/**/**/buildbuddy buildbuddy-enterprise-darwin-amd64
Expand Down

0 comments on commit 1d9b17d

Please sign in to comment.