All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] package/opencv: gpu module depends on !BR2_STATIC_LIBS
@ 2016-05-14 21:09 Samuel Martin
  2016-05-14 21:09 ` [Buildroot] [PATCH 1/2] package/android-tools: fix indentation in Config.in.host Samuel Martin
  2016-05-14 21:09 ` [Buildroot] [PATCH 2/2] package/android-tools: fix host tools dependency Samuel Martin
  0 siblings, 2 replies; 6+ messages in thread
From: Samuel Martin @ 2016-05-14 21:09 UTC (permalink / raw)
  To: buildroot

GPU support and related features (GL and CL) are detected and loaded at
runtime, so it requires libdl which is only available on
!BR2_STATIC_LIBS builds.

Because the OpenCV tests sets use these modules, they also requires
libdl, so they cannot be built when BR2_STATIC_LIBS is enable.

Fixes:
  http://autobuild.buildroot.net/results/570/57007a8d22d20b2fc5cd64154f5ec674b0842afa/

Signed-off-by: Samuel Martin <s.martin49@gmail.com>
---
 package/opencv/Config.in | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/package/opencv/Config.in b/package/opencv/Config.in
index 908eb37..a932858 100644
--- a/package/opencv/Config.in
+++ b/package/opencv/Config.in
@@ -57,9 +57,13 @@ config BR2_PACKAGE_OPENCV_LIB_GPU
 	select BR2_PACKAGE_OPENCV_LIB_OBJDETECT
 	select BR2_PACKAGE_OPENCV_LIB_PHOTO
 	select BR2_PACKAGE_OPENCV_LIB_VIDEO
+	depends on !BR2_STATIC_LIBS
 	help
 	  Include opencv_gpu module into the OpenCV build.
 
+comment "gpu module needs a toolchain w/ dynamic libraries"
+	depends on BR2_STATIC_LIBS
+
 config BR2_PACKAGE_OPENCV_LIB_HIGHGUI
 	bool "highgui"
 	default y
@@ -165,13 +169,21 @@ config BR2_PACKAGE_OPENCV_LIB_VIDEOSTAB
 	help
 	  Include opencv_videostab module into the OpenCV build.
 
+if !BR2_STATIC_LIBS
+
 comment "Test sets"
+
 config BR2_PACKAGE_OPENCV_BUILD_TESTS
 	bool "build tests"
 
 config BR2_PACKAGE_OPENCV_BUILD_PERF_TESTS
 	bool "build performance tests"
 
+endif
+
+comment "Tests sets need a toolchain w/ dynamic libraries"
+	depends on BR2_STATIC_LIBS
+
 comment "3rd party support"
 
 config BR2_PACKAGE_OPENCV_WITH_FFMPEG
-- 
2.8.2

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/2] package/android-tools: fix indentation in Config.in.host
  2016-05-14 21:09 [Buildroot] [PATCH] package/opencv: gpu module depends on !BR2_STATIC_LIBS Samuel Martin
@ 2016-05-14 21:09 ` Samuel Martin
  2016-05-15 19:34   ` Thomas Petazzoni
  2016-05-14 21:09 ` [Buildroot] [PATCH 2/2] package/android-tools: fix host tools dependency Samuel Martin
  1 sibling, 1 reply; 6+ messages in thread
From: Samuel Martin @ 2016-05-14 21:09 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Samuel Martin <s.martin49@gmail.com>
---
 package/android-tools/Config.in.host | 34 +++++++++++++++++-----------------
 1 file changed, 17 insertions(+), 17 deletions(-)

diff --git a/package/android-tools/Config.in.host b/package/android-tools/Config.in.host
index 1c3a519..4326014 100644
--- a/package/android-tools/Config.in.host
+++ b/package/android-tools/Config.in.host
@@ -1,26 +1,26 @@
 config BR2_PACKAGE_HOST_ANDROID_TOOLS
-       bool "host android-tools"
-       select BR2_PACKAGE_ANDROID_TOOLS_ADB if \
-              !BR2_PACKAGE_ANDROID_TOOLS_FASTBOOT
-       help
-         This package contains the fastboot and adb utilities, that
-         can be used to interact with target devices using of these
-         protocols.
+	bool "host android-tools"
+	select BR2_PACKAGE_ANDROID_TOOLS_ADB if \
+		!BR2_PACKAGE_ANDROID_TOOLS_FASTBOOT
+	help
+	  This package contains the fastboot and adb utilities, that
+	  can be used to interact with target devices using of these
+	  protocols.
 
 if BR2_PACKAGE_HOST_ANDROID_TOOLS
 
 config BR2_PACKAGE_HOST_ANDROID_TOOLS_FASTBOOT
-       bool "fastboot"
-       help
-         This option will build and install the fastboot utility for
-         the host, which can be used to reflash target devices
-         implementing the fastboot protocol.
+	bool "fastboot"
+	help
+	  This option will build and install the fastboot utility for
+	  the host, which can be used to reflash target devices
+	  implementing the fastboot protocol.
 
 config BR2_PACKAGE_HOST_ANDROID_TOOLS_ADB
-       bool "adb"
-       help
-         This option will build and install the adb utility for the
-         host, which can be used to interact with target devices
-         implementing the ADB protocol.
+	bool "adb"
+	help
+	  This option will build and install the adb utility for the
+	  host, which can be used to interact with target devices
+	  implementing the ADB protocol.
 
 endif
-- 
2.8.2

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 2/2] package/android-tools: fix host tools dependency
  2016-05-14 21:09 [Buildroot] [PATCH] package/opencv: gpu module depends on !BR2_STATIC_LIBS Samuel Martin
  2016-05-14 21:09 ` [Buildroot] [PATCH 1/2] package/android-tools: fix indentation in Config.in.host Samuel Martin
