[Interest] link error (and probably a dumb question)

Thiago Macieira thiago.macieira at intel.com
Wed Sep 16 20:04:38 CEST 2015


On Wednesday 16 September 2015 11:19:23 René J.V. Bertin wrote:
> .obj/qsql_sqlite.o: In function `QString::toLower() const &':
> /opt/local/src/qt-everywhere-opensource-src-5.5.0/qtbase/include/QtCore/../.
> ./src/corelib/tools/qstring.h:389: undefined reference to
> `QString::toLower_helper(QString const&)'

As Andreas pointed out and you've found out, the problem is mixing different Qt 
versions. Your headers are from Qt 5.5, as evidenced by the fact that the 
rvalue-ref QString::toLower() inline function was found (added in Qt 5.4, 
actually, in 19dd9a0ebd570ac134e115f2339912a1015ecde5), but the corresponding 
out-of-line implementation in toLower_helper() is missing during linking.

This means your -lQt5Core found an older (< 5.4) version of QtCore.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel Open Source Technology Center




More information about the Interest mailing list