Windows: do not run winsdk_configure on Linux

Fixes https://github.com/bazelbuild/bazel/issues/9089

Closes #9090.

PiperOrigin-RevId: 261894456
diff --git a/src/main/res/winsdk_configure.bzl b/src/main/res/winsdk_configure.bzl
index 2eb7d0e..3b77acb 100644
--- a/src/main/res/winsdk_configure.bzl
+++ b/src/main/res/winsdk_configure.bzl
@@ -14,6 +14,16 @@
 
 """Configure local Resource Compilers for every available target platform.
 
+Platform support:
+
+- Linux/macOS/non-Windows: this repository rule is almost a no-op.
+  It generates an empty BUILD file, and does not actually discover any
+  toolchains. The register_local_rc_exe_toolchains() method is a no-op.
+
+- Windows: this repository rule discovers the Windows SDK path, the installed
+  rc.exe compilers. The register_local_rc_exe_toolchains() registers a toolchain
+  for each rc.exe compiler.
+
 Usage:
 
     load("//src/main/res:winsdk_configure.bzl", "winsdk_configure")
@@ -46,6 +56,9 @@
     return result
 
 def _find_all_rc_exe(repository_ctx):
+    if not repository_ctx.os.name.startswith("windows"):
+        return {}
+
     vc = find_vc_path(repository_ctx)
     if vc:
         env = setup_vc_env_vars(