[CMake] CMP0022 not set

Jack Stalnaker omnijack at gmail.com
Wed Nov 11 16:51:06 EST 2015


I'm getting a new warning from cmake version 2.8.12

Policy CMP0022 is not set: INTERFACE_LINK_LIBRARIES defines the link
interface. etc...

Target "xxx" has an INTERFACE_LINK_PROPERTIES property ...

I've not set this property anywhere explicitly. I'm getting the warning
from a target_link_libraries call where the library is a target defined in
the same CMakeLists.txt file. Why am I getting this warning?

Furthermore, if I set the cmake_policy as requested, I still get the same
warning, with the same message that the cmake_policy has not been set. I do:
cmake_policy (SET CMP0022 NEW)
cmake_policy (GET CMP0022 Foo)
message (STATUS "${Foo}")

The message shows that CMP0022 is NEW, yet I still get the message that its
undefiined. What am I doing wrong?

--Jack
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20151111/cb997962/attachment.html>


More information about the CMake mailing list