[Pkg-cmake-team] Bug#1031799: cmake-data: cmake does not search multiarch paths for HIP
Cordell Bloor
cgmb at slerp.xyz
Sun Mar 26 18:23:57 BST 2023
I have been discussing this issue with the upstream developers and have
opened a merge request with a fix [1].
On 2/22/23 15:34, Cordell Bloor wrote:
> It is not possible to use CMake's HIP language support together with
> the Debian package for HIP. Consider this sample project:
>
> CMakeLists.txt:
>
> cmake_minimum_required(VERSION 3.22)
> project(example LANGUAGES HIP)
> add_executable(ex main.hip)
The fix for this issue will require the user to instead write their
CMakeLists.txt as:
cmake_minimum_required(VERSION 3.22)
project(example LANGUAGES CXX HIP)
add_executable(ex main.hip)
CMake needs to load the hip-lang information that is provided by the HIP
runtime before the HIP ABI can be determined, but CMake needs to know
the ABI to determine which multiarch directories so search for the HIP
runtime. Enabling C or CXX before HIP will ensure that the appropriate
architecture is known before starting the search and a warning will be
emitted for projects that do not enable C or CXX before HIP.
Sincerely,
Cory Bloor
[1]: https://gitlab.kitware.com/cmake/cmake/-/merge_requests/8356
More information about the Pkg-cmake-team
mailing list