Skip to content

Commit 5447777

Browse files
committed
gha: build - always use OpenCL C/CPP/ICD from Khronos directly
1 parent 82b7ef8 commit 5447777

File tree

1 file changed

+3
-10
lines changed

1 file changed

+3
-10
lines changed

.github/workflows/build.yml

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -171,16 +171,15 @@ jobs:
171171
##################################################################
172172
# OpenCL
173173

174-
# on windows, download and build icd loader, C headers and CPP headers manually, and cache the install folder:
175-
- if: runner.os == 'Windows'
176-
name: Check cache for OpenCL
174+
# Download and build ICD loader, C headers and CPP headers, and cache the install folder:
175+
- name: Check cache for OpenCL
177176
id: cache-opencl
178177
uses: actions/cache@v4
179178
with:
180179
path: opencl-${{ env.OPENCL_VERSION }}
181180
key: ${{ runner.os }}-opencl-${{ env.OPENCL_VERSION }}
182181

183-
- if: ${{ ( runner.os == 'Windows' && steps.cache-opencl.outputs.cache-hit != 'true' ) }}
182+
- if: steps.cache-opencl.outputs.cache-hit != 'true'
184183
name: Install OpenCL
185184
run: |
186185
mkdir opencl
@@ -213,12 +212,6 @@ jobs:
213212
"ITK_CMAKE_OPTIONS=${{env.ITK_CMAKE_OPTIONS}} -DOpenCL_INCLUDE_DIR:PATH=${{github.workspace}}/opencl-${{ env.OPENCL_VERSION }}/include -DOpenCL_LIBRARY:FILEPATH=${{github.workspace}}/opencl-${{ env.OPENCL_VERSION }}/lib/OpenCL.lib" >> $env:GITHUB_ENV
214213
"OPENIA_CMAKE_OPTIONS=${{env.OPENIA_CMAKE_OPTIONS}} -DOpenCLHeaders_DIR:PATH=${{github.workspace}}/opencl-${{ env.OPENCL_VERSION }}/share/cmake/OpenCLHeaders -DOpenCLHeadersCpp_DIR:PATH=${{github.workspace}}/opencl-${{ env.OPENCL_VERSION }}/share/cmake/OpenCLHeadersCpp -DOpenCLICDLoader_DIR:PATH=${{github.workspace}}/opencl-${{ env.OPENCL_VERSION }}/share/cmake/OpenCLICDLoader" >> $env:GITHUB_ENV
215214
216-
# on ubuntu, use apt-installed opencl:
217-
- if: runner.os == 'Linux'
218-
name: Install OpenCL
219-
run: |
220-
sudo apt update && sudo apt install ocl-icd-opencl-dev opencl-headers opencl-clhpp-headers
221-
222215
##################################################################
223216
# ITK
224217

0 commit comments

Comments
 (0)