Bug 366202

Summary: Cmake script does not test for QT5 mysql module availability
Product: [Applications] digikam Reporter: Simon <freisim93>
Component: Portability-CmakeAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED INTENTIONAL    
Severity: normal CC: caulier.gilles
Priority: NOR    
Version: 5.0.0   
Target Milestone: ---   
Platform: Debian testing   
OS: Linux   
Latest Commit: Version Fixed In: 7.5.0

Description Simon 2016-07-28 12:29:51 UTC
I am trying to setup digiKam with internal Mysql database. I am running into several bugs and am currently fixing them (more on this later). The following error occured during initialisation:
    QSqlDatabase: QMYSQL driver not loaded
    QSqlDatabase: available drivers: QSQLITE
    digikam.databaseserver: Invalid database object during database server startup
I checked and I was missing the file libqsqlmysql.so. On debian this file is included in package "libqt5sql5-mysql" and located in:
    /usr/lib/x86_64-linux-gnu/qt5/plugins/sqldrivers/
The bootstrap script did not report an error or warning (internal mysql was obviously enabled). but it should.

Reproducible: Always

Steps to Reproduce:
1. Run bootstrap.linux without having libqsqlmysql.so installed


Actual Results:  
Script reports success.

Expected Results:  
Script should report failure and state that it did not find the necessary libraries.
Comment 1 caulier.gilles 2016-08-06 06:02:50 UTC
The QtQQL driver availability is only tested at run time by Qt5 when digiKAm startup.

If relevant QtSql driver is missing, just install it. digiKam will report the error in a dialog at startup.

The bootstrap script will only check if components are present to compile source code, not to run it. This is a non sense to check QtSql driver before compilation time. 

Gilles Caulier