[CMake] FindMPI.cmake in 3.11.4
Burlen Loring
burlen.loring at gmail.com
Mon Sep 17 18:49:03 EDT 2018
Thanks, I did not know about the guidelines. I guess my misconception is
based on having seen historically cache variables used in a number of
find modules and also in practice being able to override the module when
needed. So if the outputs of the find module aren't cache variables, how
does one override the module and tell it what to use?
On 09/14/2018 12:30 PM, Mateusz Loskot wrote:
> On Fri, 14 Sep 2018 at 20:57, Burlen Loring <burlen.loring at gmail.com> wrote:
>> why did they MPI_C_LIBRARIES and MPI_C_INCLUDE_DIRS/PATH get changed from cache variables to not chached variables?
> Possibly, that change was due to clean up to correct the module
> according to the actual CMake conventions
>
> https://cmake.org/cmake/help/latest/manual/cmake-developer.7.html#standard-variable-names
>
> """
> Xxx_INCLUDE_DIRS
> The final set of include directories listed in one variable for use
> by client code. This should not be a cache entry.
>
> Xxx_LIBRARIES
> The libraries to link against to use Xxx. These should include full
> paths. This should not be a cache entry.
> """
>
> Also, find_package_handle_standard_args description also gives similar
> hint on the naming:
>
> https://cmake.org/cmake/help/latest/module/FindPackageHandleStandardArgs.html
> """
> Therefore these should typically be cache entries such as FOO_LIBRARY
> and not output variables like FOO_LIBRARIES.
> """
>
> Best regards,
More information about the CMake
mailing list