Opened 5 years ago

Closed 5 years ago

#12409 closed Bug Report - General (fixed)

x86_64 plugins built only after I removed qt4 devel libs on opensuse

Reported by: Yianni Vidalis <yiannividalis@…> Owned by: Stuart Auchterlonie
Priority: minor Milestone: 0.28
Component: Qt5 issues Version: Master Head
Severity: medium Keywords:
Cc: Ticket locked: no

Description

Hi, in ref to #12399 and #12404, I could not build mythplugins on an opensuse atom I have (x86_64). It has the same qt5 packages in number and version with the i586 laptop I was struggling before, and I am using the "qtmake-qt5 mythplugins.pro" command that I was missing before. I've tried distclean, removing the whole mythtv and mythplugins git folders and "git reset --hard", removing all the /usr/{include,lib,share}/mythtv folders without success.

The plugins refuse to build, they crash at mytharchive. The only way I managed to build them was by first removing two qt4 devel packages, more specifically libqt4-devel and libQtWebKit-devel.

I'm afraid I didn't keep the failure messages, but they looked similar to those mentioned in https://code.mythtv.org/trac/ticket/12399#comment:14

Maybe the problem is distro specific, because afterwards I experimented by reinstalling those two packages, removing all the folders (git and installation) and rebuilding both mythtv and plugins *with* success. So I can no longer reproduce the problem. I will try tomorrow with two more opensuse frontends to confirm.

Change History (8)

comment:1 Changed 5 years ago by yiannividalis@…

Yes, the bahaviour is the same on another x86_64 opensuse system. Mythplugins will not build initially.

panayiota@magnum:~/mythtv-git/mythplugins> ./configure --prefix=/usr --enable-mythgallery

Configuration settings:

        qmake          /usr/bin/qmake-qt5

        MythArchive    plugin will be built
        MythBrowser    plugin will be built
        MythGallery    plugin will be built
        MythGame       plugin will be built
        MythMusic      plugin will be built
        MythNetvision  plugin will be built
        MythNews       plugin will be built
        MythWeather    plugin will be built
        MythZoneMinder plugin will be built
        OpenGL         support will be included in MythGallery
        EXIF           support will be included in MythGallery
        Dcraw          support will be included in MythGallery
        libcdio        support will be included in MythMusic
        FFTW v.3       support will be included in MythMusic

panayiota@magnum:~/mythtv-git/mythplugins> make
cd mytharchive/ && ( test -e Makefile || /usr/bin/qmake-qt5 /home/panayiota/mythtv-git/mythplugins/mytharchive/mytharchive.pro QMAKE=/usr/bin/qmake-qt5 -o Makefile ) && make -f Makefile
make[1]: Entering directory '/home/panayiota/mythtv-git/mythplugins/mytharchive'
cd mytharchive/ && ( test -e Makefile || /usr/bin/qmake-qt5 /home/panayiota/mythtv-git/mythplugins/mytharchive/mytharchive/mytharchive.pro QMAKE=/usr/bin/qmake-qt5 -o Makefile ) && make -f Makefile
make[2]: Entering directory '/home/panayiota/mythtv-git/mythplugins/mytharchive/mytharchive'
ccache g++ -c -pipe -march=k8-sse3 -DNDEBUG -fomit-frame-pointer -fPIC -DQT_DISABLE_DEPRECATED_BEFORE -msse -pthread -g -Wall -Wpointer-arith -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -fvisibility-inlines-hidden -Wmissing-declarations -Wno-switch -Woverloaded-virtual -funit-at-a-time -fvisibility=hidden -g -D_REENTRANT -Wall -W -DPIC -fPIC -D_GNU_SOURCE -DPREFIX="/usr" -DMMX -D_FILE_OFFSET_BITS=64 -DMPLUGIN_API -DQT_PLUGIN -DQT_OPENGL_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_XML_LIB -DQT_SQL_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I/usr/include -I/usr/lib64/qt5/mkspecs/linux-g++ -I. -isystem /usr/include -isystem /usr/include/libxml2 -isystem /usr/include/mythtv -isystem /usr/include/mythtv/libmythbase -isystem /usr/include/mythtv/libmythui -isystem /usr/include/mythtv/libmyth -isystem /usr/include/mythtv/libavformat -isystem /usr/include/mythtv/libswscale -isystem /usr/include/qt5 -isystem /usr/include/qt5/QtOpenGL -isystem /usr/include/qt5/QtWidgets -isystem /usr/include/qt5/QtGui -isystem /usr/include/qt5/QtXml -isystem /usr/include/qt5/QtSql -isystem /usr/include/qt5/QtNetwork -isystem /usr/include/qt5/QtCore -I. -o main.o main.cpp
In file included from /usr/include/qt5/QtWidgets/QApplication:1:0,
                 from main.cpp:15:
