Skip to content

Commit 3e4f450

Browse files
committed
Fix CI for Bazel HEAD
Required changes to fix Bazel @ HEAD Signed-off-by: Luis Padron <heyluispadron@gmail.com>
1 parent a369447 commit 3e4f450

File tree

8 files changed

+23
-29
lines changed

8 files changed

+23
-29
lines changed

.bazelversion

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
8.0.0
1+
8.x

MODULE.bazel

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ use_repo(
3434

3535
bazel_dep(
3636
name = "apple_support",
37-
version = "1.11.1",
37+
version = "1.21.0",
3838
dev_dependency = True,
3939
repo_name = "build_bazel_apple_support",
4040
)
@@ -58,7 +58,7 @@ bazel_dep(
5858
# Use newer versions of deps in development
5959
single_version_override(
6060
module_name = "apple_support",
61-
version = "1.17.1",
61+
version = "1.21.0",
6262
)
6363

6464
single_version_override(

buildbuddy.yaml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ x_templates:
2323
USE_BAZEL_VERSION: 8.x
2424
- &bazel_head
2525
env:
26-
USE_BAZEL_VERSION: last_green
26+
USE_BAZEL_VERSION: 4c2d91e762ab6e492853b021408129dd93fb5904 # TODO: Switch back to last_green once get_cpu has been removed
2727

2828
- &normal_resources
2929
resource_requests: { memory: 6GB }
@@ -114,7 +114,7 @@ actions:
114114
<<: *normal_resources
115115
<<: *examples_integration_workspace
116116
bazel_commands:
117-
# Not validate since Bazel 8 Bzlmod paths are different
117+
# Not validate since Bazel 8+ Bzlmod paths are different
118118
- *generate_integration
119119
- *build_all
120120
- name: Integration Test - "examples/integration" - Bazel LTS
@@ -124,8 +124,7 @@ actions:
124124
<<: *normal_resources
125125
<<: *examples_integration_workspace
126126
bazel_commands:
127-
# Not validate since Bazel 8 Bzlmod paths are different
128-
- *generate_integration
127+
- *validate_integration
129128
- *build_all
130129
- name: Integration Test - "examples/integration" - Bazel HEAD
131130
<<: *bazel_head
@@ -134,7 +133,10 @@ actions:
134133
<<: *normal_resources
135134
<<: *examples_integration_workspace
136135
bazel_commands:
137-
- *validate_integration
136+
# Not validate as Bazel HEAD has incompatible path changes to repo rules
137+
# - "external/+_repo_rules+examples_command_line_external/",
138+
# + "external/+new_local_repository+examples_command_line_external/
139+
- *generate_integration
138140
- *build_all
139141

140142
- name: Integration Test - "examples/rules_ios" - Bazel Previous LTS

examples/integration/MODULE.bazel

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ bazel_dep(
55
)
66
bazel_dep(
77
name = "apple_support",
8-
version = "1.15.1",
8+
version = "1.21.0",
99
repo_name = "build_bazel_apple_support",
1010
)
1111
bazel_dep(
@@ -50,13 +50,18 @@ use_repo(
5050
"local_config_apple_cc_toolchains",
5151
)
5252

53-
# TODO: Remove manual register once https://github.com/bazelbuild/rules_cc/commit/c8c38f8c710cbbf834283e4777916b68261b359c is released
54-
register_toolchains("@local_config_apple_cc_toolchains//:all")
55-
5653
non_module_deps = use_extension(":repositories.bzl", "non_module_deps")
5754
use_repo(
5855
non_module_deps,
5956
"FXPageControl",
6057
"com_github_krzyzanowskim_cryptoswift",
6158
"com_google_google_maps",
6259
)
60+
61+
new_local_repository = use_repo_rule("@bazel_tools//tools/build_defs/repo:local.bzl", "new_local_repository")
62+
63+
new_local_repository(
64+
name = "examples_command_line_external",
65+
build_file = "//CommandLine/external:BUILD.tpl",
66+
path = "CommandLine/external",
67+
)

examples/integration/WORKSPACE.bzlmod

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +0,0 @@
1-
new_local_repository(
2-
name = "examples_command_line_external",
3-
build_file = "//CommandLine/external:BUILD.tpl",
4-
path = "CommandLine/external",
5-
)

examples/integration/iOSApp/Source/BUILD

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ ios_application(
4444
":release_build": [],
4545
"//conditions:default": [
4646
"--digest-algorithm=sha1",
47-
"--resource-rules=$(RESOURCE_RULES)",
4847
],
4948
}),
5049
entitlements = "ios app.entitlements",

examples/rules_ios/MODULE.bazel

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ bazel_dep(
55
)
66
bazel_dep(
77
name = "apple_support",
8-
version = "1.15.1",
8+
version = "1.21.0",
99
repo_name = "build_bazel_apple_support",
1010
)
1111
bazel_dep(
@@ -33,6 +33,3 @@ use_repo(
3333
"local_config_apple_cc",
3434
"local_config_apple_cc_toolchains",
3535
)
36-
37-
# TODO: Remove manual register once https://github.com/bazelbuild/rules_cc/commit/c8c38f8c710cbbf834283e4777916b68261b359c is released
38-
register_toolchains("@local_config_apple_cc_toolchains//:all")

test/update_all_fixtures.sh

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,13 @@ for dir in examples/*/ ; do
1010
continue
1111
fi
1212

13+
# rules_ios only supports up-to Bazel 7
1314
if [[ "$dir" == "examples/rules_ios/" ]]; then
14-
bazel_version="7.4.1"
15-
else
16-
# See https://github.com/MobileNativeFoundation/rules_xcodeproj/pull/3029
17-
#
18-
# Temporary change to make CI pass until the fix is in `last_green`
19-
bazel_version="dd2464a5933e0a5a6765024573832717b71989bf"
15+
export USE_BAZEL_VERSION="7.x"
2016
fi
2117

2218
echo
2319
echo "Updating \"${dir%/}\" fixtures"
2420
echo
25-
USE_BAZEL_VERSION="$bazel_version" bazel run --config=cache //test/fixtures:update
21+
bazel run --config=cache //test/fixtures:update
2622
done

0 commit comments

Comments
 (0)