rules_swift icon indicating copy to clipboard operation
rules_swift copied to clipboard

CI: complete the Windows CI coverage

Open compnerd opened this issue 2 years ago • 13 comments

Extend the Windows CI to include the tests as well. This will mostly complete the Windows support (the remaining pieces remain in supporting the Windows ARM64 build host).

compnerd avatar May 24 '22 16:05 compnerd

@keith okay, the install issue is resolved, but now the problem is that Path and SDKROOT are not in the environment, and I don't see how to get that added :(

compnerd avatar Feb 20 '24 23:02 compnerd

are the values stable enough to pass directly? like --repo_env=ProgramData=whatever

keith avatar Feb 20 '24 23:02 keith

I suppose that they should be - the installer is installing into a user specific location - %LocalAppData%\Programs\Swift\Toolchains\%SwiftVersion%+Asserts\usr\bin, the runtime is located at %LocalAppData%\Programs\Swift\Runtimes\%SwiftVersion%\usr\bin and SDKROOT can be assumed to be for Windows at %LocalAppData%\Programs\Swift\Platforms\Windows.platform\Developer\SDKs\Windows.sdk.

compnerd avatar Feb 21 '24 04:02 compnerd

@keith I'm not sure how to make the appropriate changes for this, so a bit of guidance would be appreciated.

compnerd avatar Feb 23 '24 18:02 compnerd

I was thinking that if you set that in the environment key like you're doing for the others, and then passed --repo_env=ProgramData it would cover it?

keith avatar Feb 23 '24 18:02 keith

I'm not too fond of the approach, but it does get further:

Auto-Configuration Error: Setting up VC environment variables failed, WINDOWSSDKDIR is not set by the following command:
--
  | "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Auxiliary\Build\VCVARSALL.BAT" amd64  -vcvars_ver=14.37.32822

compnerd avatar Feb 23 '24 22:02 compnerd

is that error one you're thinking the CI setup should have solved?

keith avatar Feb 23 '24 23:02 keith

Well, that seems like something that general Windows support should have figured out. I'm not sure what is going on, but it seems that we are missing something in the image possibly? Or we are not invoking things properly.

compnerd avatar Feb 23 '24 23:02 compnerd

this makes it sound like maybe the windows setup doesn't have the SDK? https://github.com/bazelbuild/bazel/issues/13261

is that what you're thinking?

should that be solved by https://github.com/bazelbuild/continuous-integration/blob/master/buildkite/setup-windows.ps1#L137 ?

keith avatar Feb 23 '24 23:02 keith

Yeah, exactly, it seems like that is what is needed.

compnerd avatar Feb 23 '24 23:02 compnerd

is it possible it's setup correctly but the env var isn't set? i assume that link is the current runner

keith avatar Feb 23 '24 23:02 keith