Source: knowthelist
Version: 2.3.0-1
Severity: important
Tags: patch

Hi,

the latest upload (2.3.0-1) switches from qt4 to qt5, adding the
libqt5sql5-sqlite alternative dependency to libqt4-sql-sqlite.
This is problematic for different reasons:
- while knowthelist now builds as qt5 application, the primary
  dependency is the qt4 qsqlite, so libqt4-sql-sqlite will be installed
  when neither libqt4-sql-sqlite nor libqt5sql5-sqlite is installed
  already (-> knowthelist will break)
- having the alternative dependency, even if was like
  "libqt5sql5-sqlite | libqt4-sql-sqlite", means that if
  libqt4-sql-sqlite is installed already then it satisfies the
  dependencies of knowthelist (-> knowthelist will break)

The right solution is to put only the dependency based on the qt
version used for building, so libqt4-sql-sqlite when building with qt4
and libqt5sql5-sqlite when building with qt5.
Patch attached implementing this using dpkg substvars.

(Theoretically this bug could even have "serious" as priority, since
knowthelist could be installed without a needed component.)

Thanks,
-- 
Pino
--- a/debian/control
+++ b/debian/control
@@ -13,7 +13,7 @@ Vcs-Browser: https://github.com/knowthel
 
 Package: knowthelist
 Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}, libqt4-sql-sqlite | libqt5sql5-sqlite
+Depends: ${shlibs:Depends}, ${misc:Depends}, ${qtsqlite:Depends}
 Description: awesome party music player
  Easy to use for all party guests.
  .
--- a/debian/rules
+++ b/debian/rules
@@ -10,8 +10,12 @@ HASQT5=$(shell qmake -qt5 -v > /dev/null
 
 ifeq ($(HASQT5),yes)
     QMAKE=qmake -qt5
+    QSQLITE_DEPEND=libqt5sql5-sqlite
 else
     QMAKE=qmake-qt4
+    QSQLITE_DEPEND=libqt4-sql-sqlite
 endif
 CFLAGS=-O3
-CXXFLAGS=-O3
\ No newline at end of file
+CXXFLAGS=-O3
+
+DEB_DH_GENCONTROL_ARGS_ALL = -- '-Vqtsqlite:Depends=$(QSQLITE_DEPEND)'

Reply via email to