Description of the bug:
I have a repo with platforms defined:
https://github.com/bazelbuild/apple_support/blob/f2be7660d083eeb14e52134e60308411b6c9e74a/platforms/BUILD
For everyone consuming this repo I want to recommend a platform_mappings file like:
@build_bazel_apple_support//platforms:ios_sim_arm64
--cpu=ios_sim_arm64
--apple_platform_type=ios
...
where build_bazel_apple_support is included in the platform label. But when building in the apple_support repo itself with this file, and passing something like --platforms=@build_bazel_apple_support//platforms:ios_sim_arm64 as the platform, the platform_mappings file isn't taken into account. In the output of bazel config SHA you can see the platform is set correctly:
platforms: [//platforms:ios_sim_arm64]
But the flags are not:
apple_platform_type: macos
If I change the platform_mappings file to remove the repo name it works:
//platforms:ios_sim_arm64
--cpu=ios_sim_arm64
--apple_platform_type=ios
What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
No response
Which operating system are you running Bazel on?
macOS
What is the output of bazel info release?
89d34ac
If bazel info release returns development version or (@non-git), tell us how you built Bazel.
No response
What's the output of git remote get-url origin; git rev-parse master; git rev-parse HEAD ?
No response
Have you found anything relevant by searching the web?
No response
Any other information, logs, or outputs that you want to share?
No response
Description of the bug:
I have a repo with platforms defined:
https://github.com/bazelbuild/apple_support/blob/f2be7660d083eeb14e52134e60308411b6c9e74a/platforms/BUILD
For everyone consuming this repo I want to recommend a platform_mappings file like:
where
build_bazel_apple_supportis included in the platform label. But when building in the apple_support repo itself with this file, and passing something like--platforms=@build_bazel_apple_support//platforms:ios_sim_arm64as the platform, the platform_mappings file isn't taken into account. In the output ofbazel config SHAyou can see the platform is set correctly:But the flags are not:
If I change the platform_mappings file to remove the repo name it works:
What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
No response
Which operating system are you running Bazel on?
macOS
What is the output of
bazel info release?89d34ac
If
bazel info releasereturnsdevelopment versionor(@non-git), tell us how you built Bazel.No response
What's the output of
git remote get-url origin; git rev-parse master; git rev-parse HEAD?No response
Have you found anything relevant by searching the web?
No response
Any other information, logs, or outputs that you want to share?
No response