Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hunspellplugin.h:31:23: error: ‘IID’ has not been declared #219

Closed
zhtengw opened this issue Nov 25, 2016 · 6 comments
Closed

hunspellplugin.h:31:23: error: ‘IID’ has not been declared #219

zhtengw opened this issue Nov 25, 2016 · 6 comments

Comments

@zhtengw
Copy link
Contributor

zhtengw commented Nov 25, 2016

After the latest seven commits from 3ea4ed4 , it keeps complaining when compiled:
"
plugins/hunspell/hunspellplugin.h:31:23: error: ‘IID’ has not been declared
Q_PLUGIN_METADATA(IID "org.nixnote.NixNote2.HunspellInterface/2.0");
"

--------------- the full build log --------------

make -j7
x86_64-pc-linux-gnu-g++ -c -O2 -pipe -march=native -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_SQL_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/include/poppler/qt4 -I. -o main.o main.cpp
x86_64-pc-linux-gnu-g++ -c -O2 -pipe -march=native -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_SQL_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/include/poppler/qt4 -I. -o nixnote.o nixnote.cpp
x86_64-pc-linux-gnu-g++ -c -O2 -pipe -march=native -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_SQL_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/include/poppler/qt4 -I. -o global.o global.cpp
x86_64-pc-linux-gnu-g++ -c -O2 -pipe -march=native -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_SQL_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/include/poppler/qt4 -I. -o filemanager.o settings/filemanager.cpp
x86_64-pc-linux-gnu-g++ -c -O2 -pipe -march=native -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_SQL_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/include/poppler/qt4 -I. -o nwebpage.o gui/nwebpage.cpp
x86_64-pc-linux-gnu-g++ -c -O2 -pipe -march=native -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_SQL_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/include/poppler/qt4 -I. -o nwebview.o gui/nwebview.cpp
x86_64-pc-linux-gnu-g++ -c -O2 -pipe -march=native -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_SQL_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/include/poppler/qt4 -I. -o databaseconnection.o sql/databaseconnection.cpp
In file included from ./gui/nbrowserwindow.h:61:0,
from gui/nwebview.h:31,
from gui/nwebview.cpp:21:
./plugins/hunspell/hunspellplugin.h:31:23: error: ‘IID’ has not been declared
Q_PLUGIN_METADATA(IID "org.nixnote.NixNote2.HunspellInterface/2.0");
^
./plugins/hunspell/hunspellplugin.h:31:27: error: expected ‘,’ or ‘...’ before string constant
Q_PLUGIN_METADATA(IID "org.nixnote.NixNote2.HunspellInterface/2.0");
^
./plugins/hunspell/hunspellplugin.h:31:71: error: ISO C++ forbids declaration of ‘Q_PLUGIN_METADATA’ with no type [-fpermissive]
Q_PLUGIN_METADATA(IID "org.nixnote.NixNote2.HunspellInterface/2.0");
^
x86_64-pc-linux-gnu-g++ -c -O2 -pipe -march=native -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_SQL_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/include/poppler/qt4 -I. -o qsdebugoutput.o logger/qsdebugoutput.cpp
x86_64-pc-linux-gnu-g++ -c -O2 -pipe -march=native -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_SQL_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/include/poppler/qt4 -I. -o qslog.o logger/qslog.cpp
In file included from ./gui/nbrowserwindow.h:61:0,
from gui/ntabwidget.h:23,
from nixnote.h:35,
from main.cpp:22:
./plugins/hunspell/hunspellplugin.h:31:23: error: ‘IID’ has not been declared
Q_PLUGIN_METADATA(IID "org.nixnote.NixNote2.HunspellInterface/2.0");
^
./plugins/hunspell/hunspellplugin.h:31:27: error: expected ‘,’ or ‘...’ before string constant
Q_PLUGIN_METADATA(IID "org.nixnote.NixNote2.HunspellInterface/2.0");
^
./plugins/hunspell/hunspellplugin.h:31:71: error: ISO C++ forbids declaration of ‘Q_PLUGIN_METADATA’ with no type [-fpermissive]
Q_PLUGIN_METADATA(IID "org.nixnote.NixNote2.HunspellInterface/2.0");
^
In file included from ./gui/nbrowserwindow.h:61:0,
from gui/ntabwidget.h:23,
from nixnote.h:35,
from nixnote.cpp:20:
./plugins/hunspell/hunspellplugin.h:31:23: error: ‘IID’ has not been declared
Q_PLUGIN_METADATA(IID "org.nixnote.NixNote2.HunspellInterface/2.0");
^
./plugins/hunspell/hunspellplugin.h:31:27: error: expected ‘,’ or ‘...’ before string constant
Q_PLUGIN_METADATA(IID "org.nixnote.NixNote2.HunspellInterface/2.0");
^
./plugins/hunspell/hunspellplugin.h:31:71: error: ISO C++ forbids declaration of ‘Q_PLUGIN_METADATA’ with no type [-fpermissive]
Q_PLUGIN_METADATA(IID "org.nixnote.NixNote2.HunspellInterface/2.0");
^
x86_64-pc-linux-gnu-g++ -c -O2 -pipe -march=native -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -W -D_REENTRANT -DQT_NO_DEBUG -DQT_WEBKIT_LIB -DQT_SQL_LIB -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtWebKit -I/usr/include/qt4 -I/usr/include/poppler/qt4 -I. -o qslogdest.o logger/qslogdest.cpp
Makefile:3372: recipe for target 'nixnote.o' failed
make: *** [nixnote.o] Error 1
make: *** Waiting for unfinished jobs....
Makefile:3611: recipe for target 'nwebview.o' failed
make: *** [nwebview.o] Error 1
Makefile:3223: recipe for target 'main.o' failed
make: *** [main.o] Error 1

@baumgarr
Copy link
Owner

I've migrated to Qt5. Please try compiling against that version.

@zhtengw
Copy link
Contributor Author

zhtengw commented Nov 25, 2016

So, does it mean that it can never be compiled under Qt4 after 2.0_beta10?

@baumgarr
Copy link
Owner

Not the plugins. The structure is different between how Qt4 & Qt5 handles plugins.

@zhtengw
Copy link
Contributor Author

zhtengw commented Nov 28, 2016

thanks @baumgarr , I have tried compiling against Qt5, and it completed without any error. I will update the Gentoo ebuild script then.

@baumgarr
Copy link
Owner

baumgarr commented Dec 6, 2016

Just an FYI, I updated it so it can compile against either Qt4 or Qt5.

@zhtengw
Copy link
Contributor Author

zhtengw commented Dec 7, 2016

Thanks, the commit what you changed in is just what I hacked for compiling against qt4 under gentoo.

@baumgarr baumgarr closed this as completed Dec 8, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants