[cmake-developers] Deprecating qt4_use_modules and qt4_automoc?

David Cole dlrdave at aol.com
Wed Feb 6 07:58:32 EST 2013


 

 

 

-----Original Message-----
From: Marcus D. Hanwell <marcus.hanwell at kitware.com>
To: Stephen Kelly <steveire at gmail.com>
Cc: cmake-developers <cmake-developers at cmake.org>
Sent: Wed, Feb 6, 2013 7:55 am
Subject: Re: [cmake-developers] Deprecating qt4_use_modules and qt4_automoc?


On Wed, Feb 6, 2013 at 5:46 AM, Stephen Kelly <steveire at gmail.com> wrote:
>
> Hi there,
>
> The qt4_use_modules is now mostly obsoleted by tll in CMake 2.8.11. The main
> difference is that qt4_use_modules does not require the use of imported
> targets.
>
> I think we should deprecate it in favor of using tll() with imported targets
> (using the imported targets is independent of the QT_USE_IMPORTED_TARGETS
> setting, which determines what is in the QT_QTGUI_LIBRARIES and similar
> variables). So we should document
>
>  target_link_libraries(foo PRIVATE Qt4::QtGui)
>
> and similar as the primary way to use Qt 4.
>
> The qt4_automoc macro is obsoleted by the CMAKE_AUTOMOC feature. There is no
> equivalent in the Qt 5 cmake macro offering. So, I think we should deprecate
> it too.
>
What do you mean by deprecate it? We have projects that don't require
a recent CMake, and I would rather not add two ways of doing things to
the CMake code. I will certainly use this in newer projects that
require a recent CMake. It would be irritating to see deprecation
notices popping up in our dashboards too, so I would rather see them
continue to be supported.

As there will be no more Qt 4 releases, wouldn't there be a natural
deprecation path as projects move over to Qt 5?

Marcus
--

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




I agree with Marcus. There's no reason to deprecate these (other than deprecating Qt4 entirely, but not yet) unless there's a significant code clarity advantage.

What does it buy us to deprecate these things now?

If you're just trying to point people to the new stuff, just point them to Qt5 examples.


D


 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake-developers/attachments/20130206/7987a1ab/attachment.html>


More information about the cmake-developers mailing list