diff mbox

[1/1] qt5base: Add buildroot config for custom options

Message ID 1476129757-55295-1-git-send-email-bryce.ferguson@rockwellcollins.com
State Accepted
Headers show

Commit Message

Bryce Ferguson Oct. 10, 2016, 8:02 p.m. UTC
To reduce the qt5base binary size, we can disable unnecessary features.
Instead of trying to map every qt5base option to buildroot, create a
single config that we can pass any option too. Then append those to the
ones generated by buildroot.

Signed-off-by: Brandon Maier <brandon.maier@rockwellcollins.com>
Signed-off-by: Bryce Ferguson <bryce.ferguson@rockwellcollins.com>
---
 package/qt5/qt5base/Config.in  | 11 +++++++++++
 package/qt5/qt5base/qt5base.mk |  2 ++
 2 files changed, 13 insertions(+)

Comments

Thomas Petazzoni Feb. 6, 2017, 3:57 p.m. UTC | #1
Hello,

On Mon, 10 Oct 2016 15:02:37 -0500, Bryce Ferguson wrote:
> To reduce the qt5base binary size, we can disable unnecessary features.
> Instead of trying to map every qt5base option to buildroot, create a
> single config that we can pass any option too. Then append those to the
> ones generated by buildroot.
> 
> Signed-off-by: Brandon Maier <brandon.maier@rockwellcollins.com>
> Signed-off-by: Bryce Ferguson <bryce.ferguson@rockwellcollins.com>
> ---
>  package/qt5/qt5base/Config.in  | 11 +++++++++++
>  package/qt5/qt5base/qt5base.mk |  2 ++
>  2 files changed, 13 insertions(+)

Normally we don't really like to add such "open" options, but since Qt5
has so many options, it probably makes sense to make an exception here.
In addition, nobody complained since you sent the patch in October
2016, so I applied it after doing some minor tweaks.

Thanks!

Thomas
diff mbox

Patch

diff --git a/package/qt5/qt5base/Config.in b/package/qt5/qt5base/Config.in
index 64a7f65..c7c4622 100644
--- a/package/qt5/qt5base/Config.in
+++ b/package/qt5/qt5base/Config.in
@@ -16,6 +16,17 @@  config BR2_PACKAGE_QT5BASE
 
 if BR2_PACKAGE_QT5BASE
 
+config BR2_PACKAGE_QT5BASE_CUSTOM_CONF_OPTS
+	string "Custom qt5base options"
+	help
+	  Define custom qt5 configuration options which can be used to enable
+	  or disable options not managed by buildroot. These options are
+	  appended to the ones generated by buildroot and passed to qt5base
+	  during configuration.
+
+	  E.g. to remove the Windows Vista style option, add the option
+	  -no-feature-style_windowsvista.
+
 config BR2_PACKAGE_QT5BASE_LICENSE_APPROVED
 	bool "Approve free license"
 	help
diff --git a/package/qt5/qt5base/qt5base.mk b/package/qt5/qt5base/qt5base.mk
index bf541b0..282ea1a 100644
--- a/package/qt5/qt5base/qt5base.mk
+++ b/package/qt5/qt5base/qt5base.mk
@@ -154,6 +154,8 @@  QT5BASE_DEPENDENCIES   += $(if $(BR2_PACKAGE_QT5BASE_ICU),icu)
 
 QT5BASE_CONFIGURE_OPTS += $(if $(BR2_PACKAGE_QT5BASE_EXAMPLES),-make,-nomake) examples
 
+QT5BASE_CONFIGURE_OPTS += $(call qstrip, $(BR2_PACKAGE_QT5BASE_CUSTOM_CONF_OPTS))
+
 # gstreamer 0.10 support is broken in qt5multimedia
 ifeq ($(BR2_PACKAGE_GST1_PLUGINS_BASE),y)
 QT5BASE_CONFIGURE_OPTS += -gstreamer 1.0