[Qgis-developer] OSGEO4W vs. Mac OS X Qt version (or ~34 plugins slightly broken)

William Kyngesburye woklist at kyngchaos.com
Thu May 10 17:06:47 PDT 2012

On May 10, 2012, at 6:40 PM, Larry Shaffer wrote:

> > I haven't included Qt3Support since QGIS 1.2, when the last of the Qt3 usage was removed (I think GRASS plugin was the last holdout).
> >
> > I'm referring to Qt4 being compiled with the legacy '-qt3support' option (supposedly on by default [0]), not direct Qt3 support (frameworks, etc). Recently, when there was an issue with QWebKit on 10.6, you posted a configure line for compiling Qt4 to fix the problem [1]. I noted that you chose the '-no-qt3support' option. Is that the same Qt you used for bundling the recent QGIS 1.7.4-x? Had you nixed -qt3support in past builds, or used Nokia's pre-compiled Qt4 builds with '-qt3support'?
> >
> > [0] http://qt-project.org/doc/qt-4.8/configure-options.html
> > [1] http://osgeo-org.1560.n6.nabble.com/OS-X-QtWebKit-problem-fixed-PyQwt-still-broken-td4513113.html#a4519323
> >
> "Qt3Support" is the library/framework you get with the qt3support compile option.  I don't think there is anything extra in the other frameworks/libraries when you compile with this option.
> Thank you for the clarification on the Qt3Support framework.
> OK, I think I've figured it out. When compiling Qt, and setting the -qt3support option, the variable QT3_SUPPORT is set [0]. While this is expected to produce the Qt3Support framework, it also affects the build of Qt4 frameworks in ~580 places (results of search for '#ifdef QT3_SUPPORT' in src directory [1]). This includes QAction, which is reverted to emitting the activated() signal again [2][3].
> The upshot of this is PyQt4, when compiled against a Qt4 build with the -qt3support option, will have that support, regardless (I think) of whether the Qt3Support framework is included in the Mac app bundle or not.
Not very nice of the Qt devs to hide such support in the other frameworks.

> So, I'm guessing that when you compiled Qt to fix the QWebKit issue (with no -qt3support option) you truly nixed the Qt3 support, as expected. BTW, I think this is good: it will ferret-out the current plugins still relying upon legacy Qt3 code (unfortunately only on Mac, causing some confusion for users).

anyways, I am using the Qt 4.8.1 binaries from Nokia.  It was only 4.8.0 that I had to compile my own.  So the current 1.7.4-4 and 3/11 dev build on my site have the latest Qt presumably with Qt3 "support", just not the unneeded Qt3Support framework.

> I tried on OSX 10.7, I'll try it this evening on OSX 10.6 when I get home.
> I tried with 1.7.4-4 on 10.7 and 10.6.8 with same results: no launching of plugins. It works with my nightly builds of QGIS (1.8 RC1), which are bundled with '-D QGIS_MACAPP_BUNDLE=2', i.e. app does not contain the Qt3Support framework, but PyQt4 still supports the Qt3 deprecated features (as noted above), allowing all of the affected plugins to launch [4].

Here's what I found, now.  Both the 1.7.4 and dev builds on my site fail to run the spatialquery plugin.  When it worked for me earlier today, that was a more recent dev build on my Mac that I haven't packaged.  So something has changed since 3/11, as you found in your own recent dev builds.

William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>

Theory of the Universe

There is a theory which states that if ever anyone discovers exactly what the universe is for and why it is here, it will instantly disappear and be replaced by something even more bizarrely inexplicable.  There is another theory which states that this has already happened.

-Hitchhiker's Guide to the Galaxy 2nd season intro

More information about the Qgis-developer mailing list