Closed bartlettroscoe closed 2 years ago
For a longer discussion of why we need to do this, see https://github.com/trilinos/Trilinos/pull/10930#discussion_r954990717.
With the merge of PRs #523 and #524 and the updated snapshot of TriBITS 'master' into Trilinos 'develop' with the merge of PR trilinos/Trilinos#10930, this issue is resolved.
Seems the expected convention for
<Package>Config.cmake
files is to include a call tocmake_minimum_version()
to handle any features of CMake that may need newer policies, likeif (... IN_LIST ...)
. In particular, the example in the book "Professional CMake: 11th edition" shows:This came up due to Kokkos adding extra CMake code to
KokkosConfig_install.cmake
as shown in:https://github.com/trilinos/Trilinos/blob/78aac8eb821d3a9817db214c364353fdda0c0c19/packages/kokkos/cmake/kokkos_install.cmake#L32-L44
None of the TriBITS-generated
<Package>Config.cmake
or<Project>Config.cmake
files is usingif (... IN_LIST ...)
.See more details in SNL internal issue TRILINOSHD-128.