[Buildroot] [PATCH v4 20/29] package/qt6/qt6base: add support for sql module w/ sqlite

Thomas Petazzoni thomas.petazzoni at bootlin.com
Tue Sep 20 06:39:57 UTC 2022


On Fri, 26 Aug 2022 15:54:54 +0200
Jesse Van Gavere <jesseevg at gmail.com> wrote:

> Signed-off-by: Jesse Van Gavere <jesseevg at gmail.com>
> ---
>  package/qt6/qt6base/Config.in  | 25 +++++++++++++++++++++++++
>  package/qt6/qt6base/qt6base.mk |  9 +++++++++
>  2 files changed, 34 insertions(+)
> 
> diff --git a/package/qt6/qt6base/Config.in b/package/qt6/qt6base/Config.in
> index 79b6d675c5..5ae11afdb1 100644
> --- a/package/qt6/qt6base/Config.in
> +++ b/package/qt6/qt6base/Config.in
> @@ -90,6 +90,31 @@ comment "PostgreSQL plugin needs a toolchain w/ wchar, dynamic library"
>  	depends on BR2_USE_MMU
>  	depends on BR2_STATIC_LIBS || !BR2_USE_WCHAR
>  
> +choice
> +	prompt "SQLite 3 support"
> +	default BR2_PACKAGE_QT6BASE_SQLITE_NONE
> +	help
> +	  Select SQLite support.
> +
> +config BR2_PACKAGE_QT6BASE_SQLITE_NONE
> +	bool "No sqlite support"
> +	help
> +	  Do not compile any kind of SQLite support.
> +
> +config BR2_PACKAGE_QT6BASE_SQLITE_QT
> +	bool "Qt SQLite"
> +	help
> +	  Use Qt bundled SQLite support.
> +
> +config BR2_PACKAGE_QT6BASE_SQLITE_SYSTEM
> +	bool "System SQLite"
> +	select BR2_PACKAGE_SQLITE
> +	select BR2_PACKAGE_SQLITE_ENABLE_COLUMN_METADATA
> +	help
> +	  Use system SQLite.

In Buildroot, we really prefer to use non-bundled dependencies when it
is possible. So really the choice no/bundled/system does not make a lot
of sense. I have replaced it with a single boolean to enable/disable
sqlite support, and if enabled, it always uses the system sqlite.


> +ifeq ($(BR2_PACKAGE_QT6BASE_SQLITE_SYSTEM),y)
> +QT6BASE_CONF_OPTS += -DFEATURE_sql_sqlite=ON -DFEATURE_system_sqlite=ON
> +QT6BASE_DEPENDENCIES += sqlite
> +else ifeq ($(BR2_PACKAGE_QT6BASE_SQLITE_QT),y)
> +QT6BASE_CONF_OPTS += -DFEATURE_sql_sqlite=ON -DFEATURE_system_sqlite=OFF
> +else
> +QT6BASE_CONF_OPTS += -DFEATURE_sql_sqlite=OFF
> +endif

Consequently this has been simplified as well a little bit.

Applied with those changes. Thanks!

Best regards,

Thomas
-- 
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com



More information about the buildroot mailing list