Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 646666

Summary: net-wireless/gqrx-2.9 - .../work/gqrx-2.9/src/applications/gqrx/mainwindow.h:123:5: error: ‘QSvgWidget’ does not name a type
Product: Gentoo Linux Reporter: Alessandro Di Federico <ale>
Component: Current packagesAssignee: Rick Farina (Zero_Chaos) <zerochaos>
Status: RESOLVED DUPLICATE    
Severity: normal CC: ale, radio
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Alessandro Di Federico 2018-02-05 13:29:44 UTC
The build error is the following:

---
cmake -C /var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9_build/gentoo_common_config.cmake -G Unix Makefiles -DCMAKE_INSTALL_PREFIX=/usr -DLINUX_AUDIO_BACKEND=Pulseaudio
 -DCMAKE_BUILD_TYPE=Gentoo -DCMAKE_USER_MAKE_RULES_OVERRIDE=/var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9_build/gentoo_rules.cmake -DCMAKE_TOOLCHAIN_FILE=/var/tmp/por
tage/net-wireless/gqrx-2.9/work/gqrx-2.9_build/gentoo_toolchain.cmake  /var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9
...
In file included from /var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/mainwindow.cpp:49:0:
/var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/mainwindow.h:123:5: error: ‘QSvgWidget’ does not name a type
     QSvgWidget      *qsvg_dummy;
     ^~~~~~~~~~
In file included from /var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/main.cpp:42:0:
/var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/mainwindow.h:123:5: error: ‘QSvgWidget’ does not name a type
     QSvgWidget      *qsvg_dummy;
---

Adding in src/applications/gqrx/mainwindow.h:

#undef QT_NO_WIDGETS

Before:

#include <QSvgWidget>

seems to solve the problem.

This behavior seems to be due to how qtcore is built:

https://gitweb.gentoo.org/repo/gentoo.git/tree/eclass/qt5-build.eclass#n687

Which leads /usr/include/qt5/QtCore/qconfig.h to contain:

#define QT_NO_WIDGETS true

Not sure what's the appropriate solution here.
Comment 1 imese 2018-02-06 20:15:19 UTC
I have the same problem on two devices. Plus more errors which seem to be related.

I also tried the solution by editing mainwindow.h -- not work for me.


...
In file included from /var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/mainwindow.cpp:49:0:
/var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/mainwindow.h:123:5: error: ‘QSvgWidget’ does not name a type; did you mean ‘QWidget’?
     QSvgWidget      *qsvg_dummy;
     ^~~~~~~~~~
     QWidget
...


/var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/mainwindow.cpp: In constructor ‘MainWindow::MainWindow(QString, bool, QWidget*)’:
/var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/mainwindow.cpp:324:5: error: ‘qsvg_dummy’ was not declared in this scope
     qsvg_dummy = new QSvgWidget();
     ^~~~~~~~~~
/var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/mainwindow.cpp:324:22: error: expected type-specifier before ‘QSvgWidget’
     qsvg_dummy = new QSvgWidget();
                      ^~~~~~~~~~
/var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/mainwindow.cpp: In destructor ‘virtual MainWindow::~MainWindow()’:
/var/tmp/portage/net-wireless/gqrx-2.9/work/gqrx-2.9/src/applications/gqrx/mainwindow.cpp:379:12: error: ‘qsvg_dummy’ was not declared in this scope
     delete qsvg_dummy;
            ^~~~~~~~~~
...
Comment 2 imese 2018-02-13 22:12:13 UTC
Problem solved here:
https://bugs.gentoo.org/646504
Comment 3 Chris Reffett (RETIRED) gentoo-dev Security 2018-02-13 22:50:13 UTC

*** This bug has been marked as a duplicate of bug 646504 ***