Brad King wrote:
>> We can then wrap that macro with some Qt related stuff like this:
>>
>> macro(qt5_use_package _target _package)
>> cmake_use_package(${_target} Qt5${_package} ${ARGN})
>
> For now I suggest keeping everything inside the qt5_use_package macro.
> After it matures there we can always refactor it out later, but you
> need to be able to fix things for Qt without waiting for CMake's
> release schedule.
Yes, currently it is just being developed in a unit test anyway, but we
might eventually be able to make it public API (would require target include
directories, so 2.8.8 anyway).
Trying it out there should be useful, but I'd like to develop in parallel
the ideas for how CMake is going to involve regarding this kind of stuff.
>
>> get_property(_target_type TARGET ${_target} PROPERTY TYPE)
>> if ("${_target_type}" STREQUAL "EXECUTABLE")
>> # TODO: How can I ensure this is done only once?
>> target_link_libraries(${_target} ${Qt5Core_WINMAIN_LIBRARY})
>
> Set a property on the target that records whether it has already
> been done.
>
Thanks! I'll use that technique.
Steve.
--
Powered by www.kitware.com
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers