Skip to contentSkip to conversation

package/lynx: fix build with libidn

PATCH New Vadim Kochan 2 participants 3 messages May 14, 2019 – Jun 6, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 package/lynx: fix build with libidn

In case of BR2_STATIC_LIBS=y the linking with libidn fails because linker can't resolve libiconv symbols needed by libidn. Fix it by required LIBS for libidn generated by pkg-conf.

The issue can be reproduced with the following defconfig:

	BR2_x86_i686=y
	BR2_STATIC_LIBS=y
	BR2_PACKAGE_LIBICONV=y
	BR2_PACKAGE_LIBIDN=y
	BR2_PACKAGE_LYNX=y

Fixes:

	http://autobuild.buildroot.net/results/23a421e15c32b17ff2f69f183a2e8620ecb93316/
---
 package/lynx/lynx.mk | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
package/lynx/lynx.mk +8 -1
index 3ac5b4cabf..b6cc1b2b91 100644
@@ -23,7 +23,7 @@ endif
 ifeq ($(BR2_PACKAGE_OPENSSL),y)
 LYNX_DEPENDENCIES += host-pkgconf openssl
 LYNX_CONF_OPTS += --with-ssl=$(STAGING_DIR)/usr
-LYNX_CONF_ENV = LIBS=`$(PKG_CONFIG_HOST_BINARY) --libs openssl`
+LYNX_LIBS += `$(PKG_CONFIG_HOST_BINARY) --libs openssl`
 else ifeq ($(BR2_PACKAGE_GNUTLS),y)
 LYNX_DEPENDENCIES += gnutls
 LYNX_CONF_OPTS += --with-gnutls
@@ -36,4 +36,11 @@ else
 LYNX_CONF_OPTS += --without-zlib
 endif
 
+ifeq ($(BR2_PACKAGE_LIBIDN),y)
+LYNX_DEPENDENCIES += libidn
+LYNX_LIBS += `$(PKG_CONFIG_HOST_BINARY) --libs libidn`
+endif
+
+LYNX_CONF_ENV = LIBS="$(LYNX_LIBS)"
+
 $(eval $(autotools-package))
Signature · 1 line
2.21.0
#1 lore raw

PATCH 1/1 package/lynx: fix build with libidn

Quoted 14 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Vadim" == Vadim Kochan <[email protected]> writes:

In case of BR2_STATIC_LIBS=y the linking with libidn fails because linker can't resolve libiconv symbols needed by libidn. Fix it by required LIBS for libidn generated by pkg-conf.

The issue can be reproduced with the following defconfig:

	BR2_x86_i686=y
	BR2_STATIC_LIBS=y
	BR2_PACKAGE_LIBICONV=y
	BR2_PACKAGE_LIBIDN=y
	BR2_PACKAGE_LYNX=y
Quoted 4 lines

Fixes:

	http://autobuild.buildroot.net/results/23a421e15c32b17ff2f69f183a2e8620ecb93316/

Committed, thanks.

Signature · 1 line
Bye, Peter Korsgaard
#2 lore raw

PATCH 1/1 package/lynx: fix build with libidn

In reply to Vadim Kochan
Quoted 14 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Vadim" == Vadim Kochan <[email protected]> writes:

In case of BR2_STATIC_LIBS=y the linking with libidn fails because linker can't resolve libiconv symbols needed by libidn. Fix it by required LIBS for libidn generated by pkg-conf.

The issue can be reproduced with the following defconfig:

	BR2_x86_i686=y
	BR2_STATIC_LIBS=y
	BR2_PACKAGE_LIBICONV=y
	BR2_PACKAGE_LIBIDN=y
	BR2_PACKAGE_LYNX=y
Quoted 4 lines

Fixes:

	http://autobuild.buildroot.net/results/23a421e15c32b17ff2f69f183a2e8620ecb93316/

Committed to 2019.02.x, thanks.

Signature · 1 line
Bye, Peter Korsgaard