From 6e4a0a208d109b17df3b346f24dd7d3b3f638996 Mon Sep 17 00:00:00 2001 From: Jasper Bekkers Date: Sat, 2 May 2026 16:40:49 +0200 Subject: [PATCH 1/3] Build from Traverse fork at the spirv-allow-import branch HEAD MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Switches the three clone URLs in the build workflow to the Traverse fork (Traverse-Research/DirectXShaderCompiler) and bumps `commit-hash` to 073bf7057 — the head of the `spirv-allow-import` branch, which adds the `-fspv-allow-import` SPIR-V flag for Import linkage in `lib_*` targets (PR Traverse-Research/DirectXShaderCompiler#1). The artifact names (`*-apple-darwin`, `x86_64-unknown-linux-gnu`, etc.) are unchanged — downstream `breda` consumers still drop them in `crates/breda-shader-compiler/dxc//`. Co-Authored-By: Claude Opus 4.7 (1M context) --- .github/workflows/build-dxc.yaml | 6 +++--- README.md | 11 +++++++++-- commit-hash | 2 +- 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-dxc.yaml b/.github/workflows/build-dxc.yaml index 9a6abe5..59a3b0b 100644 --- a/.github/workflows/build-dxc.yaml +++ b/.github/workflows/build-dxc.yaml @@ -5,7 +5,7 @@ jobs: runs-on: macos-15-xlarge steps: - uses: actions/checkout@v6 - - run: git clone https://github.com/microsoft/DirectXShaderCompiler.git dxc --revision=$(cat commit-hash) --recurse-submodules + - run: git clone https://github.com/Traverse-Research/DirectXShaderCompiler.git dxc --revision=$(cat commit-hash) --recurse-submodules - run: cmake -Bbuild -GNinja -C cmake/caches/PredefinedParams.cmake -DSPIRV_BUILD_TESTS=OFF -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_WERROR=OFF working-directory: dxc - run: cmake --build dxc/build -t dxcompiler @@ -20,7 +20,7 @@ jobs: steps: - run: sudo apt-get install -y ninja-build - uses: actions/checkout@v6 - - run: git clone https://github.com/microsoft/DirectXShaderCompiler.git dxc --revision=$(cat commit-hash) --recurse-submodules + - run: git clone https://github.com/Traverse-Research/DirectXShaderCompiler.git dxc --revision=$(cat commit-hash) --recurse-submodules - run: cmake -Bbuild -GNinja -C cmake/caches/PredefinedParams.cmake -DSPIRV_BUILD_TESTS=OFF -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_WERROR=OFF working-directory: dxc - run: cmake --build dxc/build -t dxcompiler @@ -33,7 +33,7 @@ jobs: runs-on: windows-2025 steps: - uses: actions/checkout@v6 - - run: git clone https://github.com/microsoft/DirectXShaderCompiler.git dxc --revision=$(cat commit-hash) --recurse-submodules + - run: git clone https://github.com/Traverse-Research/DirectXShaderCompiler.git dxc --revision=$(cat commit-hash) --recurse-submodules - run: > cmake -Bbuild -G "Visual Studio 17 2022" -C cmake/caches/PredefinedParams.cmake -DSPIRV_BUILD_TESTS=OFF -DLLVM_ENABLE_WERROR=OFF diff --git a/README.md b/README.md index 14f8bdf..8472322 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,14 @@ # How to use +This repo builds `libdxcompiler.{dylib,so,dll}` from +[Traverse-Research/DirectXShaderCompiler][fork] (our fork of microsoft/DirectXShaderCompiler) so we can ship our patches — currently the +SPIR-V `-fspv-allow-import` flag for Import linkage in `lib_*` targets. + 1. Check out the repo -2. Update [`commit-hash`](./commit-hash) to point to the right dxc commit hash -3. Download the build artifacts +2. Update [`commit-hash`](./commit-hash) to point to the desired commit on + the fork's `main` (or any branch HEAD if you're testing a topic branch) +3. Download the build artifacts from the workflow run 4. Unzip all artifacts into the right directories in `breda` (`crates/breda-shader-compiler/dxc//`) 5. When on macOS, issue `xattr -d com.apple.quarantine libdxcompiler.dylib` to de-quarantine the library (your browser will quarantine executable files, we'll need to tell macOS) + +[fork]: https://github.com/Traverse-Research/DirectXShaderCompiler diff --git a/commit-hash b/commit-hash index 80f8897..215df60 100644 --- a/commit-hash +++ b/commit-hash @@ -1 +1 @@ -4a9886749be01825e3bb161e6ea6e01fd70e9024 +073bf7057fe9d2aed135d770db50c8eaca72c098 From a3b2d7d31fa6bc99b2935da5862a375d0006c9eb Mon Sep 17 00:00:00 2001 From: Jasper Bekkers Date: Sat, 2 May 2026 23:22:58 +0200 Subject: [PATCH 2/3] Bump to spirv-allow-import head with prototype reorder + OpLine fixes --- commit-hash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commit-hash b/commit-hash index 215df60..147b33a 100644 --- a/commit-hash +++ b/commit-hash @@ -1 +1 @@ -073bf7057fe9d2aed135d770db50c8eaca72c098 +eafa33f71f21010e77cee284e24381ca19f6cad2 From a2a6f20b5c475a2fd5158e80316fd5de4ab97028 Mon Sep 17 00:00:00 2001 From: Jasper Bekkers Date: Sun, 3 May 2026 13:53:46 +0200 Subject: [PATCH 3/3] Bump to spirv-allow-import head with full Import-prototype OpLine suppression --- commit-hash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commit-hash b/commit-hash index 147b33a..44adfd7 100644 --- a/commit-hash +++ b/commit-hash @@ -1 +1 @@ -eafa33f71f21010e77cee284e24381ca19f6cad2 +c99070ed9164fb96b2afa0765294a3396adf36eb