Skip to content

Commit a06096d

Browse files
committed
Merge all artifacts into a single zip file
Since `upload-artifact@v4` we're no longer allowed to upload to a single artifact from multiple jobs. Fortunately GitHub provides a helper step to merge them again, giving us a single artifact to download rather than having to download+open+unzip four individual ones.
1 parent 5faad5c commit a06096d

File tree

1 file changed

+20
-7
lines changed

1 file changed

+20
-7
lines changed

.github/workflows/build-dxc.yaml

Lines changed: 20 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ jobs:
44
build-dxc-macos:
55
runs-on: macos-15-xlarge
66
steps:
7-
- uses: actions/checkout@v4
7+
- uses: actions/checkout@v6
88
- run: git clone https://github.com/microsoft/DirectXShaderCompiler.git dxc --revision=$(cat commit-hash) --recurse-submodules
99
- run: cmake -Bbuild -GNinja -C cmake/caches/PredefinedParams.cmake -DSPIRV_BUILD_TESTS=OFF -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_WERROR=OFF
1010
working-directory: dxc
1111
- run: cmake --build dxc/build -t dxcompiler
12-
- uses: actions/upload-artifact@v4
12+
- uses: actions/upload-artifact@v6
1313
with:
1414
name: MacOS aarch64 libdxcompiler.dylib
1515
path: dxc/build/lib/libdxcompiler.dylib
@@ -18,12 +18,12 @@ jobs:
1818
runs-on: ubuntu-22.04 # For older GLIBC, the "hosted runner" above has Ubuntu 24.04 whose compiled binaries require glibc 2.38.
1919
steps:
2020
- run: sudo apt-get install -y ninja-build
21-
- uses: actions/checkout@v4
21+
- uses: actions/checkout@v6
2222
- run: git clone https://github.com/microsoft/DirectXShaderCompiler.git dxc --revision=$(cat commit-hash) --recurse-submodules
2323
- run: cmake -Bbuild -GNinja -C cmake/caches/PredefinedParams.cmake -DSPIRV_BUILD_TESTS=OFF -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_WERROR=OFF
2424
working-directory: dxc
2525
- run: cmake --build dxc/build -t dxcompiler
26-
- uses: actions/upload-artifact@v4
26+
- uses: actions/upload-artifact@v6
2727
with:
2828
name: Linux x64 libdxcompiler.so
2929
path: dxc/build/lib/libdxcompiler.so
@@ -34,12 +34,12 @@ jobs:
3434
# 19045.6691 is the latest/last Windows 10 release, which we need to target in order
3535
# to load dxcompiler.dll on our older GPU-runner CI machines.
3636
steps:
37-
- uses: actions/checkout@v4
37+
- uses: actions/checkout@v6
3838
- run: git clone https://github.com/microsoft/DirectXShaderCompiler.git dxc --revision=$(cat commit-hash) --recurse-submodules
3939
- run: cmake -Bbuild -G "Visual Studio 17 2022" -C cmake/caches/PredefinedParams.cmake -DSPIRV_BUILD_TESTS=OFF -DLLVM_ENABLE_WERROR=OFF -DCMAKE_SYSTEM_VERSION="10.0.19045.6691"
4040
working-directory: dxc
4141
- run: cmake --build dxc/build --config Release -t dxcompiler
42-
- uses: actions/upload-artifact@v4
42+
- uses: actions/upload-artifact@v6
4343
with:
4444
name: Windows x64 dxcompiler.dll
4545
path: dxc/build/Release/bin/dxcompiler.*
@@ -55,7 +55,20 @@ jobs:
5555
-DCLANG_TABLEGEN="$(Resolve-Path build\Release\bin\clang-tblgen.exe)"
5656
working-directory: dxc
5757
- run: cmake --build dxc/build-aarch64 --config Release -t dxcompiler
58-
- uses: actions/upload-artifact@v4
58+
- uses: actions/upload-artifact@v6
5959
with:
6060
name: Windows aarch64 dxcompiler.dll
6161
path: dxc/build-aarch64/Release/bin/dxcompiler.*
62+
63+
merge:
64+
runs-on: ubuntu-latest
65+
needs:
66+
- build-dxc-macos
67+
- build-dxc-linux
68+
- build-dxc-windows
69+
steps:
70+
- name: Merge Artifacts
71+
uses: actions/upload-artifact/merge@v6
72+
with:
73+
name: dxcompiler
74+
pattern: "*dxcompiler*"

0 commit comments

Comments
 (0)