Summary: | dev-qt/qtcore-5.9.4: breakage from change in QT_NO_WIDGETS after update | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Holger Hoffstätte <holger> |
Component: | Current packages | Assignee: | Qt Bug Alias <qt> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | ale, arthur, asturm, esigra, extraconan1, jouni.kosonen, mgmadden, nickAristocrates, orzel, phantom4, public+gentoo, rauchwolke, rion4ik, rnddim, soprwa, toralf, venerix, zeekec |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: | A tiny change to the QtCore and QtWidgets ebuilds to correct the QT_NO_WIDGETS-related problems |
Description
Holger Hoffstätte
2018-02-03 19:01:06 UTC
Just tried to compile QtCreator-4.5.0. Same error. # grep QT_NO_WIDGETS -r /usr/include/qt5 /usr/include/qt5/QtCore/qconfig.h:#define QT_NO_WIDGETS true /usr/include/qt5/QtSvg/qgraphicssvgitem.h:#if !defined(QT_NO_GRAPHICSVIEW) && !defined(QT_NO_WIDGETS) imageviewerfile.cpp:109:54: error: invalid use of incomplete type ‘class QGraphicsSvgItem’ after commenting out "#define QT_NO_WIDGETS true" (and just in case rebuilding some qt gui libs) I was able to build net-im/psi and QtCreator-4.5.0. *** Bug 646574 has been marked as a duplicate of this bug. *** (In reply to Rion from comment #2) > after commenting out "#define QT_NO_WIDGETS true" (and just in case > rebuilding some qt gui libs) I was able to build net-im/psi and > QtCreator-4.5.0. same for me, it worked after rebuilding all qt related libs Workaround of commenting out the #define and rebuilding effected libraries works for me as well... My problem was with kde-frameworks/kjsembed-5.42.0 not finding QSvgWidget *** Bug 646612 has been marked as a duplicate of this bug. *** This also breaks building PyQt5-5.9.2[svg] as none of the QSvgWidget classes end up being defined.
> /var/tmp/portage/dev-python/PyQt5-5.9.2/work/PyQt5_gpl-5.9.2-python2_7/QtSvg/sipQtSvgQSvgWidget.cpp:237:1: error: expected class-name before ‘{’ token
> {
> ^
> /var/tmp/portage/dev-python/PyQt5-5.9.2/work/PyQt5_gpl-5.9.2-python2_7/QtSvg/sipQtSvgQSvgWidget.cpp: In constructor ‘sipQSvgWidget::sipQSvgWidget(QWidget*)’:
I can confirm the issue. In my case net-wireless/gqrx didn't compile until I removed #define QT_NO_WIDGETS true from the qconfig.h. *** Bug 646700 has been marked as a duplicate of this bug. *** After commenting "#define QT_NO_WIDGETS true" in the file qconfig.h , I find that kde-frameworks/kjsembed doesn't compile. It errors out with the following: CMakeFiles/KF5JsEmbed.dir/svg_binding.cpp.o: In function `KJSEmbed::SvgWidget::bindMethod(KJS::ExecState*, KJSEmbed::PointerBase&)': svg_binding.cpp:(.text+0xef): undefined reference to `QSvgWidget::staticMetaObject' CMakeFiles/KF5JsEmbed.dir/svg_binding.cpp.o: In function `SvgWidgetNS::renderer(KJS::ExecState*, KJS::JSObject*, KJS::List const&)': svg_binding.cpp:(.text+0x432): undefined reference to `QSvgWidget::staticMetaObject' svg_binding.cpp:(.text+0x444): undefined reference to `QSvgWidget::renderer() const' CMakeFiles/KF5JsEmbed.dir/svg_binding.cpp.o: In function `KJSEmbed::SvgWidget::ctorMethod(KJS::ExecState*, KJS::List const&)': svg_binding.cpp:(.text+0x1083): undefined reference to `QSvgWidget::QSvgWidget(QWidget*)' svg_binding.cpp:(.text+0x10ed): undefined reference to `QSvgWidget::QSvgWidget(QWidget*)' svg_binding.cpp:(.text+0x1172): undefined reference to `QSvgWidget::QSvgWidget(QString const&, QWidget*)' collect2: error: ld returned 1 exit status (In reply to Thomas Mori from comment #10) > After commenting "#define QT_NO_WIDGETS true" in the file qconfig.h , I find > that kde-frameworks/kjsembed doesn't compile. It errors out with the > following: Thomas, if you manually comment that out, you need to rebuild dev-qt/qtsvg to make it work. Just do as the others have done. Another dirty workaround is to comment out the line which caused this in qt5-build.eclass: $([[ ${QT5_MINOR_VERSION} -ge 9 ]] && echo -no-gui -no-widgets) Then rebuild (minimum) dev-qt/qtcore and dev-qt/qtsvg. I usually prefer to rebuild all dev-qt/* packages when messing about in QtCore. Created attachment 518042 [details, diff]
A tiny change to the QtCore and QtWidgets ebuilds to correct the QT_NO_WIDGETS-related problems
This patch to qtcore-5.9.4.ebuild and qtwidgets-5.9.4.ebuild adds a single item to each that makes the QT_NO_WIDGETS problem go away. It does this *while preserving* the original intent of the Qt base splitting in qt5-build.eclass. The ebuild changes in the patch simply add one more macro when QtWidgets registers itself on installation. This should be all that's needed for a -r release to fix this bug without having to revisit the eclass.
If anyone decides to try out these little updates to the ebuilds, remember to rebuild (at *minimum*) dev-qt/qtcore, dev-qt/qtwidgets, and dev-qt/qtsvg. Doing that resolved the problem for me (and now I get to rebuild the rest of Qt, yay). Note that you *will* still see a QT_NO_WIDGETS line in qconfig.h, but there will be an "#undef QT_NO_WIDGETS" further down in the file due to the logic in QtCore's ebuild.
*** Bug 646732 has been marked as a duplicate of this bug. *** I am not sure if it is related, but I am unable to compile kde-apps/gwenview because of error: "/var/tmp/portage/kde-apps/gwenview-17.12.1/work/gwenview-17.12.1/lib/documentview/svgviewadapter.cpp: In constructor ‘Gwenview::SvgImageView::SvgImageView(QGraphicsItem*)’: /var/tmp/portage/kde-apps/gwenview-17.12.1/work/gwenview-17.12.1/lib/documentview/svgviewadapter.cpp:45:37: error: invalid use of incomplete type ‘class QGraphicsSvgItem’ , mSvgItem(new QGraphicsSvgItem(this)) [...]" The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2e134cfc5ca0b1ef24116749340c4a5d08d1bf66 commit 2e134cfc5ca0b1ef24116749340c4a5d08d1bf66 Author: Michael Palimaka <kensington@gentoo.org> AuthorDate: 2018-02-06 12:27:28 +0000 Commit: Michael Palimaka <kensington@gentoo.org> CommitDate: 2018-02-06 12:28:38 +0000 dev-qt/qtsvg: revision bump fixes missing widgets support Bug: https://bugs.gentoo.org/646504 Package-Manager: Portage-2.3.19, Repoman-2.3.6 dev-qt/qtsvg/{qtsvg-5.9.4.ebuild => qtsvg-5.9.4-r1.ebuild} | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f8b4f8629732b2f10945fd03e6918e8d69c25805 commit f8b4f8629732b2f10945fd03e6918e8d69c25805 Author: Psi <public+gentoo@psionix.net> AuthorDate: 2018-02-06 12:25:25 +0000 Commit: Michael Palimaka <kensington@gentoo.org> CommitDate: 2018-02-06 12:28:37 +0000 dev-qt/qtwidgets: revision bump adds widgets to QT5_GENTOO_CONFIG Bug: https://bugs.gentoo.org/646504 Package-Manager: Portage-2.3.19, Repoman-2.3.6 dev-qt/qtwidgets/{qtwidgets-5.9.4.ebuild => qtwidgets-5.9.4-r1.ebuild} | 1 + 1 file changed, 1 insertion(+) https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=48ab23f11742e4c6585470d96c350b0a939cf1d4 commit 48ab23f11742e4c6585470d96c350b0a939cf1d4 Author: Psi <public+gentoo@psionix.net> AuthorDate: 2018-02-06 12:24:11 +0000 Commit: Michael Palimaka <kensington@gentoo.org> CommitDate: 2018-02-06 12:28:37 +0000 dev-qt/qtcore: revision bump adds support for mangling QT_NO_WIDGETS Bug: https://bugs.gentoo.org/646504 Package-Manager: Portage-2.3.19, Repoman-2.3.6 dev-qt/qtcore/{qtcore-5.9.4.ebuild => qtcore-5.9.4-r1.ebuild} | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)} The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/proj/qt.git/commit/?id=dfc5f67f13306a3bf15fbbbc58fcac15546bc093 commit dfc5f67f13306a3bf15fbbbc58fcac15546bc093 Author: Psi <public+gentoo@psionix.net> AuthorDate: 2018-02-06 12:31:50 +0000 Commit: Michael Palimaka <kensington@gentoo.org> CommitDate: 2018-02-06 12:32:30 +0000 dev-qt/qtwidgets: add widgets to widgets to QT5_GENTOO_CONFIG Bug: https://bugs.gentoo.org/646504 Package-Manager: Portage-2.3.19, Repoman-2.3.6 dev-qt/qtwidgets/qtwidgets-5.10.0.ebuild | 1 + dev-qt/qtwidgets/qtwidgets-5.10.9999.ebuild | 1 + dev-qt/qtwidgets/qtwidgets-5.11.9999.ebuild | 1 + dev-qt/qtwidgets/qtwidgets-5.9.9999.ebuild | 1 + dev-qt/qtwidgets/qtwidgets-5.9999.ebuild | 1 + 5 files changed, 5 insertions(+) https://gitweb.gentoo.org/proj/qt.git/commit/?id=6d5b33f7c7c9cd0aaaab791313a3946caedc7dd9 commit 6d5b33f7c7c9cd0aaaab791313a3946caedc7dd9 Author: Psi <public+gentoo@psionix.net> AuthorDate: 2018-02-06 12:30:29 +0000 Commit: Michael Palimaka <kensington@gentoo.org> CommitDate: 2018-02-06 12:32:30 +0000 dev-qt/qtcore: add support for mangling QT_NO_WIDGETS Bug: https://bugs.gentoo.org/646504 Package-Manager: Portage-2.3.19, Repoman-2.3.6 dev-qt/qtcore/qtcore-5.10.0.ebuild | 8 ++++---- dev-qt/qtcore/qtcore-5.10.9999.ebuild | 8 ++++---- dev-qt/qtcore/qtcore-5.11.9999.ebuild | 8 ++++---- dev-qt/qtcore/qtcore-5.9.9999.ebuild | 4 ++-- dev-qt/qtcore/qtcore-5.9999.ebuild | 4 ++-- 5 files changed, 16 insertions(+), 16 deletions(-)} Apologies for the delay in attending to this, I was away. Thank-you Psi for the patch, it saved a lot of time in getting this landed. (In reply to Michael Palimaka (kensington) from comment #17) > Apologies for the delay in attending to this, I was away. > > Thank-you Psi for the patch, it saved a lot of time in getting this landed. Did the revbump, rebuilt psi just as before, all working. \o/ Thanks! Yes, that was the reason of gwenview compilig error. Thank you very much. *** Bug 646848 has been marked as a duplicate of this bug. *** *** Bug 647224 has been marked as a duplicate of this bug. *** Hi, I've had a build failure of kde-frameworks/kjsembed-5.43.0 against dev-qt/qtsvg-5.10.0. In file included from /var/tmp/portage/kde-frameworks/kjsembed-5.43.0/work/kjsembed-5.43.0/src/kjsembed/kjsembed.cpp:23:0: /var/tmp/portage/kde-frameworks/kjsembed-5.43.0/work/kjsembed-5.43.0/src/kjsembed/svg_binding.h:34:25: error: ‘QSvgWidget’ has not been declared KJSO_BINDING(SvgWidget, QSvgWidget, QWidgetBinding) Same deal as before, got it to build by patching '#undef QT_NO_WIDGETS' into kjsembed. However, a revbump for qtsvg-5.10.0 seems in order... Never mind, the fix is already in place, rebuilding qtcore+qtwidgets did the trick. *** Bug 646666 has been marked as a duplicate of this bug. *** *** Bug 649898 has been marked as a duplicate of this bug. *** |