Cross compile Qt for RaspberryPi2 - undefined reference
-
Hello everyone, this is my first post here :D
I've been trying to follow this guide https://wiki.qt.io/RaspberryPi2EGLFS to cross compile Qt for the Raspberry Pi 2, so far without success. I'm working on OpenSUSE Tumbleweed x86_64 virtualized on Windows, and i get stuck at point 7: when i launch make in qtbase i get all sorts of "undefined reference to #function" errors, from all kind of libraries. I followed the guide thoroughly and i can't concieve what's possibly wrong. Here's the final part of the output of "sudo make":/home/jekk666/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/arm-linux-gnueabihf-g++ -c -include .pch/Qt5Gui -pipe -march=armv7-a -marm -mthumb-interwork -mfpu=neon-vfpv4 -mtune=cortex-a7 -mabi=aapcs-linux -mfloat-abi=hard --sysroot=/home/jekk666/raspi/sysroot -O3 -std=c++0x -fvisibility=hidden -fvisibility-inlines-hidden -fno-exceptions -Wall -W -D_REENTRANT -fPIC -DQT_NO_XKB -DQT_NO_USING_NAMESPACE -DQT_BUILD_GUI_LIB -DQT_BUILDING_QT -DQT_NO_CAST_TO_ASCII -DQT_ASCII_CAST_WARNINGS -DQT_MOC_COMPAT -DQT_USE_QSTRINGBUILDER -DQT_DEPRECATED_WARNINGS -DQT_DISABLE_DEPRECATED_BEFORE=0x050000 -DQT_ENABLE_HARFBUZZ_NG -DENABLE_PIXMAN_DRAWHELPERS -DQT_NO_EXCEPTIONS -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -DQT_NO_DEBUG -DQT_CORE_LIB -I. -I../../include -I../../include/QtGui -I../../include/QtGui/5.6.0 -I../../include/QtGui/5.6.0/QtGui -I../3rdparty/harfbuzz-ng/include -I../../include/QtCore/5.6.0 -I../../include/QtCore/5.6.0/QtCore -I../../include/QtCore -I.moc -I../../mkspecs/devices/linux-rasp-pi2-g++ -o .obj/moc_qopenglengineshadermanager_p.o .moc/moc_qopenglengineshadermanager_p.cpp rm -f libQt5Gui.so.5.6.0 libQt5Gui.so libQt5Gui.so.5 libQt5Gui.so.5.6 /home/jekk666/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/arm-linux-gnueabihf-g++ -Wl,-rpath-link,/home/jekk666/raspi/sysroot/opt/vc/lib -Wl,-rpath-link,/home/jekk666/raspi/sysroot/usr/lib/arm-linux-gnueabihf -Wl,-rpath-link,/home/jekk666/raspi/sysroot/lib/arm-linux-gnueabihf -mfloat-abi=hard --sysroot=/home/jekk666/raspi/sysroot -Wl,--no-undefined -Wl,--version-script,/home/jekk666/raspi/qtbase/src/gui/QtGui.version -Wl,-O1 -fuse-ld=gold -Wl,--enable-new-dtags -Wl,-z,origin -Wl,-rpath,\$ORIGIN -shared -Wl,-soname,libQt5Gui.so.5 -o libQt5Gui.so.5.6.0 .obj/pixman-arm-neon-asm.o .obj/qdrawhelper_neon_asm.o .obj/qimage_compat.o .obj/qaccessible.o .obj/qaccessiblecache.o .obj/qaccessibleobject.o .obj/qaccessibleplugin.o .obj/qplatformaccessibility.o .obj/qaccessiblebridge.o .obj/qgenericpluginfactory.o .obj/qgenericplugin.o .obj/qwindowsysteminterface.o .obj/qplatforminputcontextfactory.o .obj/qplatforminputcontextplugin.o .obj/qplatforminputcontext.o .obj/qplatformintegration.o .obj/qplatformdrag.o .obj/qplatformscreen.o .obj/qplatformintegrationfactory.o .obj/qplatformintegrationplugin.o .obj/qplatformtheme.o .obj/qplatformthemefactory.o .obj/qplatformthemeplugin.o .obj/qplatformwindow.o .obj/qplatformoffscreensurface.o .obj/qplatformcursor.o .obj/qplatformclipboard.o .obj/qplatformnativeinterface.o .obj/qsessionmanager.o .obj/qshapedpixmapdndwindow.o .obj/qsimpledrag.o .obj/qsurfaceformat.o .obj/qguiapplication.o .obj/qwindow.o .obj/qoffscreensurface.o .obj/qplatformsurface.o .obj/qsurface.o .obj/qclipboard.o .obj/qcursor.o .obj/qdrag.o .obj/qdnd.o .obj/qevent.o .obj/qinputmethod.o .obj/qkeysequence.o .obj/qkeymapper.o .obj/qpalette.o .obj/qguivariant.o .obj/qscreen.o .obj/qshortcutmap.o .obj/qstylehints.o .obj/qtouchdevice.o .obj/qplatformsharedgraphicscache.o .obj/qplatformdialoghelper.o .obj/qplatformservices.o .obj/qplatformsystemtrayicon.o .obj/qplatformsessionmanager.o .obj/qplatformmenu.o .obj/qpixelformat.o .obj/qpaintdevicewindow.o .obj/qrasterwindow.o .obj/qplatformgraphicsbuffer.o .obj/qplatformgraphicsbufferhelper.o .obj/qinputdevicemanager.o .obj/qhighdpiscaling.o .obj/qplatformopenglcontext.o .obj/qopenglcontext.o .obj/qopenglwindow.o .obj/qbitmap.o .obj/qimage.o .obj/qimage_conversions.o .obj/qimageiohandler.o .obj/qimagereader.o .obj/qimagewriter.o .obj/qpaintengine_pic.o .obj/qpicture.o .obj/qpictureformatplugin.o .obj/qpixmap.o .obj/qpixmapcache.o .obj/qplatformpixmap.o .obj/qmovie.o .obj/qpixmap_raster.o .obj/qpixmap_blitter.o .obj/qnativeimage.o .obj/qimagepixmapcleanuphooks.o .obj/qicon.o .obj/qiconloader.o .obj/qiconengine.o .obj/qiconengineplugin.o .obj/qbmphandler.o .obj/qppmhandler.o .obj/qxbmhandler.o .obj/qxpmhandler.o .obj/qpnghandler.o .obj/qfont.o .obj/qfontengine.o .obj/qfontengineglyphcache.o .obj/qfontsubset.o .obj/qfontmetrics.o .obj/qfontdatabase.o .obj/qtextengine.o .obj/qtextlayout.o .obj/qtextformat.o .obj/qtextobject.o .obj/qtextoption.o .obj/qfragmentmap.o .obj/qtextdocument.o .obj/qtextdocument_p.o .obj/qtexthtmlparser.o .obj/qabstracttextdocumentlayout.o .obj/qtextdocumentlayout.o .obj/qtextcursor.o .obj/qtextdocumentfragment.o .obj/qtextimagehandler.o .obj/qtexttable.o .obj/qtextlist.o .obj/qtextdocumentwriter.o .obj/qsyntaxhighlighter.o .obj/qcssparser.o .obj/qzip.o .obj/qtextodfwriter.o .obj/qstatictext.o .obj/qrawfont.o .obj/qglyphrun.o .obj/qdistancefield.o .obj/qfontengine_qpf2.o .obj/qplatformfontdatabase.o .obj/qharfbuzzng.o .obj/qbackingstore.o .obj/qbezier.o .obj/qblendfunctions.o .obj/qblittable.o .obj/qbrush.o .obj/qcolor.o .obj/qcolor_p.o .obj/qcompositionfunctions.o .obj/qcosmeticstroker.o .obj/qcssutil.o .obj/qdrawhelper.o .obj/qemulationpaintengine.o .obj/qgammatables.o .obj/qgrayraster.o .obj/qimagescale.o .obj/qmatrix.o .obj/qmemrotate.o .obj/qoutlinemapper.o .obj/qpagedpaintdevice.o .obj/qpagelayout.o .obj/qpagesize.o .obj/qpaintdevice.o .obj/qpaintengine.o .obj/qpaintengineex.o .obj/qpaintengine_blitter.o .obj/qpaintengine_raster.o .obj/qpainter.o .obj/qpainterpath.o .obj/qpathclipper.o .obj/qpdf.o .obj/qpdfwriter.o .obj/qpen.o .obj/qpolygon.o .obj/qrasterizer.o .obj/qregion.o .obj/qstroker.o .obj/qtextureglyphcache.o .obj/qtransform.o .obj/qplatformbackingstore.o .obj/qpathsimplifier.o .obj/qdesktopservices.o .obj/qvalidator.o .obj/qgridlayoutengine.o .obj/qabstractlayoutstyleinfo.o .obj/qlayoutpolicy.o .obj/qgenericmatrix.o .obj/qmatrix4x4.o .obj/qquaternion.o .obj/qvector2d.o .obj/qvector3d.o .obj/qvector4d.o .obj/qopengl.o .obj/qopenglfunctions.o .obj/qopenglframebufferobject.o .obj/qopenglpaintdevice.o .obj/qopenglbuffer.o .obj/qopenglshaderprogram.o .obj/qopenglgradientcache.o .obj/qopengltexturecache.o .obj/qopenglengineshadermanager.o .obj/qopengl2pexvertexarray.o .obj/qopenglpaintengine.o .obj/qopenglcustomshaderstage.o .obj/qtriangulatingstroker.o .obj/qopengltextureglyphcache.o .obj/qtriangulator.o .obj/qopenglversionfunctions.o .obj/qopenglversionfunctionsfactory.o .obj/qopenglvertexarrayobject.o .obj/qopengldebug.o .obj/qopengltextureblitter.o .obj/qopengltexture.o .obj/qopengltexturehelper.o .obj/qopenglpixeltransferoptions.o .obj/qopenglfunctions_es2.o .obj/qguivariantanimation.o .obj/qstandarditemmodel.o .obj/qimage_neon.o .obj/qdrawhelper_neon.o .obj/moc_qaccessible.o .obj/moc_qaccessiblecache_p.o .obj/moc_qaccessibleplugin.o .obj/moc_qaccessiblebridge.o .obj/moc_qgenericplugin.o .obj/moc_qplatforminputcontext.o .obj/moc_qplatforminputcontextplugin_p.o .obj/moc_qplatformintegrationplugin.o .obj/moc_qplatformthemeplugin.o .obj/moc_qplatformnativeinterface.o .obj/moc_qplatformmenu.o .obj/moc_qshapedpixmapdndwindow_p.o .obj/moc_qoffscreensurface.o .obj/moc_qclipboard.o .obj/moc_qdrag.o .obj/moc_qdnd_p.o .obj/moc_qevent.o .obj/moc_qkeysequence.o .obj/moc_qkeymapper_p.o .obj/moc_qpalette.o .obj/moc_qsessionmanager.o .obj/moc_qscreen.o .obj/moc_qstylehints.o .obj/moc_qtouchdevice.o .obj/moc_qplatformsharedgraphicscache.o .obj/moc_qplatformdialoghelper.o .obj/moc_qpaintdevicewindow.o .obj/moc_qrasterwindow.o .obj/moc_qplatformgraphicsbuffer.o .obj/moc_qinputdevicemanager_p.o .obj/moc_qopenglwindow.o .obj/moc_qimageiohandler.o .obj/moc_qpictureformatplugin.o .obj/moc_qiconengineplugin.o .obj/moc_qfont.o .obj/moc_qfontdatabase.o .obj/moc_qtextformat.o .obj/moc_qtextobject.o .obj/moc_qtextdocument.o .obj/moc_qtextimagehandler_p.o .obj/moc_qtexttable.o .obj/moc_qtextlist.o .obj/moc_qbrush.o .obj/moc_qpainter.o .obj/moc_qpdfwriter.o .obj/moc_qplatformbackingstore.o .obj/moc_qvalidator.o .obj/moc_qopenglshaderprogram.o .obj/moc_qopenglengineshadermanager_p.o -L/home/jekk666/raspi/sysroot/usr/lib/arm-linux-gnueabihf -L/home/jekk666/raspi/qtbase/lib -lQt5Core -lpthread -lpng -lqtharfbuzzng -lz -lGLESv2 .obj/qaccessible.o:qaccessible.cpp:function QAccessibleEvent::accessibleInterface() const: error: undefined reference to 'QDebug::~QDebug()' .obj/qaccessible.o:qaccessible.cpp:function QAccessibleEvent::accessibleInterface() const: error: undefined reference to 'QDebug::~QDebug()' .obj/qaccessible.o:qaccessible.cpp:function QAccessibleEvent::accessibleInterface() const: error: undefined reference to 'QDebug::~QDebug()' .obj/qaccessible.o:qaccessible.cpp:function QAccessibleEvent::accessibleInterface() const: error: undefined reference to 'QDebug::~QDebug()' .obj/qaccessible.o:qaccessible.cpp:function operator<<(QDebug, QAccessibleInterface const*): error: undefined reference to 'QDebug::putString(QChar const*, unsigned int)' .obj/qaccessible.o:qaccessible.cpp:function operator<<(QDebug, QAccessibleInterface const*): error: undefined reference to 'QDebug::putString(QChar const*, unsigned int)' .obj/qgenericpluginfactory.o:qgenericpluginfactory.cpp:function QGenericPluginFactory::create(QString const&, QString const&): error: undefined reference to 'QString::toLower_helper(QString const&)' .obj/qwindowsysteminterface.o:qwindowsysteminterface.cpp:function qt_handleShortcutEvent(QObject*, unsigned long, int, QFlags<Qt::KeyboardModifier>, QString const&, bool, unsigned short): error: undefined reference to 'QCoreApplication::notifyInternal2(QObject*, QEvent*)' .obj/qplatforminputcontextfactory.o:qplatforminputcontextfactory.cpp:function QPlatformInputContextFactory::create(QString const&): error: undefined reference to 'QString::toLower_helper(QString&)' .obj/qplatformtheme.o:qplatformtheme.cpp:function QPlatformTheme::defaultThemeHint(QPlatformTheme::ThemeHint): error: undefined reference to 'qEnvironmentVariableIntValue(char const*, bool*)' .obj/qplatformtheme.o:qplatformtheme.cpp:function QPlatformTheme::defaultThemeHint(QPlatformTheme::ThemeHint): error: undefined reference to 'QMetaType::registerNormalizedType(QByteArray const&, void (*)(void*), void* (*)(void*, void const*), int, QFlags<QMetaType::TypeFlag>, QMetaObject const*)' .obj/qplatformtheme.o:qplatformtheme.cpp:function QPlatformTheme::defaultThemeHint(QPlatformTheme::ThemeHint): error: undefined reference to 'QMetaType::registerNormalizedType(QByteArray const&, void (*)(void*), void* (*)(void*, void const*), int, QFlags<QMetaType::TypeFlag>, QMetaObject const*)' .obj/qplatformtheme.o:qplatformtheme.cpp:function QMetaTypeId<QtMetaTypePrivate::QSequentialIterableImpl>::qt_metatype_id(): error: undefined reference to 'QMetaType::registerNormalizedType(QByteArray const&, void (*)(void*), void* (*)(void*, void const*), int, QFlags<QMetaType::TypeFlag>, QMetaObject const*)' .obj/qplatformtheme.o:qplatformtheme.cpp:function QMetaTypeId<QList<int> >::qt_metatype_id(): error: undefined reference to 'QMetaType::registerNormalizedType(QByteArray const&, void (*)(void*), void* (*)(void*, void const*), int, QFlags<QMetaType::TypeFlag>, QMetaObject const*)' .obj/qplatformthemefactory.o:qplatformthemefactory.cpp:function QPlatformThemeFactory::create(QString const&, QString const&): error: undefined reference to 'QString::toLower_helper(QString&)' .obj/qplatformwindow.o:qplatformwindow.cpp:function QPlatformWindow::requestUpdate(): error: undefined reference to 'qEnvironmentVariableIntValue(char const*, bool*)' .obj/qsurfaceformat.o:qsurfaceformat.cpp:function operator<<(QDebug, QSurfaceFormat const&): error: undefined reference to 'QDebug::resetFormat()' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::processGestureEvent(QWindowSystemInterfacePrivate::GestureEvent*): error: undefined reference to 'QCoreApplication::notifyInternal2(QObject*, QEvent*)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::createPlatformIntegration(): error: undefined reference to 'QString::toLower_helper(QString&)' .obj/qguiapplication.o:qguiapplication.cpp:function updateBlockedStatusRecursion(QWindow*, bool): error: undefined reference to 'QCoreApplication::notifyInternal2(QObject*, QEvent*)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::showModalWindow(QWindow*): error: undefined reference to 'QCoreApplication::notifyInternal2(QObject*, QEvent*)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::init(): error: undefined reference to 'QDebug::putByteArray(char const*, unsigned int, QDebug::Latin1Content)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::init(): error: undefined reference to 'qEnvironmentVariableIntValue(char const*, bool*)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::init(): error: undefined reference to 'QDebug::putString(QChar const*, unsigned int)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::init(): error: undefined reference to 'QString::toLower_helper(QString&)' .obj/qwindow.o:qwindow.cpp:function operator<<(QDebug, QWindow const*): error: undefined reference to 'qt_QMetaEnum_debugOperator(QDebug&, int, QMetaObject const*, char const*)' .obj/qwindow.o:qwindow.cpp:function operator<<(QDebug, QWindow const*): error: undefined reference to 'qt_QMetaEnum_debugOperator(QDebug&, int, QMetaObject const*, char const*)' .obj/qwindow.o:qwindow.cpp:function operator<<(QDebug, QWindow const*): error: undefined reference to 'qt_QMetaEnum_flagDebugOperator(QDebug&, unsigned long long, QMetaObject const*, char const*)' .obj/qwindow.o:qwindow.cpp:function operator<<(QDebug, QWindow const*): error: undefined reference to 'QDebug::putString(QChar const*, unsigned int)' .obj/qwindow.o:qwindow.cpp:function QWindowPrivate::create(bool): error: undefined reference to 'qt_QMetaEnum_flagDebugOperator(QDebug&, unsigned long long, QMetaObject const*, char const*)' .obj/qclipboard.o:qclipboard.cpp:function QClipboard::text(QString&, QClipboard::Mode) const: error: undefined reference to 'QString::operator=(QLatin1String)' .obj/qcursor.o:qcursor.cpp:function operator<<(QDebug, QCursor const&): error: undefined reference to 'qt_QMetaEnum_debugOperator(QDebug&, int, QMetaObject const*, char const*)' .obj/qdnd.o:qdnd.cpp:function imageReadMimeFormats(): error: undefined reference to 'QByteArray::toLower_helper(QByteArray const&)' .obj/qdnd.o:qdnd.cpp:function imageWriteMimeFormats(): error: undefined reference to 'QByteArray::toLower_helper(QByteArray const&)' .obj/qdnd.o:qdnd.cpp:function QInternalMimeData::renderDataHelper(QString const&, QMimeData const*): error: undefined reference to 'QByteArray::toUpper_helper(QByteArray&)' .obj/qevent.o:qevent.cpp:function operator<<(QDebug, QEvent const*): error: undefined reference to 'QDebug::putByteArray(char const*, unsigned int, QDebug::Latin1Content)' .obj/qevent.o:qevent.cpp:function operator<<(QDebug, QEvent const*): error: undefined reference to 'QDebug::putByteArray(char const*, unsigned int, QDebug::Latin1Content)' .obj/qevent.o:qevent.cpp:function operator<<(QDebug, QEvent const*): error: undefined reference to 'QDebug::putByteArray(char const*, unsigned int, QDebug::Latin1Content)' .obj/qkeysequence.o:qkeysequence.cpp:function QKeySequencePrivate::decodeString(QString const&, QKeySequence::SequenceFormat): error: undefined reference to 'QString::toLower_helper(QString const&)' .obj/qkeysequence.o:qkeysequence.cpp:function QKeySequencePrivate::decodeString(QString const&, QKeySequence::SequenceFormat): error: undefined reference to 'QString::toLower_helper(QString const&)' .obj/qscreen.o:qscreen.cpp:function operator<<(QDebug, QScreen const*): error: undefined reference to 'qt_QMetaEnum_debugOperator(QDebug&, int, QMetaObject const*, char const*)' .obj/qhighdpiscaling.o:qhighdpiscaling.cpp:function QHighDpiScaling::initHighDpiScaling(): error: undefined reference to 'qEnvironmentVariableIntValue(char const*, bool*)' .obj/qhighdpiscaling.o:qhighdpiscaling.cpp:function QHighDpiScaling::initHighDpiScaling(): error: undefined reference to 'QByteArray::toLower_helper(QByteArray&)' .obj/qimage.o:qimage.cpp:function operator<<(QDebug, QImage const&): error: undefined reference to 'QDebug::resetFormat()' .obj/qimage.o:qimage.cpp:function QImage::text(QString const&) const: error: undefined reference to 'QString::simplified_helper(QString const&)' .obj/qimagereader.o:qimagereader.cpp:function createReadHandlerHelper(QIODevice*, QByteArray const&, bool, bool): error: undefined reference to 'QByteArray::toLower_helper(QByteArray const&)' .obj/qimagereader.o:qimagereader.cpp:function QImageReaderPrivate::getText() [clone .part.30]: error: undefined reference to 'QString::simplified_helper(QString const&)' .obj/qimagereader.o:qimagereader.cpp:function QImageReaderPrivate::getText() [clone .part.30]: error: undefined reference to 'QString::simplified_helper(QString&)' .obj/qimagereader.o:qimagereader.cpp:function QImageReaderPrivate::initHandler(): error: undefined reference to 'QByteArray::toLower_helper(QByteArray const&)' .obj/qimagewriter.o:qimagewriter.cpp:function QImageWriter::setText(QString const&, QString const&): error: undefined reference to 'QString::simplified_helper(QString const&)' .obj/qimagewriter.o:qimagewriter.cpp:function QImageWriter::setText(QString const&, QString const&): error: undefined reference to 'QString::simplified_helper(QString const&)' .obj/qpixmap.o:qpixmap.cpp:function operator<<(QDebug, QPixmap const&): error: undefined reference to 'QDebug::resetFormat()' .obj/qicon.o:qicon.cpp:function operator<<(QDebug, QIcon const&): error: undefined reference to 'QDebug::resetFormat()' .obj/qiconloader.o:qiconloader.cpp:function QIconLoader::findIconHelper(QString const&, QString const&, QStringList&) const: error: undefined reference to 'QString::trimmed_helper(QString const&)' .obj/qppmhandler.o:qppmhandler.cpp:function QPpmHandler::setOption(QImageIOHandler::ImageOption, QVariant const&): error: undefined reference to 'QByteArray::toLower_helper(QByteArray&)' .obj/qxbmhandler.o:qxbmhandler.cpp:function read_xbm_header(QIODevice*, int&, int&): error: undefined reference to 'QByteArray::trimmed_helper(QByteArray&)' .obj/qxbmhandler.o:qxbmhandler.cpp:function read_xbm_header(QIODevice*, int&, int&): error: undefined reference to 'QByteArray::trimmed_helper(QByteArray&)' .obj/qxpmhandler.o:qxpmhandler.cpp:function read_xpm_body(QIODevice*, char const* const*, int&, QByteArray&, int, int, int, int, QImage&): error: undefined reference to 'QByteArray::simplified_helper(QByteArray&)' .obj/qxpmhandler.o:qxpmhandler.cpp:function read_xpm_body(QIODevice*, char const* const*, int&, QByteArray&, int, int, int, int, QImage&): error: undefined reference to 'QByteArray::trimmed_helper(QByteArray&)' .obj/qxpmhandler.o:qxpmhandler.cpp:function read_xpm_body(QIODevice*, char const* const*, int&, QByteArray&, int, int, int, int, QImage&): error: undefined reference to 'QByteArray::toLower_helper(QByteArray&)' .obj/qxpmhandler.o:qxpmhandler.cpp:function QXpmHandler::write(QImage const&): error: undefined reference to 'QString::asprintf(char const*, ...)' .obj/qxpmhandler.o:qxpmhandler.cpp:function QXpmHandler::write(QImage const&): error: undefined reference to 'QString::asprintf(char const*, ...)' .obj/qpnghandler.o:qpnghandler.cpp:function QPNGImageWriter::writeImage(QImage const&, int, QString const&, int, int): error: undefined reference to 'QString::simplified_helper(QString&)' .obj/qfont.o:qfont.cpp:function QFont::substitute(QString const&): error: undefined reference to 'QString::toLower_helper(QString const&)' .obj/qfontsubset.o:qfontsubset.cpp:function QFontSubset::toTruetype() const: error: undefined reference to 'QString::operator=(QLatin1String)' .obj/qfontsubset.o:qfontsubset.cpp:function QFontSubset::toTruetype() const: error: undefined reference to 'QString::operator=(QLatin1String)' .obj/qfontsubset.o:qfontsubset.cpp:function QFontSubset::toTruetype() const: error: undefined reference to 'QString::operator=(QLatin1String)' .obj/qfontdatabase.o:qfontdatabase.cpp:function QFontDatabase::load(QFontPrivate const*, int): error: undefined reference to 'QString::trimmed_helper(QString const&)' .obj/qtextdocument.o:qtextdocument.cpp:function findInBlock(QTextBlock const&, QRegularExpression const&, int, QFlags<QTextDocument::FindFlag>, QTextCursor*): error: undefined reference to 'QString::lastIndexOf(QRegularExpression const&, int, QRegularExpressionMatch*) const' .obj/qtextdocument.o:qtextdocument.cpp:function findInBlock(QTextBlock const&, QRegularExpression const&, int, QFlags<QTextDocument::FindFlag>, QTextCursor*): error: undefined reference to 'QString::indexOf(QRegularExpression const&, int, QRegularExpressionMatch*) const' .obj/qtexthtmlparser.o:qtexthtmlparser.cpp:function setWidthAttribute(QTextLength*, QString): error: undefined reference to 'QString::trimmed_helper(QString const&)' .obj/qtexthtmlparser.o:qtexthtmlparser.cpp:function QTextHtmlParser::parseCloseTag(): error: undefined reference to 'QString::trimmed_helper(QString&)' .obj/qcssparser.o:qcssparser.cpp:function parseColorValue(QCss::Value): error: undefined reference to 'QString::trimmed_helper(QString const&)' .obj/qtextodfwriter.o:qtextodfwriter.cpp:function QTextOdfWriter::writeBlockFormat(QXmlStreamWriter&, QTextBlockFormat, int) const: error: undefined reference to 'qt_QMetaEnum_flagDebugOperator(QDebug&, unsigned long long, QMetaObject const*, char const*)' .obj/qcolor.o:qcolor.cpp:function QColor::name(QColor::NameFormat) const: error: undefined reference to 'QString::asprintf(char const*, ...)' .obj/qcolor.o:qcolor.cpp:function QColor::name(QColor::NameFormat) const: error: undefined reference to 'QString::asprintf(char const*, ...)' .obj/qvalidator.o:qvalidator.cpp:function QDoubleValidator::validate(QString&, int&) const: error: undefined reference to 'QLocaleData::validateChars(QString const&, QLocaleData::NumberMode, QByteArray*, int, bool) const' .obj/qvalidator.o:qvalidator.cpp:function QIntValidator::validate(QString&, int&) const: error: undefined reference to 'QLocaleData::validateChars(QString const&, QLocaleData::NumberMode, QByteArray*, int, bool) const' .obj/qvalidator.o:qvalidator.cpp:function QIntValidator::fixup(QString&) const: error: undefined reference to 'QLocaleData::validateChars(QString const&, QLocaleData::NumberMode, QByteArray*, int, bool) const' .obj/qvalidator.o:qvalidator.cpp:function QDoubleValidatorPrivate::validateWithLocale(QString&, QLocaleData::NumberMode, QLocale const&) const: error: undefined reference to 'QLocaleData::validateChars(QString const&, QLocaleData::NumberMode, QByteArray*, int, bool) const' .obj/qopengl.o:qopengl.cpp:function (anonymous namespace)::VersionTerm::matches(QVersionNumber const&) const: error: undefined reference to 'QVersionNumber::compare(QVersionNumber const&, QVersionNumber const&)' .obj/qopengl.o:qopengl.cpp:function (anonymous namespace)::VersionTerm::matches(QVersionNumber const&) const: error: undefined reference to 'QVersionNumber::compare(QVersionNumber const&, QVersionNumber const&)' .obj/qopengl.o:qopengl.cpp:function (anonymous namespace)::VersionTerm::matches(QVersionNumber const&) const: error: undefined reference to 'QVersionNumber::compare(QVersionNumber const&, QVersionNumber const&)' .obj/qopengl.o:qopengl.cpp:function (anonymous namespace)::VersionTerm::matches(QVersionNumber const&) const: error: undefined reference to 'QVersionNumber::compare(QVersionNumber const&, QVersionNumber const&)' .obj/qopengl.o:qopengl.cpp:function (anonymous namespace)::VersionTerm::fromJson(QJsonValue const&): error: undefined reference to 'QVersionNumber::fromString(QString const&, int*)' .obj/qopengl.o:qopengl.cpp:function operator<<(QDebug, QOpenGLConfig::Gpu const&): error: undefined reference to 'operator<<(QDebug, QVersionNumber const&)' .obj/qopengl.o:qopengl.cpp:function QOpenGLConfig::gpuFeatures(QOpenGLConfig::Gpu const&, QJsonDocument const&): error: undefined reference to 'QSysInfo::kernelVersion()' .obj/qopengl.o:qopengl.cpp:function QOpenGLConfig::gpuFeatures(QOpenGLConfig::Gpu const&, QJsonDocument const&): error: undefined reference to 'QVersionNumber::fromString(QString const&, int*)' .obj/qopengl.o:qopengl.cpp:function QOpenGLConfig::gpuFeatures(QOpenGLConfig::Gpu const&, QString const&): error: undefined reference to 'QSysInfo::kernelVersion()' .obj/qopengl.o:qopengl.cpp:function QOpenGLConfig::gpuFeatures(QOpenGLConfig::Gpu const&, QString const&): error: undefined reference to 'QVersionNumber::fromString(QString const&, int*)' collect2: error: ld returned 1 exit status Makefile:1204: recipe for target '../../lib/libQt5Gui.so.5.6.0' failed make[2]: *** [../../lib/libQt5Gui.so.5.6.0] Error 1 make[2]: Leaving directory '/home/jekk666/raspi/qtbase/src/gui' Makefile:498: recipe for target 'sub-gui-make_first' failed make[1]: *** [sub-gui-make_first] Error 2 make[1]: Leaving directory '/home/jekk666/raspi/qtbase/src' Makefile:45: recipe for target 'sub-src-make_first' failed make: *** [sub-src-make_first] Error 2
I have no prior experience with Qt and i'm far from being an expert of Linux, so any piece of advice will be most welcome.
Thanks. -
Seeing the same error for a x86_64 target:
linking ../bin/qtweb
/opt/poky/1.8.1/sysroots/corei7-64-poky-linux/usr/lib/libQt5WebKitWidgets.so: undefined reference toQAccessibleWidget::text(QAccessible::Text) const@Qt_5' /opt/poky/1.8.1/sysroots/corei7-64-poky-linux/usr/lib/libQt5WebKitWidgets.so: undefined reference to
non-virtual thunk to QAccessibleWidget::doAction(QString const&)@Qt_5'
........ -
@Jacob
Hi, Can you explain how you solve this problem, because i have the exact same problem. I am try to cross compile QT5.6 on Ubuntu 14.04here's my config
./configure -release -opengl es2 -device linux-rasp-pi2-g++ -device-option CROSS_COMPILE=~/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/arm-linux-gnueabihf- -device-option DISTRO_OPTS=hard-float -sysroot ~/raspi/sysroot -opensource -confirm-license -no-xcb -make libs -prefix /usr/local/qt5pi -extprefix ~/raspi/qt5pi -hostprefix ~/raspi/qt5 -v
Error stack:
make[2]: Entering directory `/home/daywong/raspi/qtbase/src/gui' rm -f libQt5Gui.so.5.6.0 libQt5Gui.so libQt5Gui.so.5 libQt5Gui.so.5.6 /home/daywong/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/arm-linux-gnueabihf-g++ -Wl,-rpath-link,/home/daywong/raspi/sysroot/opt/vc/lib -Wl,-rpath-link,/home/daywong/raspi/sysroot/usr/lib/arm-linux-gnueabihf -Wl,-rpath-link,/home/daywong/raspi/sysroot/lib/arm-linux-gnueabihf -mfloat-abi=hard --sysroot=/home/daywong/raspi/sysroot -Wl,--no-undefined -Wl,--version-script,/home/daywong/raspi/qtbase/src/gui/QtGui.version -Wl,-O1 -fuse-ld=gold -Wl,--enable-new-dtags -Wl,-z,origin -Wl,-rpath,\$ORIGIN -shared -Wl,-soname,libQt5Gui.so.5 -o libQt5Gui.so.5.6.0 .obj/pixman-arm-neon-asm.o .obj/qdrawhelper_neon_asm.o .obj/qimage_compat.o .obj/qaccessible.o .obj/qaccessiblecache.o .obj/qaccessibleobject.o .obj/qaccessibleplugin.o .obj/qplatformaccessibility.o .obj/qaccessiblebridge.o .obj/qgenericpluginfactory.o .obj/qgenericplugin.o .obj/qwindowsysteminterface.o .obj/qplatforminputcontextfactory.o .obj/qplatforminputcontextplugin.o .obj/qplatforminputcontext.o .obj/qplatformintegration.o .obj/qplatformdrag.o .obj/qplatformscreen.o .obj/qplatformintegrationfactory.o .obj/qplatformintegrationplugin.o .obj/qplatformtheme.o .obj/qplatformthemefactory.o .obj/qplatformthemeplugin.o .obj/qplatformwindow.o .obj/qplatformoffscreensurface.o .obj/qplatformcursor.o .obj/qplatformclipboard.o .obj/qplatformnativeinterface.o .obj/qsessionmanager.o .obj/qshapedpixmapdndwindow.o .obj/qsimpledrag.o .obj/qsurfaceformat.o .obj/qguiapplication.o .obj/qwindow.o .obj/qoffscreensurface.o .obj/qplatformsurface.o .obj/qsurface.o .obj/qclipboard.o .obj/qcursor.o .obj/qdrag.o .obj/qdnd.o .obj/qevent.o .obj/qinputmethod.o .obj/qkeysequence.o .obj/qkeymapper.o .obj/qpalette.o .obj/qguivariant.o .obj/qscreen.o .obj/qshortcutmap.o .obj/qstylehints.o .obj/qtouchdevice.o .obj/qplatformsharedgraphicscache.o .obj/qplatformdialoghelper.o .obj/qplatformservices.o .obj/qplatformsystemtrayicon.o .obj/qplatformsessionmanager.o .obj/qplatformmenu.o .obj/qpixelformat.o .obj/qpaintdevicewindow.o .obj/qrasterwindow.o .obj/qplatformgraphicsbuffer.o .obj/qplatformgraphicsbufferhelper.o .obj/qinputdevicemanager.o .obj/qhighdpiscaling.o .obj/qplatformopenglcontext.o .obj/qopenglcontext.o .obj/qopenglwindow.o .obj/qbitmap.o .obj/qimage.o .obj/qimage_conversions.o .obj/qimageiohandler.o .obj/qimagereader.o .obj/qimagewriter.o .obj/qpaintengine_pic.o .obj/qpicture.o .obj/qpictureformatplugin.o .obj/qpixmap.o .obj/qpixmapcache.o .obj/qplatformpixmap.o .obj/qmovie.o .obj/qpixmap_raster.o .obj/qpixmap_blitter.o .obj/qnativeimage.o .obj/qimagepixmapcleanuphooks.o .obj/qicon.o .obj/qiconloader.o .obj/qiconengine.o .obj/qiconengineplugin.o .obj/qbmphandler.o .obj/qppmhandler.o .obj/qxbmhandler.o .obj/qxpmhandler.o .obj/qpnghandler.o .obj/qfont.o .obj/qfontengine.o .obj/qfontengineglyphcache.o .obj/qfontsubset.o .obj/qfontmetrics.o .obj/qfontdatabase.o .obj/qtextengine.o .obj/qtextlayout.o .obj/qtextformat.o .obj/qtextobject.o .obj/qtextoption.o .obj/qfragmentmap.o .obj/qtextdocument.o .obj/qtextdocument_p.o .obj/qtexthtmlparser.o .obj/qabstracttextdocumentlayout.o .obj/qtextdocumentlayout.o .obj/qtextcursor.o .obj/qtextdocumentfragment.o .obj/qtextimagehandler.o .obj/qtexttable.o .obj/qtextlist.o .obj/qtextdocumentwriter.o .obj/qsyntaxhighlighter.o .obj/qcssparser.o .obj/qzip.o .obj/qtextodfwriter.o .obj/qstatictext.o .obj/qrawfont.o .obj/qglyphrun.o .obj/qdistancefield.o .obj/qfontengine_qpf2.o .obj/qplatformfontdatabase.o .obj/qharfbuzzng.o .obj/qbackingstore.o .obj/qbezier.o .obj/qblendfunctions.o .obj/qblittable.o .obj/qbrush.o .obj/qcolor.o .obj/qcolor_p.o .obj/qcompositionfunctions.o .obj/qcosmeticstroker.o .obj/qcssutil.o .obj/qdrawhelper.o .obj/qemulationpaintengine.o .obj/qgammatables.o .obj/qgrayraster.o .obj/qimagescale.o .obj/qmatrix.o .obj/qmemrotate.o .obj/qoutlinemapper.o .obj/qpagedpaintdevice.o .obj/qpagelayout.o .obj/qpagesize.o .obj/qpaintdevice.o .obj/qpaintengine.o .obj/qpaintengineex.o .obj/qpaintengine_blitter.o .obj/qpaintengine_raster.o .obj/qpainter.o .obj/qpainterpath.o .obj/qpathclipper.o .obj/qpdf.o .obj/qpdfwriter.o .obj/qpen.o .obj/qpolygon.o .obj/qrasterizer.o .obj/qregion.o .obj/qstroker.o .obj/qtextureglyphcache.o .obj/qtransform.o .obj/qplatformbackingstore.o .obj/qpathsimplifier.o .obj/qdesktopservices.o .obj/qvalidator.o .obj/qgridlayoutengine.o .obj/qabstractlayoutstyleinfo.o .obj/qlayoutpolicy.o .obj/qgenericmatrix.o .obj/qmatrix4x4.o .obj/qquaternion.o .obj/qvector2d.o .obj/qvector3d.o .obj/qvector4d.o .obj/qopengl.o .obj/qopenglfunctions.o .obj/qopenglframebufferobject.o .obj/qopenglpaintdevice.o .obj/qopenglbuffer.o .obj/qopenglshaderprogram.o .obj/qopenglgradientcache.o .obj/qopengltexturecache.o .obj/qopenglengineshadermanager.o .obj/qopengl2pexvertexarray.o .obj/qopenglpaintengine.o .obj/qopenglcustomshaderstage.o .obj/qtriangulatingstroker.o .obj/qopengltextureglyphcache.o .obj/qtriangulator.o .obj/qopenglversionfunctions.o .obj/qopenglversionfunctionsfactory.o .obj/qopenglvertexarrayobject.o .obj/qopengldebug.o .obj/qopengltextureblitter.o .obj/qopengltexture.o .obj/qopengltexturehelper.o .obj/qopenglpixeltransferoptions.o .obj/qopenglfunctions_es2.o .obj/qguivariantanimation.o .obj/qstandarditemmodel.o .obj/qimage_neon.o .obj/qdrawhelper_neon.o .obj/moc_qaccessible.o .obj/moc_qaccessiblecache_p.o .obj/moc_qaccessibleplugin.o .obj/moc_qaccessiblebridge.o .obj/moc_qgenericplugin.o .obj/moc_qplatforminputcontext.o .obj/moc_qplatforminputcontextplugin_p.o .obj/moc_qplatformintegrationplugin.o .obj/moc_qplatformthemeplugin.o .obj/moc_qplatformnativeinterface.o .obj/moc_qplatformmenu.o .obj/moc_qshapedpixmapdndwindow_p.o .obj/moc_qoffscreensurface.o .obj/moc_qclipboard.o .obj/moc_qdrag.o .obj/moc_qdnd_p.o .obj/moc_qevent.o .obj/moc_qkeysequence.o .obj/moc_qkeymapper_p.o .obj/moc_qpalette.o .obj/moc_qsessionmanager.o .obj/moc_qscreen.o .obj/moc_qstylehints.o .obj/moc_qtouchdevice.o .obj/moc_qplatformsharedgraphicscache.o .obj/moc_qplatformdialoghelper.o .obj/moc_qpaintdevicewindow.o .obj/moc_qrasterwindow.o .obj/moc_qplatformgraphicsbuffer.o .obj/moc_qinputdevicemanager_p.o .obj/moc_qopenglwindow.o .obj/moc_qimageiohandler.o .obj/moc_qpictureformatplugin.o .obj/moc_qiconengineplugin.o .obj/moc_qfont.o .obj/moc_qfontdatabase.o .obj/moc_qtextformat.o .obj/moc_qtextobject.o .obj/moc_qtextdocument.o .obj/moc_qtextimagehandler_p.o .obj/moc_qtexttable.o .obj/moc_qtextlist.o .obj/moc_qbrush.o .obj/moc_qpainter.o .obj/moc_qpdfwriter.o .obj/moc_qplatformbackingstore.o .obj/moc_qvalidator.o .obj/moc_qopenglshaderprogram.o .obj/moc_qopenglengineshadermanager_p.o -L/home/daywong/raspi/sysroot/usr/lib/arm-linux-gnueabihf -L/home/daywong/raspi/qtbase/lib -lQt5Core -lpthread -lpng -lqtharfbuzzng -lz -lGLESv2 .obj/qaccessible.o:qaccessible.cpp:function QAccessibleEvent::accessibleInterface() const: error: undefined reference to 'QDebug::~QDebug()' .obj/qaccessible.o:qaccessible.cpp:function QAccessibleEvent::accessibleInterface() const: error: undefined reference to 'QDebug::~QDebug()' .obj/qaccessible.o:qaccessible.cpp:function QAccessibleEvent::accessibleInterface() const: error: undefined reference to 'QDebug::~QDebug()' .obj/qaccessible.o:qaccessible.cpp:function operator<<(QDebug, QAccessibleEvent const&): error: undefined reference to 'QDebug::~QDebug()' .obj/qaccessible.o:qaccessible.cpp:function operator<<(QDebug, QAccessibleInterface const*): error: undefined reference to 'QDebug::putString(QChar const*, unsigned int)' .obj/qaccessible.o:qaccessible.cpp:function operator<<(QDebug, QAccessibleInterface const*): error: undefined reference to 'QDebug::putString(QChar const*, unsigned int)' .obj/qgenericpluginfactory.o:qgenericpluginfactory.cpp:function QGenericPluginFactory::create(QString const&, QString const&): error: undefined reference to 'QString::toLower_helper(QString const&)' .obj/qwindowsysteminterface.o:qwindowsysteminterface.cpp:function qt_handleShortcutEvent(QObject*, unsigned long, int, QFlags<Qt::KeyboardModifier>, QString const&, bool, unsigned short): error: undefined reference to 'QCoreApplication::notifyInternal2(QObject*, QEvent*)' .obj/qplatforminputcontextfactory.o:qplatforminputcontextfactory.cpp:function QPlatformInputContextFactory::create(QString const&): error: undefined reference to 'QString::toLower_helper(QString&)' .obj/qplatformtheme.o:qplatformtheme.cpp:function QPlatformTheme::defaultThemeHint(QPlatformTheme::ThemeHint): error: undefined reference to 'qEnvironmentVariableIntValue(char const*, bool*)' .obj/qplatformtheme.o:qplatformtheme.cpp:function QPlatformTheme::defaultThemeHint(QPlatformTheme::ThemeHint): error: undefined reference to 'QMetaType::registerNormalizedType(QByteArray const&, void (*)(void*), void* (*)(void*, void const*), int, QFlags<QMetaType::TypeFlag>, QMetaObject const*)' .obj/qplatformtheme.o:qplatformtheme.cpp:function QPlatformTheme::defaultThemeHint(QPlatformTheme::ThemeHint): error: undefined reference to 'QMetaType::registerNormalizedType(QByteArray const&, void (*)(void*), void* (*)(void*, void const*), int, QFlags<QMetaType::TypeFlag>, QMetaObject const*)' .obj/qplatformtheme.o:qplatformtheme.cpp:function QMetaTypeId<QtMetaTypePrivate::QSequentialIterableImpl>::qt_metatype_id(): error: undefined reference to 'QMetaType::registerNormalizedType(QByteArray const&, void (*)(void*), void* (*)(void*, void const*), int, QFlags<QMetaType::TypeFlag>, QMetaObject const*)' .obj/qplatformtheme.o:qplatformtheme.cpp:function QMetaTypeId<QList<int> >::qt_metatype_id(): error: undefined reference to 'QMetaType::registerNormalizedType(QByteArray const&, void (*)(void*), void* (*)(void*, void const*), int, QFlags<QMetaType::TypeFlag>, QMetaObject const*)' .obj/qplatformthemefactory.o:qplatformthemefactory.cpp:function QPlatformThemeFactory::create(QString const&, QString const&): error: undefined reference to 'QString::toLower_helper(QString&)' .obj/qplatformwindow.o:qplatformwindow.cpp:function QPlatformWindow::requestUpdate(): error: undefined reference to 'qEnvironmentVariableIntValue(char const*, bool*)' .obj/qsurfaceformat.o:qsurfaceformat.cpp:function operator<<(QDebug, QSurfaceFormat const&): error: undefined reference to 'QDebug::resetFormat()' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::processGestureEvent(QWindowSystemInterfacePrivate::GestureEvent*): error: undefined reference to 'QCoreApplication::notifyInternal2(QObject*, QEvent*)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::createPlatformIntegration(): error: undefined reference to 'QString::toLower_helper(QString&)' .obj/qguiapplication.o:qguiapplication.cpp:function updateBlockedStatusRecursion(QWindow*, bool): error: undefined reference to 'QCoreApplication::notifyInternal2(QObject*, QEvent*)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::showModalWindow(QWindow*): error: undefined reference to 'QCoreApplication::notifyInternal2(QObject*, QEvent*)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::init(): error: undefined reference to 'QDebug::putByteArray(char const*, unsigned int, QDebug::Latin1Content)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::init(): error: undefined reference to 'qEnvironmentVariableIntValue(char const*, bool*)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::init(): error: undefined reference to 'QDebug::putString(QChar const*, unsigned int)' .obj/qguiapplication.o:qguiapplication.cpp:function QGuiApplicationPrivate::init(): error: undefined reference to 'QString::toLower_helper(QString&)' .obj/qwindow.o:qwindow.cpp:function operator<<(QDebug, QWindow const*): error: undefined reference to 'qt_QMetaEnum_debugOperator(QDebug&, int, QMetaObject const*, char const*)' .obj/qwindow.o:qwindow.cpp:function operator<<(QDebug, QWindow const*): error: undefined reference to 'qt_QMetaEnum_debugOperator(QDebug&, int, QMetaObject const*, char const*)' .obj/qwindow.o:qwindow.cpp:function operator<<(QDebug, QWindow const*): error: undefined reference to 'qt_QMetaEnum_flagDebugOperator(QDebug&, unsigned long long, QMetaObject const*, char const*)' .obj/qwindow.o:qwindow.cpp:function operator<<(QDebug, QWindow const*): error: undefined reference to 'QDebug::putString(QChar const*, unsigned int)' .obj/qwindow.o:qwindow.cpp:function QWindowPrivate::create(bool): error: undefined reference to 'qt_QMetaEnum_flagDebugOperator(QDebug&, unsigned long long, QMetaObject const*, char const*)' .obj/qclipboard.o:qclipboard.cpp:function QClipboard::text(QString&, QClipboard::Mode) const: error: undefined reference to 'QString::operator=(QLatin1String)' .obj/qcursor.o:qcursor.cpp:function operator<<(QDebug, QCursor const&): error: undefined reference to 'qt_QMetaEnum_debugOperator(QDebug&, int, QMetaObject const*, char const*)' .obj/qdnd.o:qdnd.cpp:function imageReadMimeFormats(): error: undefined reference to 'QByteArray::toLower_helper(QByteArray const&)' .obj/qdnd.o:qdnd.cpp:function imageWriteMimeFormats(): error: undefined reference to 'QByteArray::toLower_helper(QByteArray const&)' .obj/qdnd.o:qdnd.cpp:function QInternalMimeData::renderDataHelper(QString const&, QMimeData const*): error: undefined reference to 'QByteArray::toUpper_helper(QByteArray&)' .obj/qevent.o:qevent.cpp:function operator<<(QDebug, QEvent const*): error: undefined reference to 'QDebug::putByteArray(char const*, unsigned int, QDebug::Latin1Content)' .obj/qevent.o:qevent.cpp:function operator<<(QDebug, QEvent const*): error: undefined reference to 'QDebug::putByteArray(char const*, unsigned int, QDebug::Latin1Content)' .obj/qevent.o:qevent.cpp:function operator<<(QDebug, QEvent const*): error: undefined reference to 'QDebug::putByteArray(char const*, unsigned int, QDebug::Latin1Content)' .obj/qkeysequence.o:qkeysequence.cpp:function QKeySequencePrivate::decodeString(QString const&, QKeySequence::SequenceFormat): error: undefined reference to 'QString::toLower_helper(QString const&)' .obj/qkeysequence.o:qkeysequence.cpp:function QKeySequencePrivate::decodeString(QString const&, QKeySequence::SequenceFormat): error: undefined reference to 'QString::toLower_helper(QString const&)' .obj/qscreen.o:qscreen.cpp:function operator<<(QDebug, QScreen const*): error: undefined reference to 'qt_QMetaEnum_debugOperator(QDebug&, int, QMetaObject const*, char const*)' .obj/qhighdpiscaling.o:qhighdpiscaling.cpp:function QHighDpiScaling::initHighDpiScaling(): error: undefined reference to 'qEnvironmentVariableIntValue(char const*, bool*)' .obj/qhighdpiscaling.o:qhighdpiscaling.cpp:function QHighDpiScaling::initHighDpiScaling(): error: undefined reference to 'QByteArray::toLower_helper(QByteArray&)' .obj/qimage.o:qimage.cpp:function operator<<(QDebug, QImage const&): error: undefined reference to 'QDebug::resetFormat()' .obj/qimage.o:qimage.cpp:function QImage::text(QString const&) const: error: undefined reference to 'QString::simplified_helper(QString const&)' .obj/qimagereader.o:qimagereader.cpp:function createReadHandlerHelper(QIODevice*, QByteArray const&, bool, bool): error: undefined reference to 'QByteArray::toLower_helper(QByteArray const&)' .obj/qimagereader.o:qimagereader.cpp:function QImageReaderPrivate::getText() [clone .part.30]: error: undefined reference to 'QString::simplified_helper(QString const&)' .obj/qimagereader.o:qimagereader.cpp:function QImageReaderPrivate::getText() [clone .part.30]: error: undefined reference to 'QString::simplified_helper(QString&)' .obj/qimagereader.o:qimagereader.cpp:function QImageReaderPrivate::initHandler(): error: undefined reference to 'QByteArray::toLower_helper(QByteArray const&)' .obj/qimagewriter.o:qimagewriter.cpp:function QImageWriter::setText(QString const&, QString const&): error: undefined reference to 'QString::simplified_helper(QString const&)' .obj/qimagewriter.o:qimagewriter.cpp:function QImageWriter::setText(QString const&, QString const&): error: undefined reference to 'QString::simplified_helper(QString const&)' .obj/qpixmap.o:qpixmap.cpp:function operator<<(QDebug, QPixmap const&): error: undefined reference to 'QDebug::resetFormat()' .obj/qicon.o:qicon.cpp:function operator<<(QDebug, QIcon const&): error: undefined reference to 'QDebug::resetFormat()' .obj/qiconloader.o:qiconloader.cpp:function QIconLoader::findIconHelper(QString const&, QString const&, QStringList&) const: error: undefined reference to 'QString::trimmed_helper(QString const&)' .obj/qppmhandler.o:qppmhandler.cpp:function QPpmHandler::setOption(QImageIOHandler::ImageOption, QVariant const&): error: undefined reference to 'QByteArray::toLower_helper(QByteArray&)' .obj/qxbmhandler.o:qxbmhandler.cpp:function read_xbm_header(QIODevice*, int&, int&): error: undefined reference to 'QByteArray::trimmed_helper(QByteArray&)' .obj/qxbmhandler.o:qxbmhandler.cpp:function read_xbm_header(QIODevice*, int&, int&): error: undefined reference to 'QByteArray::trimmed_helper(QByteArray&)' .obj/qxpmhandler.o:qxpmhandler.cpp:function read_xpm_body(QIODevice*, char const* const*, int&, QByteArray&, int, int, int, int, QImage&): error: undefined reference to 'QByteArray::simplified_helper(QByteArray&)' .obj/qxpmhandler.o:qxpmhandler.cpp:function read_xpm_body(QIODevice*, char const* const*, int&, QByteArray&, int, int, int, int, QImage&): error: undefined reference to 'QByteArray::trimmed_helper(QByteArray&)' .obj/qxpmhandler.o:qxpmhandler.cpp:function read_xpm_body(QIODevice*, char const* const*, int&, QByteArray&, int, int, int, int, QImage&): error: undefined reference to 'QByteArray::toLower_helper(QByteArray&)' .obj/qxpmhandler.o:qxpmhandler.cpp:function QXpmHandler::write(QImage const&): error: undefined reference to 'QString::asprintf(char const*, ...)' .obj/qxpmhandler.o:qxpmhandler.cpp:function QXpmHandler::write(QImage const&): error: undefined reference to 'QString::asprintf(char const*, ...)' .obj/qpnghandler.o:qpnghandler.cpp:function QPNGImageWriter::writeImage(QImage const&, int, QString const&, int, int): error: undefined reference to 'QString::simplified_helper(QString&)' .obj/qfont.o:qfont.cpp:function QFont::substitute(QString const&): error: undefined reference to 'QString::toLower_helper(QString const&)' .obj/qfontsubset.o:qfontsubset.cpp:function QFontSubset::toTruetype() const: error: undefined reference to 'QString::operator=(QLatin1String)' .obj/qfontsubset.o:qfontsubset.cpp:function QFontSubset::toTruetype() const: error: undefined reference to 'QString::operator=(QLatin1String)' .obj/qfontsubset.o:qfontsubset.cpp:function QFontSubset::toTruetype() const: error: undefined reference to 'QString::operator=(QLatin1String)' .obj/qfontdatabase.o:qfontdatabase.cpp:function QFontDatabase::load(QFontPrivate const*, int): error: undefined reference to 'QString::trimmed_helper(QString const&)' .obj/qtextdocument.o:qtextdocument.cpp:function findInBlock(QTextBlock const&, QRegularExpression const&, int, QFlags<QTextDocument::FindFlag>, QTextCursor*): error: undefined reference to 'QString::lastIndexOf(QRegularExpression const&, int, QRegularExpressionMatch*) const' .obj/qtextdocument.o:qtextdocument.cpp:function findInBlock(QTextBlock const&, QRegularExpression const&, int, QFlags<QTextDocument::FindFlag>, QTextCursor*): error: undefined reference to 'QString::indexOf(QRegularExpression const&, int, QRegularExpressionMatch*) const' .obj/qtexthtmlparser.o:qtexthtmlparser.cpp:function setWidthAttribute(QTextLength*, QString): error: undefined reference to 'QString::trimmed_helper(QString const&)' .obj/qtexthtmlparser.o:qtexthtmlparser.cpp:function QTextHtmlParser::parseCloseTag(): error: undefined reference to 'QString::trimmed_helper(QString&)' .obj/qcssparser.o:qcssparser.cpp:function parseColorValue(QCss::Value): error: undefined reference to 'QString::trimmed_helper(QString const&)' .obj/qtextodfwriter.o:qtextodfwriter.cpp:function QTextOdfWriter::writeBlockFormat(QXmlStreamWriter&, QTextBlockFormat, int) const: error: undefined reference to 'qt_QMetaEnum_flagDebugOperator(QDebug&, unsigned long long, QMetaObject const*, char const*)' .obj/qcolor.o:qcolor.cpp:function QColor::name(QColor::NameFormat) const: error: undefined reference to 'QString::asprintf(char const*, ...)' .obj/qcolor.o:qcolor.cpp:function QColor::name(QColor::NameFormat) const: error: undefined reference to 'QString::asprintf(char const*, ...)' .obj/qvalidator.o:qvalidator.cpp:function QDoubleValidator::validate(QString&, int&) const: error: undefined reference to 'QLocaleData::validateChars(QString const&, QLocaleData::NumberMode, QByteArray*, int, bool) const' .obj/qvalidator.o:qvalidator.cpp:function QIntValidator::validate(QString&, int&) const: error: undefined reference to 'QLocaleData::validateChars(QString const&, QLocaleData::NumberMode, QByteArray*, int, bool) const' .obj/qvalidator.o:qvalidator.cpp:function QIntValidator::fixup(QString&) const: error: undefined reference to 'QLocaleData::validateChars(QString const&, QLocaleData::NumberMode, QByteArray*, int, bool) const' .obj/qvalidator.o:qvalidator.cpp:function QDoubleValidatorPrivate::validateWithLocale(QString&, QLocaleData::NumberMode, QLocale const&) const: error: undefined reference to 'QLocaleData::validateChars(QString const&, QLocaleData::NumberMode, QByteArray*, int, bool) const' .obj/qopengl.o:qopengl.cpp:function (anonymous namespace)::VersionTerm::matches(QVersionNumber const&) const: error: undefined reference to 'QVersionNumber::compare(QVersionNumber const&, QVersionNumber const&)' .obj/qopengl.o:qopengl.cpp:function (anonymous namespace)::VersionTerm::matches(QVersionNumber const&) const: error: undefined reference to 'QVersionNumber::compare(QVersionNumber const&, QVersionNumber const&)' .obj/qopengl.o:qopengl.cpp:function (anonymous namespace)::VersionTerm::matches(QVersionNumber const&) const: error: undefined reference to 'QVersionNumber::compare(QVersionNumber const&, QVersionNumber const&)' .obj/qopengl.o:qopengl.cpp:function (anonymous namespace)::VersionTerm::matches(QVersionNumber const&) const: error: undefined reference to 'QVersionNumber::compare(QVersionNumber const&, QVersionNumber const&)' .obj/qopengl.o:qopengl.cpp:function (anonymous namespace)::VersionTerm::fromJson(QJsonValue const&): error: undefined reference to 'QVersionNumber::fromString(QString const&, int*)' .obj/qopengl.o:qopengl.cpp:function operator<<(QDebug, QOpenGLConfig::Gpu const&): error: undefined reference to 'operator<<(QDebug, QVersionNumber const&)' .obj/qopengl.o:qopengl.cpp:function QOpenGLConfig::gpuFeatures(QOpenGLConfig::Gpu const&, QJsonDocument const&): error: undefined reference to 'QSysInfo::kernelVersion()' .obj/qopengl.o:qopengl.cpp:function QOpenGLConfig::gpuFeatures(QOpenGLConfig::Gpu const&, QJsonDocument const&): error: undefined reference to 'QVersionNumber::fromString(QString const&, int*)' .obj/qopengl.o:qopengl.cpp:function QOpenGLConfig::gpuFeatures(QOpenGLConfig::Gpu const&, QString const&): error: undefined reference to 'QSysInfo::kernelVersion()' .obj/qopengl.o:qopengl.cpp:function QOpenGLConfig::gpuFeatures(QOpenGLConfig::Gpu const&, QString const&): error: undefined reference to 'QVersionNumber::fromString(QString const&, int*)' collect2: error: ld returned 1 exit status make[2]: *** [../../lib/libQt5Gui.so.5.6.0] Error 1 make[2]: Leaving directory `/home/daywong/raspi/qtbase/src/gui' make[1]: *** [sub-gui-make_first] Error 2 make[1]: Leaving directory `/home/daywong/raspi/qtbase/src' make: *** [sub-src-make_first] Error 2
Thanks
-
After looking more closely, the errors you are seeing and what I saw, are somewhat different. Also, you are building Qt whereas I was building an application which used Qt.
I saw a lot of errors regarding unresolved symbols in QAccessible*. Checked on internet but there was no satisfactory explanation. I just decided to rebuild. Deleted the build directory & rebuilt Qt5. Created a new Qt tool chain also. Installed the new toolchain & linked with it. There were no unresolved symbols.