QSqlDatabase: MYSQL driver not loaded
-
Thanks
But here we go again
The 3 files are inside the project, where the documentation wants me to do :
MSVC runtime is installed.
Maybe the problem come from the commands... i can see if they where well executed.
Near to success... bot not yet.
Thanks. -
Thanks
But here we go again
The 3 files are inside the project, where the documentation wants me to do :
MSVC runtime is installed.
Maybe the problem come from the commands... i can see if they where well executed.
Near to success... bot not yet.
Thanks.@Cervo2paille I think you must include the exe folder path in environmental "Path" variable
-
Thanks
But here we go again
The 3 files are inside the project, where the documentation wants me to do :
MSVC runtime is installed.
Maybe the problem come from the commands... i can see if they where well executed.
Near to success... bot not yet.
Thanks.@Cervo2paille It looks like it is actually working? You just messed up with connections.
-
This post is deleted!
-
@Cervo2paille It looks like it is actually working? You just messed up with connections.
@jsulm Added Cmake Path and retry the commands. In fact, the commands seems to not be passed because here, they gave me an error :
C:\Users\flebourgeois\build-sqldrivers>qt-cmake -G Ninja D:\Users\flebourgeois\Documents\QT_Projets\blossom -DCMAKE_INSTALL_PREFIX="D:\Qt\6.3.1\mingw_64" -DMySQL_INCLUDE_DIR="D:\Program Files\MySQL\MySQL Server 8.0\include" -DMySQL_LIBRARY="D:\Program Files\MySQL\MySQL Server 8.0\lib\libmysql.lib" CMake Error: CMake was unable to find a build program corresponding to "Ninja". CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool. CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage -- Configuring incomplete, errors occurred!
Tried to Install Ninja on my windows Ninja.
Config of my project under QT :
Maybe my -DCMAKE_INSTALL_PREFIX isn't ok ?
My CMAKE_MAKE_PROGRAM in QT show me a Ninja.exe, it's not ok ?
Thanks for your help :) -
Hi, you can also try without the
-G Ninja
stuff, e.g.C:\Users\flebourgeois\build-sqldrivers>qt-cmake D:\Users\flebourgeois\Documents\Q...
@hskoglund Hey, thanks i successful to do the commands. But i got again and again the same error.
The installation :D:\Users\fabdu\Documents\build-blossom-Desktop_Qt_6_3_1_MinGW_64_bit-Debug>qt-cmake -G Ninja "D:\Users\fabdu\Documents\blossom" -DCMAKE_INSTALL_PREFIX="D:\Qt\6.3.1\mingw_64" -DMySQL_INCLUDE_DIR="D:\Program Files (x86)\MySQL\MySQL Server 5.5\include" -DMySQL_LIBRARY="D:\Program Files (x86)\MySQL\MySQL Server 5.5\lib\libmysql.lib" -- Could NOT find WrapVulkanHeaders (missing: Vulkan_INCLUDE_DIR) -- Configuring done -- Generating done CMake Warning: Manually-specified variables were not used by the project: CMAKE_TOOLCHAIN_FILE MySQL_INCLUDE_DIR MySQL_LIBRARY -- Build files have been written to: D:/Users/fabdu/Documents/build-blossom-Desktop_Qt_6_3_1_MinGW_64_bit-Debug D:\Users\fabdu\Documents\build-blossom-Desktop_Qt_6_3_1_MinGW_64_bit-Debug>cmake --build . ninja: no work to do. D:\Users\fabdu\Documents\build-blossom-Desktop_Qt_6_3_1_MinGW_64_bit-Debug>cmake --install . -- Install configuration: "Debug" -- Installing: D:/Qt/6.3.1/mingw_64/bin/blossom.exe D:\Users\fabdu\Documents\build-blossom-Desktop_Qt_6_3_1_MinGW_64_bit-Debug>
The famous error :
QSqlDatabase: QMYSQL driver not loaded QSqlDatabase: available drivers: QSQLITE QODBC QPSQL
My Path :
I think i do a mistake about the starting of this line "qt-cmake -G Ninja <qt_installation_path>\Src\qtbase\src\plugins\sqldrivers...".
What do you think about ? How to write it ?
If someone has an idea... thanks ! :) -
@hskoglund Hey, thanks i successful to do the commands. But i got again and again the same error.
The installation :D:\Users\fabdu\Documents\build-blossom-Desktop_Qt_6_3_1_MinGW_64_bit-Debug>qt-cmake -G Ninja "D:\Users\fabdu\Documents\blossom" -DCMAKE_INSTALL_PREFIX="D:\Qt\6.3.1\mingw_64" -DMySQL_INCLUDE_DIR="D:\Program Files (x86)\MySQL\MySQL Server 5.5\include" -DMySQL_LIBRARY="D:\Program Files (x86)\MySQL\MySQL Server 5.5\lib\libmysql.lib" -- Could NOT find WrapVulkanHeaders (missing: Vulkan_INCLUDE_DIR) -- Configuring done -- Generating done CMake Warning: Manually-specified variables were not used by the project: CMAKE_TOOLCHAIN_FILE MySQL_INCLUDE_DIR MySQL_LIBRARY -- Build files have been written to: D:/Users/fabdu/Documents/build-blossom-Desktop_Qt_6_3_1_MinGW_64_bit-Debug D:\Users\fabdu\Documents\build-blossom-Desktop_Qt_6_3_1_MinGW_64_bit-Debug>cmake --build . ninja: no work to do. D:\Users\fabdu\Documents\build-blossom-Desktop_Qt_6_3_1_MinGW_64_bit-Debug>cmake --install . -- Install configuration: "Debug" -- Installing: D:/Qt/6.3.1/mingw_64/bin/blossom.exe D:\Users\fabdu\Documents\build-blossom-Desktop_Qt_6_3_1_MinGW_64_bit-Debug>
The famous error :
QSqlDatabase: QMYSQL driver not loaded QSqlDatabase: available drivers: QSQLITE QODBC QPSQL
My Path :
I think i do a mistake about the starting of this line "qt-cmake -G Ninja <qt_installation_path>\Src\qtbase\src\plugins\sqldrivers...".
What do you think about ? How to write it ?
If someone has an idea... thanks ! :)@Cervo2paille I haved bat file for mariadb for WIndow if you want try.
-
thanks yes i would like to try :)
-
thanks yes i would like to try :)
@Cervo2paille
That is my bat for maria db tested on 5.15.2SET QTDIR="C:\Qt\5.15.2\Src"
SET MYSQL_INCDIR="C:\Program Files\MariaDB\MariaDB Connector C 64-bit\include"
SET MYSQL_LIBDIR="C:\Program Files\MariaDB\MariaDB Connector C 64-bit\lib"SET PATH=%PATH%;C:\Qt\5.15.2\mingw81_64\bin;C:\Qt\Tools\mingw810_64\bin;
cd %QTDIR%\qtbase\src\plugins\sqldrivers
pause
qmake -- MYSQL_INCDIR=%MYSQL_INCDIR% MYSQL_LIBDIR=%MYSQL_LIBDIR%
pause
mingw32-make sub-mysql
pause
mingw32-make install
pause1.Before build, clear the previous installation
2. copy libmariadb in exe directoryI hose it is useful.
The driver installed for Maria DB is "C Connector".