Re: [pcre-dev] HELP! CMake expert needed

Góra strony
Delete this message
Autor: Giuseppe D'Angelo
Data:  
Dla: pcre-dev
Temat: Re: [pcre-dev] HELP! CMake expert needed
Hi,

On 13 January 2018 at 18:05, <ph10@???> wrote:

> is going to stop working at some point. This is related to two lines
> like
>
> GET_TARGET_PROPERTY(PCRE2TEST_EXE pcre2test DEBUG_LOCATION)
>
> which use a LOCATION property that is not going to be available in some
> future release of CMake. I am very ignorant about CMake and can do only
> minor maintenace of CMakeLists.txt. Upgrading to avoid this problem is
> beyond me. (I googled but didn't find a simple recipe I could follow.)
>
> Is there a CMake expert on this list? If so, I would be very grateful if
> you could take a look at CMakeLists.txt and advise on how to update it
> so that CMAKE_POLICY(SET CMP0026 OLD) is no longer needed. Then we
> won't have a panic in the future when building with CMake stops working.


I've asked to a colleague of mine (Kevin Funk, working on the KDE
project), and his suggestion was to use $<TARGET_FILE:pcre2test> or
possibly $<TARGET_PROPERTY:pcre2test,DEBUG_LOCATION> in a SET
statement (instead of GET_TARGET_PROPRETY); see for instance this diff
https://git.reviewboard.kde.org/r/116090/diff/1/#

Hope this helps,
Giuseppe D'Angelo