/usr/include/qt5/QtWidgets/qapplication.h:103:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 0)
                        ^
/usr/include/qt5/QtWidgets/qapplication.h:143:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 0)
                        ^
/usr/include/qt5/QtWidgets/qapplication.h:173:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 0)
                        ^
In file included from /usr/include/qt5/QtSql/QSqlError:1:0,
                 from /usr/include/mythtv/mythdbcon.h:6,
                 from /usr/include/mythtv/mythdb.h:8,
                 from /usr/include/mythtv/mythcorecontext.h:8,
                 from /usr/include/mythtv/mythcontext.h:7,
                 from main.cpp:21:
/usr/include/qt5/QtSql/qsqlerror.h:54:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 3)
                        ^
/usr/include/qt5/QtSql/qsqlerror.h:71:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 3)
                        ^
/usr/include/qt5/QtSql/qsqlerror.h:78:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 1)
                        ^
In file included from /usr/include/qt5/QtCore/QDateTime:1:0,
                 from /usr/include/mythtv/mythdbcon.h:10,
                 from /usr/include/mythtv/mythdb.h:8,
                 from /usr/include/mythtv/mythcorecontext.h:8,
                 from /usr/include/mythtv/mythcontext.h:7,
                 from main.cpp:21:
/usr/include/qt5/QtCore/qdatetime.h:80:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5,0)
                        ^
/usr/include/qt5/QtCore/qdatetime.h:271:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 2)
                        ^
In file included from /usr/include/qt5/QtGui/QRegion:1:0,
                 from /usr/include/mythtv/libmythui/mythuitype.h:5,
                 from /usr/include/mythtv/libmythui/mythuicomposite.h:4,
                 from /usr/include/mythtv/libmythui/mythscreentype.h:4,
                 from /usr/include/mythtv/libmythui/myththemedmenu.h:4,
                 from main.cpp:26:
/usr/include/qt5/QtGui/qregion.h:91:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 0)
                        ^
In file included from /usr/include/qt5/QtGui/QFont:1:0,
                 from /usr/include/mythtv/libmythui/mythuitype.h:9,
                 from /usr/include/mythtv/libmythui/mythuicomposite.h:4,
                 from /usr/include/mythtv/libmythui/mythscreentype.h:4,
                 from /usr/include/mythtv/libmythui/myththemedmenu.h:4,
                 from main.cpp:26:
/usr/include/qt5/QtGui/qfont.h:238:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 3)
                        ^
/usr/include/qt5/QtGui/qfont.h:255:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 0)
                        ^
In file included from /usr/include/qt5/QtWidgets/qabstractitemview.h:39:0,
                 from /usr/include/qt5/QtWidgets/qlistview.h:37,
                 from /usr/include/qt5/QtWidgets/qlistwidget.h:37,
                 from /usr/include/qt5/QtWidgets/QListWidget:1,
                 from /usr/include/mythtv/mythwidgets.h:22,
                 from /usr/include/mythtv/settings.h:14,
                 from archivesettings.h:12,
                 from main.cpp:31:
/usr/include/qt5/QtCore/qitemselectionmodel.h:85:24: error: missing binary operator before token "("
 #if QT_DEPRECATED_SINCE(5, 0)
                        ^
In file included from /usr/include/qt5/QtGui/qguiapplication.h:39:0,
                 from /usr/include/qt5/QtWidgets/qapplication.h:48,
                 from /usr/include/qt5/QtWidgets/QApplication:1,
                 from main.cpp:15:
