From 6ad55a087814cb63a541cbe0239818b6b8798b21 Mon Sep 17 00:00:00 2001 From: Keith Smiley Date: Mon, 17 Nov 2025 10:43:26 -0800 Subject: [PATCH] Fix windows toolchain target_compatible_with It seems like this was incorrectly targeting apple constraints, when really if this works at all today it will only be able to build windows targets for now. Fixes https://github.com/bazelbuild/rules_swift/issues/1614 --- swift/internal/swift_autoconfiguration.bzl | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/swift/internal/swift_autoconfiguration.bzl b/swift/internal/swift_autoconfiguration.bzl index 46f1f3746..27a99652e 100644 --- a/swift/internal/swift_autoconfiguration.bzl +++ b/swift/internal/swift_autoconfiguration.bzl @@ -364,7 +364,10 @@ toolchain( "@platforms//os:windows", "@platforms//cpu:x86_64", ], - target_compatible_with = APPLE_PLATFORMS_CONSTRAINTS[arch], + target_compatible_with = [ + "@platforms//os:windows", + "@platforms//cpu:x86_64", + ], toolchain = ":windows-toolchain", toolchain_type = "{toolchain_type}", visibility = ["//visibility:public"],