You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm building a local package for qt5 software that uses qt5sql-sqlite plugin in it sources. So currently I have to specify all qt5-sql plugins like qt5-plugin-sqlite etc. in template file to make package. Because if you look at Qt5SqlConfig.cmake file, it uses GLOB CMake function:
# In Qt 5.15 the glob pattern was relaxed to also catch plugins not literally named Plugin.
# Define QT5_STRICT_PLUGIN_GLOB or ModuleName_STRICT_PLUGIN_GLOB to revert to old behavior.
if (QT5_STRICT_PLUGIN_GLOB OR Qt5Sql_STRICT_PLUGIN_GLOB)
file(GLOB pluginTargets "${CMAKE_CURRENT_LIST_DIR}/Qt5Sql_*Plugin.cmake")
else()
file(GLOB pluginTargets "${CMAKE_CURRENT_LIST_DIR}/Qt5Sql_*.cmake")
endif()
So it's trying to find every single .so file from Qt5Sql_Q***DriverPlugin.cmake file. But they don't exist, they separated into packages like qt5-plugin-sqlite etc. and configuration fails with:
macro(_qt5_Sql_check_file_exists file)
if(NOT EXISTS "${file}" )
message(FATAL_ERROR "The imported target \"Qt5::Sql\" references the file
\"${file}\"
but this file does not exist. Possible reasons include:
* The file was deleted, renamed, or moved to another location.
* An install or uninstall procedure did not complete successfully.
* The installation package was faulty and contained
\"${CMAKE_CURRENT_LIST_FILE}\"
but not all the files it references.
")
endif()
endmacro()
The solution I'm suggesting is:
Move Qt5SqlConfig.cmake Qt5SqlConfigVersion.cmake from /usr/lib/cmake/Qt5Sql/ (qt5-sql package) into qt5-sql-devel package.
Move all Qt5Sql_QMYSQLDriverPlugin.cmake Qt5Sql_QODBCDriverPlugin.cmake Qt5Sql_QPSQLDriverPlugin.cmake Qt5Sql_QSQLiteDriverPlugin.cmake Qt5Sql_QTDSDriverPlugin.cmake from qt5-sql package into qt5-plugin-*-devel subpackages for example: Qt5Sql_QSQLiteDriverPlugin.cmake file into qt5-plugin-sqlite-devel etc.
That way to build software, we can specify single qt5-plugin-sqlite-devel as makedepends and qt5-plugin-sqlite as depends and don't list all of qt5sql plugins in template.
The text was updated successfully, but these errors were encountered:
System
Void 5.15.11-xanmod1_1 x86_64 GenuineIntel notuptodate rrFFF
qt5-sql-5.15.3+20211001_1
I'm building a local package for qt5 software that uses qt5sql-sqlite plugin in it sources. So currently I have to specify all qt5-sql plugins like
qt5-plugin-sqlite
etc. intemplate
file to make package. Because if you look atQt5SqlConfig.cmake
file, it usesGLOB
CMake function:So it's trying to find every single
.so
file fromQt5Sql_Q***DriverPlugin.cmake
file. But they don't exist, they separated into packages likeqt5-plugin-sqlite
etc. and configuration fails with:The solution I'm suggesting is:
Qt5SqlConfig.cmake Qt5SqlConfigVersion.cmake
from/usr/lib/cmake/Qt5Sql/
(qt5-sql
package) intoqt5-sql-devel
package.Qt5Sql_QMYSQLDriverPlugin.cmake Qt5Sql_QODBCDriverPlugin.cmake Qt5Sql_QPSQLDriverPlugin.cmake Qt5Sql_QSQLiteDriverPlugin.cmake Qt5Sql_QTDSDriverPlugin.cmake
fromqt5-sql
package intoqt5-plugin-*-devel
subpackages for example:Qt5Sql_QSQLiteDriverPlugin.cmake
file intoqt5-plugin-sqlite-devel
etc.That way to build software, we can specify single
qt5-plugin-sqlite-devel
asmakedepends
andqt5-plugin-sqlite
asdepends
and don't list all of qt5sql plugins in template.The text was updated successfully, but these errors were encountered: