Skip to content

Commit 89691ed

Browse files
Do not assume submodule root directory in presubmit (#2040)
Tweaks compare_build_systems.py slightly so that it does not assume the root directory of submodules, which arguably made the implementation a little less intuitive.
1 parent 11e7801 commit 89691ed

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

MODULE.bazel

+4-4
Original file line numberDiff line numberDiff line change
@@ -90,31 +90,31 @@ new_git_repository = use_repo_rule("@bazel_tools//tools/build_defs/repo:git.bzl"
9090
new_git_repository(
9191
name = "tinyusb",
9292
build_file = "//src/rp2_common/tinyusb:tinyusb.BUILD",
93-
commit = "4232642899362fa5e9cf0dc59bad6f1f6d32c563", # keep-in-sync-with-submodule: tinyusb
93+
commit = "4232642899362fa5e9cf0dc59bad6f1f6d32c563", # keep-in-sync-with-submodule: lib/tinyusb
9494
remote = "https://github.com/hathach/tinyusb.git",
9595
)
9696

9797
# TODO: Provide btstack as a proper Bazel module.
9898
new_git_repository(
9999
name = "btstack",
100100
build_file = "//src/rp2_common/pico_btstack:btstack.BUILD",
101-
commit = "2b49e57bd1fae85ac32ac1f41cdb7c794de335f6", # keep-in-sync-with-submodule: btstack
101+
commit = "2b49e57bd1fae85ac32ac1f41cdb7c794de335f6", # keep-in-sync-with-submodule: lib/btstack
102102
remote = "https://github.com/bluekitchen/btstack.git",
103103
)
104104

105105
# TODO: Provide cyw43-driver as a proper Bazel module.
106106
new_git_repository(
107107
name = "cyw43-driver",
108108
build_file = "//src/rp2_common/pico_cyw43_driver:cyw43-driver.BUILD",
109-
commit = "cf924bb04c8984675ca0fc2178f082e404e048c3", # keep-in-sync-with-submodule: cyw43-driver
109+
commit = "cf924bb04c8984675ca0fc2178f082e404e048c3", # keep-in-sync-with-submodule: lib/cyw43-driver
110110
remote = "https://github.com/georgerobotics/cyw43-driver.git",
111111
)
112112

113113
# TODO: Provide lwip as a proper Bazel module.
114114
new_git_repository(
115115
name = "lwip",
116116
build_file = "//src/rp2_common/pico_lwip:lwip.BUILD",
117-
commit = "0a0452b2c39bdd91e252aef045c115f88f6ca773", # keep-in-sync-with-submodule: lwip
117+
commit = "0a0452b2c39bdd91e252aef045c115f88f6ca773", # keep-in-sync-with-submodule: lib/lwip
118118
remote = "https://github.com/lwip-tcpip/lwip.git",
119119
)
120120

tools/compare_build_systems.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ def CompareExternalDependencyVersions():
239239
continue
240240

241241
current_submodule_pin = subprocess.run(
242-
("git", "-C", SDK_ROOT, "rev-parse", f'HEAD:lib/{maybe_match.group("dependency")}'),
242+
("git", "-C", SDK_ROOT, "rev-parse", f'HEAD:{maybe_match.group("dependency")}'),
243243
text=True,
244244
check=True,
245245
capture_output=True,

0 commit comments

Comments
 (0)