Qt5 cmake stuff

Alexander Neundorf neundorf at kde.org
Mon May 14 21:30:18 UTC 2012


On Monday 14 May 2012, David Faure wrote:
> On Monday 14 May 2012 23:13:44 Alexander Neundorf wrote:
> > if (NOT TARGET Qt5::Core)
> > 
> >   add_library(Qt5::Core SHARED IMPORTED)
> > 
> > endif()
> 
> Thanks, that works, and is MUCH simpler too ;-)
> 
> Any reason against committing that upstream? 

There was some subtle reason why this can have issues in some cases...
Stephen, what was it exactly ?
It was something with unexpected name clashes IIRC.
We need to be able to notice if somebody accidentially created a target with 
the same name already, and instead of silently not creating the imported 
target, fail. Was that it ?
If this way the reason, I'm not sure how realistic this is when we use 
"namespaced" imported targets as is done here (the "Qt5::").

> Requires a too recent cmake?

No, not at all.

Alex
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20120514/de1a2542/attachment.html>


More information about the Kde-frameworks-devel mailing list