From f4ab6a2253a8cb9adfb608e52f4d341f03ffc136 Mon Sep 17 00:00:00 2001 From: Brentley Jones Date: Mon, 21 Aug 2023 10:08:15 -0500 Subject: [PATCH] Add feature to check for `ObjcProvider` linker info availability MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Some rulesets inspect linking information from `ObjcProvider` and fallback to `CcInfo` only if a rule doesn’t propagate an `ObjcProvider`. After `7.0.0-pre.20230724.1` a `ObjcProvider` will exist, but it won’t have any linking information set. Signed-off-by: Brentley Jones --- features.bzl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/features.bzl b/features.bzl index 328d23d..6c6240d 100644 --- a/features.bzl +++ b/features.bzl @@ -11,6 +11,8 @@ _cc = struct( # Note: In Bazel 6.3 the `grep_includes` parameter is optional and a no-op in the cc_common API # In future Bazel versions it will be removed altogether. grep_includes_is_optional = ge("6.3.0"), + # From 7.0.0-pre.20230724.1 on `ObjcProvider` no longer contains linking info + objc_linking_info_migrated = ge("7.0.0-pre.20230724.1"), ) _external_deps = struct( @@ -22,7 +24,7 @@ _external_deps = struct( _flags = struct( # This flag was renamed in https://github.com/bazelbuild/bazel/pull/18313 allow_unresolved_symlinks = ( - "allow_unresolved_symlinks" + "allow_unresolved_symlinks" if ge("7.0.0-pre.20230628.2") else "experimental_allow_unresolved_symlinks" )