mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-07-02 02:51:42 +00:00
[bazel] Update toolchains to 2027-1 (#9016)
This updates to the 2027-1 toolchains. This also is the first version with the `rules_bzlmodrio_toolchains -> wpilib_toolchains` rename, so the surface area of the change is a little bit big. The opencv dep has bzlmod'ified as part of this as well.
This commit is contained in:
@@ -441,8 +441,8 @@ def wpilib_cc_shared_library(
|
||||
_split_debug_symbols(
|
||||
name = name + "-symbolsplit",
|
||||
copy = select({
|
||||
"@rules_bzlmodrio_toolchains//conditions:linux_arm64": False,
|
||||
"@rules_bzlmodrio_toolchains//conditions:linux_x86_64": True,
|
||||
"@wpilib_toolchains//conditions:linux_arm64": False,
|
||||
"@wpilib_toolchains//conditions:linux_x86_64": True,
|
||||
"//conditions:default": True,
|
||||
}),
|
||||
use_debug_name = select({
|
||||
@@ -455,13 +455,13 @@ def wpilib_cc_shared_library(
|
||||
pkg_files(
|
||||
name = folder + "/lib" + lib + "-shared-files",
|
||||
srcs = select({
|
||||
"@rules_bzlmodrio_toolchains//conditions:osx": [universal_name],
|
||||
"@wpilib_toolchains//conditions:osx": [universal_name],
|
||||
"//conditions:default": [
|
||||
":" + name + "-symbolsplit",
|
||||
],
|
||||
}),
|
||||
strip_prefix = select({
|
||||
"@rules_bzlmodrio_toolchains//conditions:osx": "universal",
|
||||
"@wpilib_toolchains//conditions:osx": "universal",
|
||||
"//conditions:default": None,
|
||||
}),
|
||||
visibility = visibility,
|
||||
|
||||
@@ -13,7 +13,7 @@ py_binary(
|
||||
name = "gen_resources",
|
||||
srcs = ["gen_resources.py"],
|
||||
target_compatible_with = select({
|
||||
"@rules_bzlmodrio_toolchains//constraints/is_systemcore:systemcore": ["@platforms//:incompatible"],
|
||||
"@wpilib_toolchains//constraints/is_systemcore:systemcore": ["@platforms//:incompatible"],
|
||||
"//conditions:default": [],
|
||||
}),
|
||||
visibility = ["//visibility:public"],
|
||||
|
||||
@@ -11,7 +11,7 @@ def wpilib_halsim_extension(
|
||||
includes = ["src/main/native/include"],
|
||||
include_license_files = True,
|
||||
target_compatible_with = select({
|
||||
"@rules_bzlmodrio_toolchains//constraints/is_systemcore:systemcore": ["@platforms//:incompatible"],
|
||||
"@wpilib_toolchains//constraints/is_systemcore:systemcore": ["@platforms//:incompatible"],
|
||||
"//conditions:default": [],
|
||||
}),
|
||||
visibility = ["//visibility:public"],
|
||||
|
||||
@@ -84,7 +84,7 @@ def wpilib_jni_java_library(
|
||||
**java_library_args
|
||||
)
|
||||
|
||||
jni = "@rules_bzlmodrio_toolchains//jni"
|
||||
jni = "@wpilib_toolchains//jni"
|
||||
_jni_headers(
|
||||
name = headers_name,
|
||||
jni = jni,
|
||||
@@ -106,7 +106,7 @@ def wpilib_jni_cc_library(
|
||||
deps = [],
|
||||
java_dep = None,
|
||||
**kwargs):
|
||||
jni = "@rules_bzlmodrio_toolchains//jni"
|
||||
jni = "@wpilib_toolchains//jni"
|
||||
|
||||
if java_dep[0] != ":":
|
||||
fail("java_dep", java_dep, "should start with a :")
|
||||
|
||||
@@ -122,12 +122,11 @@ def architectures_pkg_zip(
|
||||
|
||||
def platform_prefix(t):
|
||||
return select({
|
||||
"@rules_bzlmodrio_toolchains//conditions:linux_x86_64": "linux/x86-64/" + t,
|
||||
"@rules_bzlmodrio_toolchains//conditions:osx": "osx/universal/" + t,
|
||||
"@rules_bzlmodrio_toolchains//conditions:windows_arm64": "windows/arm64/" + t,
|
||||
"@rules_bzlmodrio_toolchains//conditions:windows_x86_64": "windows/x86-64/" + t,
|
||||
"@rules_bzlmodrio_toolchains//constraints/is_roborio:roborio": "linux/roborio/" + t,
|
||||
"@rules_bzlmodrio_toolchains//constraints/is_systemcore:systemcore": "linux/systemcore/" + t,
|
||||
"@wpilib_toolchains//conditions:linux_x86_64": "linux/x86-64/" + t,
|
||||
"@wpilib_toolchains//conditions:osx": "osx/universal/" + t,
|
||||
"@wpilib_toolchains//conditions:windows_arm64": "windows/arm64/" + t,
|
||||
"@wpilib_toolchains//conditions:windows_x86_64": "windows/x86-64/" + t,
|
||||
"@wpilib_toolchains//constraints/is_systemcore:systemcore": "linux/systemcore/" + t,
|
||||
})
|
||||
|
||||
def _wpilib_maven_export_impl(
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
def robotpy_compatibility_select():
|
||||
return select({
|
||||
"@bazel_tools//src/conditions:windows": ["@platforms//:incompatible"],
|
||||
"@rules_bzlmodrio_toolchains//constraints/is_systemcore:systemcore": ["@platforms//:incompatible"],
|
||||
"@wpilib_toolchains//constraints/is_systemcore:systemcore": ["@platforms//:incompatible"],
|
||||
"//conditions:default": [],
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user