/usr/include/qt5/QtGui/qinputmethod.h:82:5: error: ‘QLocale’ does not name a type
     QLocale locale() const;
     ^
/usr/include/qt5/QtGui/qinputmethod.h:91:21: error: ‘Qt::InputMethodQueries’ has not been declared
     void update(Qt::InputMethodQueries queries);
                     ^
In file included from /usr/include/qt5/QtWidgets/qapplication.h:48:0,
                 from /usr/include/qt5/QtWidgets/QApplication:1,
                 from main.cpp:15:
/usr/include/qt5/QtGui/qguiapplication.h:85:12: error: ‘QWindowList’ does not name a type
     static QWindowList allWindows();
            ^
/usr/include/qt5/QtGui/qguiapplication.h:86:12: error: ‘QWindowList’ does not name a type
     static QWindowList topLevelWindows();
            ^
/usr/include/qt5/QtGui/qguiapplication.h:138:12: error: ‘QFunctionPointer’ does not name a type
     static QFunctionPointer platformFunction(const QByteArray &function);
            ^
/usr/include/qt5/QtGui/qguiapplication.h:143:12: error: ‘ApplicationState’ in namespace ‘Qt’ does not name a type
     static Qt::ApplicationState applicationState();
            ^
/usr/include/qt5/QtGui/qguiapplication.h:164:38: error: ‘Qt::ApplicationState’ has not been declared
     void applicationStateChanged(Qt::ApplicationState state);
                                      ^
In file included from /usr/include/qt5/QtWidgets/QApplication:1:0,
                 from main.cpp:15:
/usr/include/qt5/QtWidgets/qapplication.h:68:37: error: expected initializer before ‘:’ token
 class Q_WIDGETS_EXPORT QApplication : public QGuiApplication
                                     ^
Makefile:529: recipe for target 'main.o' failed
make[2]: *** [main.o] Error 1
make[2]: Leaving directory '/home/panayiota/mythtv-git/mythplugins/mytharchive/mytharchive'
Makefile:45: recipe for target 'sub-mytharchive-make_first' failed
make[1]: *** [sub-mytharchive-make_first] Error 2
make[1]: Leaving directory '/home/panayiota/mythtv-git/mythplugins/mytharchive'
Makefile:51: recipe for target 'sub-mytharchive-make_first' failed
make: *** [sub-mytharchive-make_first] Error 2

I think I can afford not building the plugins for now, should any developer want me to make further tests. I am sure that if I remove and reinstall the qt4 devel libs, I'll be able to build the plugins without problem, but it will be irreversible.

comment:2 Changed 5 years ago by Stuart Auchterlonie

Component: MythTV - GeneralQt5 issues
Milestone: unknown0.28
Owner: set to Stuart Auchterlonie
Status: newaccepted

I'm not seeing this so far. I've built an opensuse vm with both qt4 and qt5 installed. Master compiled fine, while 0.27 barfed in mytharchive.

Can you share the output of both $ qmake -query $ qmake-qt5 -query

Thanks Stuart

comment:3 Changed 5 years ago by Stuart Auchterlonie

Hmmm, it may well be because you are using prefix=/usr which ends up causing /usr/include to be in the include path before the Qt5 headers, so you get the Qt4 headers which then causes the build to break

comment:4 Changed 5 years ago by yiannividalis@…

