QupZilla / qupzilla

Cross-platform Qt web browser
http://www.qupzilla.com
GNU General Public License v3.0
1.12k stars 348 forks source link

Cannot compile with Qt 5.10 #2515

Closed pavbaranov closed 6 years ago

pavbaranov commented 6 years ago

Qt 5.10 is just round the corner, but there isn't possible to compile Qupzilla against of Qt5.10 (now RC2). I know, that there is closed issue: https://github.com/QupZilla/qupzilla/issues/2487 with commit 1409b56, but it doesn't work. This is last few lines from make:

In file included from /usr/include/qt/QtWidgets/qtoolbutton.h:45:0,
                 from /usr/include/qt/QtWidgets/QToolButton:1,
                 from tools/mactoolbutton.h:45,
                 from ../../build/ui_searchtoolbar.h:22,
                 from webtab/searchtoolbar.cpp:22:
/usr/include/qt/QtWidgets/qabstractbutton.h:87:10: note: candidate: void QAbstractButton::setShortcut(const QKeySequence&)
     void setShortcut(const QKeySequence &key);
          ^~~~~~~~~~~
/usr/include/qt/QtWidgets/qabstractbutton.h:87:10: note:   no known conversion for argument 1 from 'QLatin1String' to 'const QKeySequence&'
In file included from webtab/searchtoolbar.cpp:22:0:
../../build/ui_searchtoolbar.h:86:50: error: no matching function for call to 'MacToolButton::setShortcut(QLatin1String)'
         next->setShortcut(QLatin1String("Ctrl+G"));
                                                  ^
In file included from /usr/include/qt/QtWidgets/qtoolbutton.h:45:0,
                 from /usr/include/qt/QtWidgets/QToolButton:1,
                 from tools/mactoolbutton.h:45,
                 from ../../build/ui_searchtoolbar.h:22,
                 from webtab/searchtoolbar.cpp:22:
/usr/include/qt/QtWidgets/qabstractbutton.h:87:10: note: candidate: void QAbstractButton::setShortcut(const QKeySequence&)
     void setShortcut(const QKeySequence &key);
          ^~~~~~~~~~~
/usr/include/qt/QtWidgets/qabstractbutton.h:87:10: note:   no known conversion for argument 1 from 'QLatin1String' to 'const QKeySequence&'
make[1]: *** [Makefile:5816: ../../build/searchtoolbar.o] Error 1
make[1]: Leaving directory '/home/pb/builds/qupzilla-git/src/qupzilla/src/lib'
make: *** [Makefile:47: sub-src-lib-make_first] Error 2
==> ERROR: A failure occurred in build().
    Aborting...
nowrep commented 6 years ago

Alright, but that's bug in Qt ui compiler, the build error is in generated file. Make sure you do clean build, so there are not any leftover files generated with older Qt.

If the problem still persists, please report this on Qt bugtracker.

Chiitoo commented 6 years ago

See my comment in https://github.com/QupZilla/qupzilla/issues/2487#issuecomment-337341988, which at least used to have a working workaround (haven't tried too recently).

It's definitely far from proper, however. :]