Brad King wrote:

> On 09/20/2013 08:54 AM, Stephen Kelly wrote:
>> Brad King wrote:
>>> Other than the TYPE being a different name, how would CMake
>>> treat this target type differently?
>>
>> So the answer is, 'probably nothing'.
> 
> In that case I do not think we can justify a special CMake
> target type for it.  All the special cases for STATIC_LIBRARY
> targets will have to be updated to also account for the new
> type with no difference in logic.

Ok. If I don't ask I don't get :).


> add_library(mystatic_library STATIC foo.cpp)
> set_property(TARGET mystatic_library PROPERTY QT_STATICPLUGIN 1)
> target_link_libraries(mystatic_library Qt5::Core)

Yes, but I don't think that's better than

 add_library(mystatic_library STATIC foo.cpp)
 target_compile_definitions(mystatic_library PRIVATE QT_STATICPLUGIN)
 target_link_libraries(mystatic_library Qt5::Core)

I guess that's what I should recommend.

Thanks,

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

Reply via email to