Skip to content

Commit 35d91af

Browse files
committed
ci : add nvcc wrapper for sccache
1 parent 3e3b66d commit 35d91af

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

.github/workflows/build.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,13 @@ jobs:
126126
echo "SDL2_DIR=${{ github.workspace }}\SDL2-${{ matrix.sdl2_ver }}\cmake" | Out-File -FilePath $env:GITHUB_ENV -Append
127127
echo "${{ github.workspace }}\SDL2-${{ matrix.sdl2_ver }}\cmake" > SDL2_PATH.txt
128128
129+
- name: Create nvcc wrapper for sccache
130+
shell: cmd
131+
run: |
132+
echo @echo off > nvcc-sccache.bat
133+
echo sccache "%CUDA_PATH%\bin\nvcc.exe" %%* >> nvcc-sccache.bat
134+
echo set CUDA_NVCC_EXECUTABLE=%CD%\nvcc-sccache.bat >> %GITHUB_ENV%
135+
129136
- name: Configure CMake
130137
shell: cmd
131138
run: |
@@ -136,6 +143,7 @@ jobs:
136143
-DGGML_CUDA=${{ matrix.cublas }} ^
137144
-DCMAKE_CUDA_ARCHITECTURES=all ^
138145
-DWHISPER_SDL2=${{ matrix.sdl2 }} ^
146+
-DCMAKE_CUDA_COMPILER="%CD%\nvcc-sccache.bat" ^
139147
-DCMAKE_CUDA_COMPILER_LAUNCHER=sccache ^
140148
-DCMAKE_C_COMPILER_LAUNCHER=sccache ^
141149
-DCMAKE_CXX_COMPILER_LAUNCHER=sccache ^

0 commit comments

Comments
 (0)