Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions rules/apple_platform/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,6 @@
"macos",
"tvos",
"watchos",
"visionos"
]
]
5 changes: 4 additions & 1 deletion rules/framework.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ def apple_framework(
"@build_bazel_rules_ios//rules/apple_platform:macos": "@build_bazel_rules_apple//apple/internal:environment_plist_macos",
"@build_bazel_rules_ios//rules/apple_platform:tvos": "@build_bazel_rules_apple//apple/internal:environment_plist_tvos",
"@build_bazel_rules_ios//rules/apple_platform:watchos": "@build_bazel_rules_apple//apple/internal:environment_plist_watchos",
"@build_bazel_rules_ios//rules/apple_platform:visionos": "@build_bazel_rules_apple//apple/internal:environment_plist_visionos",
"//conditions:default": None,
}))

Expand All @@ -114,13 +115,15 @@ def apple_framework(
"@build_bazel_rules_ios//rules/apple_platform:macos": platforms.get("macos", ""),
"@build_bazel_rules_ios//rules/apple_platform:tvos": platforms.get("tvos", ""),
"@build_bazel_rules_ios//rules/apple_platform:watchos": platforms.get("watchos", ""),
"@build_bazel_rules_ios//rules/apple_platform:visionos": platforms.get("visionos", ""),
"//conditions:default": "",
})
platform_type = select({
"@build_bazel_rules_ios//rules/apple_platform:ios": "ios",
"@build_bazel_rules_ios//rules/apple_platform:macos": "macos",
"@build_bazel_rules_ios//rules/apple_platform:tvos": "tvos",
"@build_bazel_rules_ios//rules/apple_platform:watchos": "watchos",
"@build_bazel_rules_ios//rules/apple_platform:visionos": "visionos",
"//conditions:default": "",
})

Expand Down Expand Up @@ -997,7 +1000,7 @@ def _apple_framework_packaging_impl(ctx):
# The current build architecture
arch = ctx.fragments.apple.single_arch_cpu

# The current Apple platform type, such as iOS, macOS, tvOS, or watchOS
# The current Apple platform type, such as iOS, macOS, tvOS, visionOS or watchOS
platform = str(ctx.fragments.apple.single_arch_platform.platform_type)

# Use 'library_linkopts' to determine if resulting binary should be application extension safe.
Expand Down
1 change: 1 addition & 0 deletions rules/precompiled_apple_resource_bundle.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,7 @@ def precompiled_apple_resource_bundle(**kwargs):
"@build_bazel_rules_ios//rules/apple_platform:macos": "@build_bazel_rules_apple//apple/internal:environment_plist_macos",
"@build_bazel_rules_ios//rules/apple_platform:tvos": "@build_bazel_rules_apple//apple/internal:environment_plist_tvos",
"@build_bazel_rules_ios//rules/apple_platform:watchos": "@build_bazel_rules_apple//apple/internal:environment_plist_watchos",
"@build_bazel_rules_ios//rules/apple_platform:visionos": "@build_bazel_rules_apple//apple/internal:environment_plist_visionos",
}),
**kwargs
)
1 change: 1 addition & 0 deletions tests/framework/platforms/versions.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ _VERSIONS = {
"ios": ["12.0", "16.2", "17.2"],
"tvos": ["12.0", "16.2", "17.2"],
"watchos": ["3.2"],
"visionos": ["1.0"],
}

def _version_int(version):
Expand Down
Loading