oneapi-src / level-zero

oneAPI Level Zero Specification Headers and Loader
https://spec.oneapi.com/versions/latest/elements/l0/source/index.html
MIT License
222 stars 98 forks source link

Wrap linker flags on Windows for IntelLLVM #206

Closed Maetveis closed 1 month ago

Maetveis commented 1 month ago

The Intel C++ compiler requires linker flags to be wrapped, because CMake passes them through the compiler driver. Prefix Linker options with ${CMAKE_CXX_LINKER_WRAPPER_FLAG}. This variable is set to the option to pass a linker flag through the compiler driver by CMake. For MSVC and clang-cl or IntelLLVM pre cmake 3.25 this will be empty, so the patch will work in these cases too.

Fixes: #205