Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Qt 5.5 (Q_ENUM causing compile error)

Tags:

qt

qt5.5

I've just upgraded Qt from 5.3.2 to 5.5.0. A project (which uses QAbstractTableModel) which compiles just fine in 5.3.2 does not compile in 5.5.0, reporting the following error (numerous times):

/usr/local/Qt-5.5.0/include/QtCore/qabstractitemmodel.h:241: error: ISO C++     forbids declaration of 'Q_ENUM' with no type [-fpermissive]
     Q_ENUM(LayoutChangeHint)
                        ^

The errors are entirely in Qt's files, not mine. I'm using gcc491. Below is a few interesting bits from my project file. Any ideas?

TEMPLATE = app
TARGET = MyApp
QT += core widgets gui
QMAKE_CXXFLAGS += -g -std=c++11
like image 841
kiss-o-matic Avatar asked Aug 14 '26 01:08

kiss-o-matic


1 Answers

Bonehead move. In QtCreator I pointed to the 5.5.0 version of qmake, but in the .project file 5.3.2 was still in the INCLUDEPATH.

like image 108
kiss-o-matic Avatar answered Aug 16 '26 20:08

kiss-o-matic