diff mbox

[2/2] qt5connectivity: add QtNfc submodule

Message ID 1459763762-31640-2-git-send-email-corjon.j@ecagroup.com
State Superseded
Headers show

Commit Message

Julien Corjon April 4, 2016, 9:56 a.m. UTC
Signed-off-by: Julien Corjon <corjon.j@ecagroup.com>
---
 package/qt5/qt5connectivity/Config.in          | 10 ++++++----
 package/qt5/qt5connectivity/qt5connectivity.mk |  4 +++-
 2 files changed, 9 insertions(+), 5 deletions(-)

Comments

Arnout Vandecappelle April 4, 2016, 8:13 p.m. UTC | #1
On 04/04/16 11:56, Julien Corjon wrote:
> Signed-off-by: Julien Corjon <corjon.j@ecagroup.com>
> ---
>   package/qt5/qt5connectivity/Config.in          | 10 ++++++----
>   package/qt5/qt5connectivity/qt5connectivity.mk |  4 +++-
>   2 files changed, 9 insertions(+), 5 deletions(-)
>
> diff --git a/package/qt5/qt5connectivity/Config.in b/package/qt5/qt5connectivity/Config.in
> index d529ea7..611ef14 100644
> --- a/package/qt5/qt5connectivity/Config.in
> +++ b/package/qt5/qt5connectivity/Config.in
> @@ -1,13 +1,15 @@
>   config BR2_PACKAGE_QT5CONNECTIVITY
>   	bool "qt5connectivity"
>   	select BR2_PACKAGE_BLUEZ_UTILS
> +	select BR2_PACKAGE_NEARD
>   	select BR2_PACKAGE_QT5BASE
>   	select BR2_PACKAGE_QT5BASE_CONCURRENT
>   	select BR2_PACKAGE_QT5BASE_DBUS
> -	depends on !BR2_STATIC_LIBS # bluez_utils
> -	depends on BR2_USE_WCHAR # bluez_utils
> -	depends on BR2_TOOLCHAIN_HAS_THREADS # bluez_utils
> -	depends on BR2_USE_MMU # bluez_utils
> +	depends on !BR2_STATIC_LIBS # bluez_utils, neard
> +	depends on BR2_USE_WCHAR # bluez_utils, neard
> +	depends on BR2_TOOLCHAIN_HAS_THREADS # bluez_utils, neard
> +	depends on BR2_USE_MMU # bluez_utils, neard
> +	depends on BR2_TOOLCHAIN_HAS_SYNC_4 # neard

  My first thought was: this is unnecessarily adding an architecture dependency 
