Skip to content

Commit c44f3d7

Browse files
committed
Add Intel oneAPI setup for OpenMP in GitHub Actions
Integrated Intel oneAPI into the workflow to enable OpenMP support for the project. Updated CMake configuration to include necessary OpenMP flags and library paths. This ensures compatibility with Intel's OpenMP runtime for improved parallelization.Simplify Intel oneAPI setup in CI workflow Removed the explicit `rscohn2/setup-oneapi` action and streamlined the OpenMP configuration directly within the CMake command. This reduces external dependencies while maintaining compatibility with Intel's oneAPI tools.
1 parent ba1ba02 commit c44f3d7

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

.github/workflows/main.yml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -814,21 +814,24 @@ jobs:
814814
uses: ilammy/msvc-dev-cmd@v1
815815
- name: CMake configure
816816
run: >
817-
cmake -S . -B build -G Ninja -D CMAKE_C_COMPILER=clang-cl -DCMAKE_CXX_COMPILER=clang-cl
818-
-D CMAKE_C_COMPILER_LAUNCHER=ccache -D CMAKE_CXX_COMPILER_LAUNCHER=ccache
819-
-D CMAKE_BUILD_TYPE=RELEASE -DCMAKE_INSTALL_PREFIX=install
817+
cmake -S . -B build -G Ninja
818+
-D CMAKE_C_COMPILER=clang-cl
819+
-D CMAKE_CXX_COMPILER=clang-cl
820+
-D CMAKE_C_COMPILER_LAUNCHER=ccache
821+
-D CMAKE_CXX_COMPILER_LAUNCHER=ccache
822+
-D CMAKE_BUILD_TYPE=Release
823+
-D CMAKE_INSTALL_PREFIX=install
824+
-D CMAKE_CXX_FLAGS="/clang:-fopenmp=libiomp5 /I\"C:/Program Files (x86)/Intel/oneAPI/compiler/latest/windows/include\" /link /LIBPATH:\"C:/Program Files (x86)/Intel/oneAPI/compiler/latest/windows/lib/intel64_win\" libiomp5md.lib"
820825
env:
821826
CC: clang-cl
822827
CXX: clang-cl
823828
- name: Build project
824-
run: |
825-
cmake --build build --config Release --parallel
829+
run: cmake --build build --config Release --parallel
826830
env:
827831
CC: clang-cl
828832
CXX: clang-cl
829833
- name: Install project
830-
run: |
831-
cmake --install build
834+
run: cmake --install build
832835
- name: Archive installed package
833836
run: Compress-Archive -Path install -DestinationPath windows-clang-install.zip
834837
shell: pwsh

0 commit comments

Comments
 (0)