[HLSL] Update Msvce.psm1 to grab FXC binaries#2127
Conversation
|
I want to preface this with an upfront apology that I have no idea if this is actually the best place or way to do this. For context, FXC is the original HLSL compiler from DX9, and it is still shipped as part of the Windows SDK for DX9-11. It is closed-source and windows-only. Grabbing it from the Windows SDK distributions as part of the Windows compiler build seemed reasonable to me. I know there is more glue to get it wired up into the compiler-explorer UI, but think this is the right first step. |
|
sorry, no, this script is old and not used. Basically what we do is download zip files from somewhere and manually extract them to a shared drive that CE can reach. And for MSVC compilers we use this script to download, install and zip them up: https://github.com/compiler-explorer/infra/blob/main/msvc-install/msvc2022-install.ps1 |
This adds a new fxc-install.ps1 script which downloads Windows SDKs and extracts out the compiler binaries. It tries to match the directory structure and final outputs that the msvc2022-install.ps1 script produces.
|
@partouf getting this really pushed the limits of my powershell abilities (which are pretty bad), so I did need a fair bit of help from Claude on this latest iteration. The approach seems to work, although it is a bit wonky. The Windows SDK installers really don't like being installed if they're already on the system (even to a different path), and they aggressively prompt users. So the workaround is to manually rip apart the installer package... which works. I've gone over the script myself and it seems sane-ish, and I've tested locally that it works. I don't know where it would need to be integrated to put the compilers into the shared drive used in production. Also feel free to tell me to go away... I know I'm doing something awkward here. |
This updates the powershell script that builds up the windows image's data directory to pull in FXC compiler binaries.
Assisted-by: Claude Opus 4.7