to qt5connectivity. However, in practice it doesn't exclude anything that wasn't 
excluded already (sparc and arc don't have GL support anyway).

  Therefore:

Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>


  Regards,
  Arnout

>   	help
>   	  Qt is a cross-platform application and UI framework for
>   	  developers using C++.
> diff --git a/package/qt5/qt5connectivity/qt5connectivity.mk b/package/qt5/qt5connectivity/qt5connectivity.mk
> index 936bc6f..ff82b9d 100644
> --- a/package/qt5/qt5connectivity/qt5connectivity.mk
> +++ b/package/qt5/qt5connectivity/qt5connectivity.mk
> @@ -7,7 +7,7 @@
>   QT5CONNECTIVITY_VERSION = $(QT5_VERSION)
>   QT5CONNECTIVITY_SITE = $(QT5_SITE)
>   QT5CONNECTIVITY_SOURCE = qtconnectivity-opensource-src-$(QT5CONNECTIVITY_VERSION).tar.xz
> -QT5CONNECTIVITY_DEPENDENCIES = bluez_utils qt5base
> +QT5CONNECTIVITY_DEPENDENCIES = bluez_utils neard qt5base
>   QT5CONNECTIVITY_INSTALL_STAGING = YES
>
>   ifeq ($(BR2_PACKAGE_QT5BASE_LICENSE_APPROVED),y)
> @@ -38,12 +38,14 @@ endef
>   ifeq ($(BR2_PACKAGE_QT5DECLARATIVE_QUICK),y)
>   define QT5CONNECTIVITY_INSTALL_TARGET_QMLS
>   	cp -dpfr $(STAGING_DIR)/usr/qml/QtBluetooth $(TARGET_DIR)/usr/qml/
> +	cp -dpfr $(STAGING_DIR)/usr/qml/QtNfc $(TARGET_DIR)/usr/qml/
>   endef
>   endif
>
>   define QT5CONNECTIVITY_INSTALL_TARGET_CMDS
>   	cp -dpf $(STAGING_DIR)/usr/lib/libQt5Bluetooth.so.* $(TARGET_DIR)/usr/lib
>   	cp -dpf $(STAGING_DIR)/usr/bin/sdpscanner $(TARGET_DIR)/usr/bin
> +	cp -dpf $(STAGING_DIR)/usr/lib/libQt5Nfc.so.* $(TARGET_DIR)/usr/lib
>   	$(QT5CONNECTIVITY_INSTALL_TARGET_QMLS)
>   endef
>
>
Thomas Petazzoni April 13, 2016, 9:53 p.m. UTC | #2
Hello,

On Mon,  4 Apr 2016 11:56:02 +0200, Julien Corjon wrote:
> Signed-off-by: Julien Corjon <corjon.j@ecagroup.com>
> ---
>  package/qt5/qt5connectivity/Config.in          | 10 ++++++----
>  package/qt5/qt5connectivity/qt5connectivity.mk |  4 +++-
>  2 files changed, 9 insertions(+), 5 deletions(-)
> 
> diff --git a/package/qt5/qt5connectivity/Config.in b/package/qt5/qt5connectivity/Config.in
> index d529ea7..611ef14 100644
> --- a/package/qt5/qt5connectivity/Config.in
> +++ b/package/qt5/qt5connectivity/Config.in
> @@ -1,13 +1,15 @@
>  config BR2_PACKAGE_QT5CONNECTIVITY
>  	bool "qt5connectivity"
>  	select BR2_PACKAGE_BLUEZ_UTILS
> +	select BR2_PACKAGE_NEARD

So until now, neard was not necessary, and without any version bump or
anything, it should become a mandatory dependency? This seems weird,
and does not quite follow the policy of Buildroot that we should have
as much as possible the smallest set of mandatory dependencies.

Is it possible to have qt5connectivity with just Bluetooth support?
Just NFC support? No support for any of them at all?

I'm wondering if we shouldn't be doing:

ifeq ($(BR2_PACKAGE_BLUEZ_UTILS),y)
QT5CONNECTIVITY_DEPENDENCIES += bluez_utils
endif

ifeq ($(BR2_PACKAGE_NEARD),y)
QT5CONNECTIVITY_DEPENDENCIES += neard
endif

in the .mk file, instead of forcefully selecting both bluez_utils and
neard.

Thanks,

Thomas
Thomas Petazzoni April 18, 2016, 10:01 p.m. UTC | #3
Hello,

On Wed, 13 Apr 2016 23:53:17 +0200, Thomas Petazzoni wrote:

> So until now, neard was not necessary, and without any version bump or
> anything, it should become a mandatory dependency? This seems weird,
> and does not quite follow the policy of Buildroot that we should have
> as much as possible the smallest set of mandatory dependencies.

I just tested, and indeed you can build Qt5Connectivity without
Bluetooth support and have only NFC support. Or build only Bluetooth
support without NFC support.

So could you make these optional?

I'll mark your patch as Changes Requested in patchwork in the mean time.

Thanks!

Thomas
diff mbox

Patch

diff --git a/package/qt5/qt5connectivity/Config.in b/package/qt5/qt5connectivity/Config.in
index d529ea7..611ef14 100644
--- a/package/qt5/qt5connectivity/Config.in
+++ b/package/qt5/qt5connectivity/Config.in
@@ -1,13 +1,15 @@ 
 config BR2_PACKAGE_QT5CONNECTIVITY
 	bool "qt5connectivity"
 	select BR2_PACKAGE_BLUEZ_UTILS
+	select BR2_PACKAGE_NEARD
 	select BR2_PACKAGE_QT5BASE
 	select BR2_PACKAGE_QT5BASE_CONCURRENT
 	select BR2_PACKAGE_QT5BASE_DBUS
-	depends on !BR2_STATIC_LIBS # bluez_utils
-	depends on BR2_USE_WCHAR # bluez_utils
-	depends on BR2_TOOLCHAIN_HAS_THREADS # bluez_utils
-	depends on BR2_USE_MMU # bluez_utils
+	depends on !BR2_STATIC_LIBS # bluez_utils, neard
+	depends on BR2_USE_WCHAR # bluez_utils, neard
+	depends on BR2_TOOLCHAIN_HAS_THREADS # bluez_utils, neard
+	depends on BR2_USE_MMU # bluez_utils, neard
+	depends on BR2_TOOLCHAIN_HAS_SYNC_4 # neard
 	help
 	  Qt is a cross-platform application and UI framework for
 	  developers using C++.
diff --git a/package/qt5/qt5connectivity/qt5connectivity.mk b/package/qt5/qt5connectivity/qt5connectivity.mk
index 936bc6f..ff82b9d 100644
--- a/package/qt5/qt5connectivity/qt5connectivity.mk
+++ b/package/qt5/qt5connectivity/qt5connectivity.mk
@@ -7,7 +7,7 @@ 
 QT5CONNECTIVITY_VERSION = $(QT5_VERSION)
 QT5CONNECTIVITY_SITE = $(QT5_SITE)
 QT5CONNECTIVITY_SOURCE = qtconnectivity-opensource-src-$(QT5CONNECTIVITY_VERSION).tar.xz
-QT5CONNECTIVITY_DEPENDENCIES = bluez_utils qt5base
+QT5CONNECTIVITY_DEPENDENCIES = bluez_utils neard qt5base
 QT5CONNECTIVITY_INSTALL_STAGING = YES
 
 ifeq ($(BR2_PACKAGE_QT5BASE_LICENSE_APPROVED),y)
@@ -38,12 +38,14 @@  endef
 ifeq ($(BR2_PACKAGE_QT5DECLARATIVE_QUICK),y)
 define QT5CONNECTIVITY_INSTALL_TARGET_QMLS
 	cp -dpfr $(STAGING_DIR)/usr/qml/QtBluetooth $(TARGET_DIR)/usr/qml/
+	cp -dpfr $(STAGING_DIR)/usr/qml/QtNfc $(TARGET_DIR)/usr/qml/
 endef
 endif
 
 define QT5CONNECTIVITY_INSTALL_TARGET_CMDS
 	cp -dpf $(STAGING_DIR)/usr/lib/libQt5Bluetooth.so.* $(TARGET_DIR)/usr/lib
 	cp -dpf $(STAGING_DIR)/usr/bin/sdpscanner $(TARGET_DIR)/usr/bin
+	cp -dpf $(STAGING_DIR)/usr/lib/libQt5Nfc.so.* $(TARGET_DIR)/usr/lib
 	$(QT5CONNECTIVITY_INSTALL_TARGET_QMLS)
 endef