@ 2016-05-14 21:09 ` Samuel Martin
  2016-05-15 19:36   ` Thomas Petazzoni
  1 sibling, 1 reply; 6+ messages in thread
From: Samuel Martin @ 2016-05-14 21:09 UTC (permalink / raw)
  To: buildroot

Host android-tools only makes sense when the target package is enable,
so make it available only when the android-tools is already part of the
target package selection.

This change fixes in a simpler way the missing selection on
BR2_PACKAGE_ANDROID_TOOLS and the missing dependency on BR2_USE_MMU.

This patch fixes the following kconfig warning:

  warning: (BR2_PACKAGE_HOST_ANDROID_TOOLS) selects BR2_PACKAGE_ANDROID_TOOLS_ADB which has unmet direct dependencies (BR2_PACKAGE_ANDROID_TOOLS && BR2_USE_MMU)

Signed-off-by: Samuel Martin <s.martin49@gmail.com>
---
 package/android-tools/Config.in.host | 1 +
 1 file changed, 1 insertion(+)

diff --git a/package/android-tools/Config.in.host b/package/android-tools/Config.in.host
index 4326014..7ac9636 100644
--- a/package/android-tools/Config.in.host
+++ b/package/android-tools/Config.in.host
@@ -1,5 +1,6 @@
 config BR2_PACKAGE_HOST_ANDROID_TOOLS
 	bool "host android-tools"
+	depends on BR2_PACKAGE_ANDROID_TOOLS
 	select BR2_PACKAGE_ANDROID_TOOLS_ADB if \
 		!BR2_PACKAGE_ANDROID_TOOLS_FASTBOOT
 	help
-- 
2.8.2

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/2] package/android-tools: fix indentation in Config.in.host
  2016-05-14 21:09 ` [Buildroot] [PATCH 1/2] package/android-tools: fix indentation in Config.in.host Samuel Martin
@ 2016-05-15 19:34   ` Thomas Petazzoni
  0 siblings, 0 replies; 6+ messages in thread
From: Thomas Petazzoni @ 2016-05-15 19:34 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 14 May 2016 23:09:15 +0200, Samuel Martin wrote:
> Signed-off-by: Samuel Martin <s.martin49@gmail.com>
> ---
>  package/android-tools/Config.in.host | 34 +++++++++++++++++-----------------
>  1 file changed, 17 insertions(+), 17 deletions(-)

Applied to master, thanks.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 2/2] package/android-tools: fix host tools dependency
  2016-05-14 21:09 ` [Buildroot] [PATCH 2/2] package/android-tools: fix host tools dependency Samuel Martin
@ 2016-05-15 19:36   ` Thomas Petazzoni
  2016-05-16  6:57     ` Samuel Martin
  0 siblings, 1 reply; 6+ messages in thread
From: Thomas Petazzoni @ 2016-05-15 19:36 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 14 May 2016 23:09:16 +0200, Samuel Martin wrote:
> Host android-tools only makes sense when the target package is enable,
> so make it available only when the android-tools is already part of the
> target package selection.
> 
> This change fixes in a simpler way the missing selection on
> BR2_PACKAGE_ANDROID_TOOLS and the missing dependency on BR2_USE_MMU.
> 
> This patch fixes the following kconfig warning:
> 
>   warning: (BR2_PACKAGE_HOST_ANDROID_TOOLS) selects BR2_PACKAGE_ANDROID_TOOLS_ADB which has unmet direct dependencies (BR2_PACKAGE_ANDROID_TOOLS && BR2_USE_MMU)
> 
> Signed-off-by: Samuel Martin <s.martin49@gmail.com>
> ---
>  package/android-tools/Config.in.host | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/package/android-tools/Config.in.host b/package/android-tools/Config.in.host
> index 4326014..7ac9636 100644
> --- a/package/android-tools/Config.in.host
> +++ b/package/android-tools/Config.in.host
> @@ -1,5 +1,6 @@
>  config BR2_PACKAGE_HOST_ANDROID_TOOLS
>  	bool "host android-tools"
> +	depends on BR2_PACKAGE_ANDROID_TOOLS
>  	select BR2_PACKAGE_ANDROID_TOOLS_ADB if \
>  		!BR2_PACKAGE_ANDROID_TOOLS_FASTBOOT

This is not the correct fix, for two reasons:

 1/ The intent of the "select" is to make sure that either adb or
    fastboot support is enabled, so basically the mistake is that the
    select are using the options of the *target* android-tools package,
    while it should be using the options of the *host* android-tools
    package, defined below in the same file.

 2/ Your assumption that android-tools on the host are needed only if
    android-tools are installed on the target are wrong. The original
    reason for which I started packaging the android-tools is because
    we wanted to have the fastboot command on our host machine, to talk
    to a fastboot implementation in U-Boot. So there's no android-tools
    in the target, but we need android-tools on the host.

So, I committed a fix that simply changes the select to use the
sub-options of the host android-tools package. See
https://git.buildroot.net/buildroot/commit/?id=f0d995cafd0c664f436bc9d082a3bb14b683dd75.

Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 2/2] package/android-tools: fix host tools dependency
  2016-05-15 19:36   ` Thomas Petazzoni
@ 2016-05-16  6:57     ` Samuel Martin
  0 siblings, 0 replies; 6+ messages in thread
From: Samuel Martin @ 2016-05-16  6:57 UTC (permalink / raw)
  To: buildroot

On Sun, May 15, 2016 at 9:36 PM, Thomas Petazzoni
<thomas.petazzoni@free-electrons.com> wrote:
> Hello,
>
> On Sat, 14 May 2016 23:09:16 +0200, Samuel Martin wrote:
>> Host android-tools only makes sense when the target package is enable,
>> so make it available only when the android-tools is already part of the
>> target package selection.
>>
>> This change fixes in a simpler way the missing selection on
>> BR2_PACKAGE_ANDROID_TOOLS and the missing dependency on BR2_USE_MMU.
>>
>> This patch fixes the following kconfig warning:
>>
>>   warning: (BR2_PACKAGE_HOST_ANDROID_TOOLS) selects BR2_PACKAGE_ANDROID_TOOLS_ADB which has unmet direct dependencies (BR2_PACKAGE_ANDROID_TOOLS && BR2_USE_MMU)
>>
>> Signed-off-by: Samuel Martin <s.martin49@gmail.com>
>> ---
>>  package/android-tools/Config.in.host | 1 +
>>  1 file changed, 1 insertion(+)
>>
>> diff --git a/package/android-tools/Config.in.host b/package/android-tools/Config.in.host
>> index 4326014..7ac9636 100644
>> --- a/package/android-tools/Config.in.host
>> +++ b/package/android-tools/Config.in.host
>> @@ -1,5 +1,6 @@
>>  config BR2_PACKAGE_HOST_ANDROID_TOOLS
>>       bool "host android-tools"
>> +     depends on BR2_PACKAGE_ANDROID_TOOLS
>>       select BR2_PACKAGE_ANDROID_TOOLS_ADB if \
>>               !BR2_PACKAGE_ANDROID_TOOLS_FASTBOOT
>
> This is not the correct fix, for two reasons:
>
>  1/ The intent of the "select" is to make sure that either adb or
>     fastboot support is enabled, so basically the mistake is that the
>     select are using the options of the *target* android-tools package,
>     while it should be using the options of the *host* android-tools
>     package, defined below in the same file.
>
>  2/ Your assumption that android-tools on the host are needed only if
>     android-tools are installed on the target are wrong. The original
>     reason for which I started packaging the android-tools is because
>     we wanted to have the fastboot command on our host machine, to talk
>     to a fastboot implementation in U-Boot. So there's no android-tools
>     in the target, but we need android-tools on the host.

Thanks for the clarification, I was not aware of this use-case.

>
> So, I committed a fix that simply changes the select to use the
> sub-options of the host android-tools package. See
> https://git.buildroot.net/buildroot/commit/?id=f0d995cafd0c664f436bc9d082a3bb14b683dd75.
>
> Thanks!
>
> Thomas
> --
> Thomas Petazzoni, CTO, Free Electrons
> Embedded Linux, Kernel and Android engineering
> http://free-electrons.com

Regards,

-- 
Samuel

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2016-05-16  6:57 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-14 21:09 [Buildroot] [PATCH] package/opencv: gpu module depends on !BR2_STATIC_LIBS Samuel Martin
2016-05-14 21:09 ` [Buildroot] [PATCH 1/2] package/android-tools: fix indentation in Config.in.host Samuel Martin
2016-05-15 19:34   ` Thomas Petazzoni
2016-05-14 21:09 ` [Buildroot] [PATCH 2/2] package/android-tools: fix host tools dependency Samuel Martin
2016-05-15 19:36   ` Thomas Petazzoni
2016-05-16  6:57     ` Samuel Martin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.