panayiota@magnum:~> qmake -query
QT_INSTALL_PREFIX:/usr
QT_INSTALL_DATA:/usr/share/qt4/
QT_INSTALL_DOCS:/usr/share/doc/packages/libqt4
QT_INSTALL_HEADERS:/usr/include
QT_INSTALL_LIBS:/usr/lib64
QT_INSTALL_BINS:/usr/bin
QT_INSTALL_PLUGINS:/usr/lib64/qt4/plugins
QT_INSTALL_IMPORTS:/usr/lib64/qt4/plugins/imports
QT_INSTALL_TRANSLATIONS:/usr/share/qt4/translations
QT_INSTALL_CONFIGURATION:/etc/settings
QT_INSTALL_EXAMPLES:/usr/lib64/qt4/examples
QT_INSTALL_DEMOS:/usr/lib64/qt4/demos
QMAKE_MKSPECS:/usr/share/qt4//mkspecs
QMAKE_VERSION:2.01a
QT_VERSION:4.8.6
panayiota@magnum:~> qmake-qt5 -query
QT_SYSROOT:
QT_INSTALL_PREFIX:/usr
QT_INSTALL_ARCHDATA:/usr/lib64/qt5
QT_INSTALL_DATA:/usr/share/qt5
QT_INSTALL_DOCS:/usr/share/doc/packages/qt5
QT_INSTALL_HEADERS:/usr/include/qt5
QT_INSTALL_LIBS:/usr/lib64
QT_INSTALL_LIBEXECS:/usr/lib64/qt5/libexec
QT_INSTALL_BINS:/usr/lib64/qt5/bin
QT_INSTALL_TESTS:/usr/tests
QT_INSTALL_PLUGINS:/usr/lib64/qt5/plugins
QT_INSTALL_IMPORTS:/usr/lib64/qt5/imports
QT_INSTALL_QML:/usr/lib64/qt5/qml
QT_INSTALL_TRANSLATIONS:/usr/share/qt5/translations
QT_INSTALL_CONFIGURATION:/etc/xdg
QT_INSTALL_EXAMPLES:/usr/lib64/qt5/examples
QT_INSTALL_DEMOS:/usr/lib64/qt5/examples
QT_HOST_PREFIX:/usr
QT_HOST_DATA:/usr/lib64/qt5
QT_HOST_BINS:/usr/lib64/qt5/bin
QT_HOST_LIBS:/usr/lib64
QMAKE_SPEC:linux-g++
QMAKE_XSPEC:linux-g++
QMAKE_VERSION:3.0
QT_VERSION:5.4.0

And my initial assumption that reinstalling the qt4 devel libraries would not crash the plugins built were not entirely correct: a simple "make" will not fail, but after distclean I cannot build the plugins unless I remove the libraries (tried it on the laptop I first observed it)

comment:5 Changed 5 years ago by Stuart Auchterlonie

Okay, reproduced it. It occurs when you set prefix=/usr because then the Qt4 headers get picked up as a consequence of finding the "installed" mythtv headers under /usr/include

Out of curiosity, which opensuse version are you running? i've installed 13.2 and it installed qt5 version 5.3.2

comment:6 Changed 5 years ago by yiannividalis@…

yianni@eagle1:~/mythtv-git/mythplugins> cat /etc/SuSE-release 
openSUSE 20150227 (i586)
VERSION = 20150227
CODENAME = Tumbleweed
# /etc/SuSE-release is deprecated and will be removed in the future, use /etc/os-release instead
yianni@eagle1:~/mythtv-git/mythplugins> cat /etc/os-release 
NAME=openSUSE
VERSION="20150227 (Tumbleweed)"
VERSION_ID="20150227"
PRETTY_NAME="openSUSE 20150227 (Tumbleweed) (i586)"
ID=opensuse
ANSI_COLOR="0;32"
CPE_NAME="cpe:/o:opensuse:opensuse:20150227"
BUG_REPORT_URL="https://bugs.opensuse.org"
HOME_URL="https://opensuse.org/"
ID_LIKE="suse"

I use the rolling release, which as far as I understand IS opensuse at the moment. The oss repo is http://ftp.halifax.rwth-aachen.de/opensuse/factory/repo/oss and the non-oss is at http://ftp.halifax.rwth-aachen.de/opensuse/factory/repo/non-oss

comment:7 Changed 5 years ago by yiannividalis@…

The info on the previous comment is from the laptop, but all pcs have the same repos setup. I actually rsync it locally and install from nfs.

comment:8 Changed 5 years ago by Stuart Auchterlonie <stuarta@…>

Resolution: fixed
Status: acceptedclosed

In 0b0a228bb7a8e34e1463704e1fe8f2bf5f3470d2/mythtv:

Fixes #12409. Don't add /usr/include to the INCLUDEPATH in the plugins

Note: See TracTickets for help on using tickets.