When compiling Qt 4.6 (seems to be the same issue for Git 4.6-stable, 4.6 and master, and also the release candidate 1), there seems to be a include search path clash when Qt is compiled with -qt-sql-mysql and -with-webkit.
Since MySQL support is not included by default, I have to compile Qt manually, and I used the following configuration:
-nomake "demos examples" \
-I /usr/local/libmysql/include \
-L /usr/local/libmysql/lib \
As you can see, I defined an additional include path for the libmysql code/libraries. Now when I run make, it compiles fine for a while, but as soon as it reaches a certain part of WebKit code, the following happens:
/Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowCustom.cpp: In member function 'JSC::JSValue WebCore::JSDOMWindow::atob(JSC::ExecState*, const JSC::ArgList&)':
/Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowCustom.cpp:1015: error: 'base64Decode' was not declared in this scope
/Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowCustom.cpp: In member function 'JSC::JSValue WebCore::JSDOMWindow::btoa(JSC::ExecState*, const JSC::ArgList&)':
/Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowCustom.cpp:1041: error: 'base64Encode' was not declared in this scope
make: *** [obj/release/JSDOMWindowCustom.o] Error 1
make: *** Waiting for unfinished jobs....
make: *** [release] Error 2
make: *** [sub-webkit-make_default-ordered] Error 2
It seems that it's possible to work around this by moving the libmysql from a "contained" place like /usr/local/libmysql/, which in turn contains include, lib and bin; to their "public" places like /usr/local/include, etc.
I consider this to be a blocker, since it costs a LOT of time if you run into this issue and it likely leads to more reports and problems on the user side.
I assume this is due to the wrong order of include paths, and WebKit includes a file that appears to have the same name in the MySQL drivers, and that one is included instead.
Also, take a look at a discussion on the mailing lists for more information: