diff mbox

[1/1] package/tvheadend: Add optional dependency to libiconv

Message ID 1402313033-31085-1-git-send-email-bernd.kuhls@t-online.de
State Accepted
Commit a27065eb038f7f8d38d9ba82c5030f16d2628a04
Headers show

Commit Message

Bernd Kuhls June 9, 2014, 11:23 a.m. UTC
To get reproducable builds depend on libiconv if needed.

tvheadend configure either shows

  checking for cc libiconv ...                      fail

or

  checking for cc libiconv ...                      ok

depending on the presence of libiconv, and gets linked

output/host/usr/bin/i586-buildroot-linux-uclibc-readelf -a output/target/usr/bin/tvheadend | grep NEEDED | grep iconv
 0x00000001 (NEEDED)                     Shared library: [libiconv.so.2]

Tested with minimal defconfig

BR2_TOOLCHAIN_BUILDROOT_LARGEFILE=y
BR2_TOOLCHAIN_BUILDROOT_INET_IPV6=y
BR2_PACKAGE_LIBICONV=y
BR2_PACKAGE_TVHEADEND=y

Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
---
 package/tvheadend/tvheadend.mk |    4 ++++
 1 file changed, 4 insertions(+)

Comments

Yann E. MORIN June 9, 2014, 2:04 p.m. UTC | #1
Bernd, All,

On 2014-06-09 13:23 +0200, Bernd Kuhls spake thusly:
> To get reproducable builds depend on libiconv if needed.
> 
> tvheadend configure either shows
> 
>   checking for cc libiconv ...                      fail
> 
> or
> 
>   checking for cc libiconv ...                      ok
> 
> depending on the presence of libiconv, and gets linked
> 
> output/host/usr/bin/i586-buildroot-linux-uclibc-readelf -a output/target/usr/bin/tvheadend | grep NEEDED | grep iconv
>  0x00000001 (NEEDED)                     Shared library: [libiconv.so.2]
> 
> Tested with minimal defconfig
> 
> BR2_TOOLCHAIN_BUILDROOT_LARGEFILE=y
> BR2_TOOLCHAIN_BUILDROOT_INET_IPV6=y
> BR2_PACKAGE_LIBICONV=y
> BR2_PACKAGE_TVHEADEND=y
> 
> Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>

Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>

Regards,
Yann E. MORIN.

> ---
>  package/tvheadend/tvheadend.mk |    4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/package/tvheadend/tvheadend.mk b/package/tvheadend/tvheadend.mk
> index c582c07..4d0a16d 100644
> --- a/package/tvheadend/tvheadend.mk
> +++ b/package/tvheadend/tvheadend.mk
> @@ -14,6 +14,10 @@ ifeq ($(BR2_PACKAGE_AVAHI),y)
>  TVHEADEND_DEPENDENCIES += avahi
>  endif
>  
> +ifeq ($(BR2_PACKAGE_LIBICONV),y)
> +TVHEADEND_DEPENDENCIES += libiconv
> +endif
> +
>  TVHEADEND_DEPENDENCIES += dtv-scan-tables
>  
>  define TVHEADEND_CONFIGURE_CMDS
> -- 
> 1.7.10.4
> 
> _______________________________________________
> buildroot mailing list
> buildroot@busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
Thomas Petazzoni June 9, 2014, 5:58 p.m. UTC | #2
Dear Bernd Kuhls,

On Mon,  9 Jun 2014 13:23:53 +0200, Bernd Kuhls wrote:

> BR2_TOOLCHAIN_BUILDROOT_LARGEFILE=y
> BR2_TOOLCHAIN_BUILDROOT_INET_IPV6=y
> BR2_PACKAGE_LIBICONV=y
> BR2_PACKAGE_TVHEADEND=y

You need libiconv because your toolchain does not have locale support.
Therefore, your Config.in should have something like:

	select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE

see all the other examples in Buildroot.

Thomas
Bernd Kuhls June 11, 2014, 12:14 p.m. UTC | #3
Thomas Petazzoni <thomas.petazzoni-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8
@public.gmane.org> wrote in news:20140609195850.2317401f@free-electrons.com:

> You need libiconv because your toolchain does not have locale support.
> Therefore, your Config.in should have something like:
> 
>      select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
> 
> see all the other examples in Buildroot.

Hi,

libiconv is not a hard-dependency of tvheadend so I thought enabling libiconv 
in the !BR2_ENABLE_LOCALE case is not necessary here.

Regards, Bernd
Peter Korsgaard June 11, 2014, 12:45 p.m. UTC | #4
>>>>> "Bernd" == Bernd Kuhls <bernd.kuhls@t-online.de> writes:

 > Thomas Petazzoni <thomas.petazzoni-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8
 > @public.gmane.org> wrote in news:20140609195850.2317401f@free-electrons.com:

 >> You need libiconv because your toolchain does not have locale support.
 >> Therefore, your Config.in should have something like:
 >> 
 >> select BR2_PACKAGE_LIBICONV if !BR2_ENABLE_LOCALE
 >> 
 >> see all the other examples in Buildroot.

 > Hi,

 > libiconv is not a hard-dependency of tvheadend so I thought enabling libiconv 
 > in the !BR2_ENABLE_LOCALE case is not necessary here.

Ahh, so it's just an optional dependency it CAN use if available? Then
the patch is fine.

Somehow I don't see it anymore in patchwork though?
Bernd Kuhls June 11, 2014, 1:03 p.m. UTC | #5
Peter Korsgaard <jacmet@uclibc.org> wrote in
news:877g4nipi0.fsf@dell.be.48ers.dk: 

> Somehow I don't see it anymore in patchwork though?

Hi,

here you can find v2: http://patchwork.ozlabs.org/patch/358660/

Regards, Bernd
diff mbox

Patch

diff --git a/package/tvheadend/tvheadend.mk b/package/tvheadend/tvheadend.mk
index c582c07..4d0a16d 100644
--- a/package/tvheadend/tvheadend.mk
+++ b/package/tvheadend/tvheadend.mk
@@ -14,6 +14,10 @@  ifeq ($(BR2_PACKAGE_AVAHI),y)
 TVHEADEND_DEPENDENCIES += avahi
 endif
 
+ifeq ($(BR2_PACKAGE_LIBICONV),y)
+TVHEADEND_DEPENDENCIES += libiconv
+endif
+
 TVHEADEND_DEPENDENCIES += dtv-scan-tables
 
 define TVHEADEND_CONFIGURE_CMDS