Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [git commit] libupnpp: fix static linking issue with libcurl
@ 2015-05-14 20:44 Peter Korsgaard
  2015-05-14 21:14 ` Thomas Petazzoni
  0 siblings, 1 reply; 3+ messages in thread
From: Peter Korsgaard @ 2015-05-14 20:44 UTC (permalink / raw)
  To: buildroot

commit: http://git.buildroot.net/buildroot/commit/?id=f7638ca23229bc9dfe3696f562afc63bda6bd1f0
branch: http://git.buildroot.net/buildroot/commit/?id=refs/heads/master

Fixes:
http://autobuild.buildroot.net/results/f38/f383bf4d7572a7dd59d382cd06a9baeb37e9161c/
http://autobuild.buildroot.net/results/d93/d934871d1b192706cd9163715c5ebcd96deff2b8/

Libcurl optionally links to a number of libraries that have to be taken into
consideration when linking statically.

Use pkg-config to get the correct libcurl link line, and also use it for
libupnp instead of the hardcoded list.

Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
---
 package/libupnpp/libupnpp.mk |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/package/libupnpp/libupnpp.mk b/package/libupnpp/libupnpp.mk
index 853a724..defc16a 100644
--- a/package/libupnpp/libupnpp.mk
+++ b/package/libupnpp/libupnpp.mk
@@ -12,9 +12,11 @@ LIBUPNPP_INSTALL_STAGING = YES
 LIBUPNPP_DEPENDENCIES = expat libcurl libupnp
 
 # configure script fails to link against the dependencies of libupnp
-# causing upnp detection to fail when statically linking
+# and libcurl causing detection to fail when statically linking
 ifeq ($(BR2_STATIC_LIBS),y)
-LIBUPNPP_CONF_ENV += LIBS='-lthreadutil -lixml -pthread'
+LIBUPNPP_DEPENDENCIES += host-pkgconf
+LIBUPNPP_CONF_ENV += \
+	LIBS='$(shell $(PKG_CONFIG_HOST_BINARY) --libs libupnp libcurl)'
 endif
 
 $(eval $(autotools-package))

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

* [Buildroot] [git commit] libupnpp: fix static linking issue with libcurl
  2015-05-14 20:44 [Buildroot] [git commit] libupnpp: fix static linking issue with libcurl Peter Korsgaard
@ 2015-05-14 21:14 ` Thomas Petazzoni
  2015-05-14 21:17   ` Peter Korsgaard
  0 siblings, 1 reply; 3+ messages in thread
From: Thomas Petazzoni @ 2015-05-14 21:14 UTC (permalink / raw)
  To: buildroot

Dear Peter Korsgaard,

On Thu, 14 May 2015 22:44:06 +0200, Peter Korsgaard wrote:

>  # configure script fails to link against the dependencies of libupnp
> -# causing upnp detection to fail when statically linking
> +# and libcurl causing detection to fail when statically linking
>  ifeq ($(BR2_STATIC_LIBS),y)
> -LIBUPNPP_CONF_ENV += LIBS='-lthreadutil -lixml -pthread'
> +LIBUPNPP_DEPENDENCIES += host-pkgconf
> +LIBUPNPP_CONF_ENV += \
> +	LIBS='$(shell $(PKG_CONFIG_HOST_BINARY) --libs libupnp libcurl)'
>  endif

I'm glad to see that we're moving away from a hardcoded LIBS value to
using pkg-config :-)

Thanks,

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

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

* [Buildroot] [git commit] libupnpp: fix static linking issue with libcurl
  2015-05-14 21:14 ` Thomas Petazzoni
@ 2015-05-14 21:17   ` Peter Korsgaard
  0 siblings, 0 replies; 3+ messages in thread
From: Peter Korsgaard @ 2015-05-14 21:17 UTC (permalink / raw)
  To: buildroot

>>>>> "Thomas" == Thomas Petazzoni <thomas.petazzoni@free-electrons.com> writes:

 > Dear Peter Korsgaard,
 > On Thu, 14 May 2015 22:44:06 +0200, Peter Korsgaard wrote:

 >> # configure script fails to link against the dependencies of libupnp
 >> -# causing upnp detection to fail when statically linking
 >> +# and libcurl causing detection to fail when statically linking
 >> ifeq ($(BR2_STATIC_LIBS),y)
 >> -LIBUPNPP_CONF_ENV += LIBS='-lthreadutil -lixml -pthread'
 >> +LIBUPNPP_DEPENDENCIES += host-pkgconf
 >> +LIBUPNPP_CONF_ENV += \
 >> +	LIBS='$(shell $(PKG_CONFIG_HOST_BINARY) --libs libupnp libcurl)'
 >> endif

 > I'm glad to see that we're moving away from a hardcoded LIBS value to
 > using pkg-config :-)

Yeah ;)

-- 
Venlig hilsen,
Peter Korsgaard 

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

end of thread, other threads:[~2015-05-14 21:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-14 20:44 [Buildroot] [git commit] libupnpp: fix static linking issue with libcurl Peter Korsgaard
2015-05-14 21:14 ` Thomas Petazzoni
2015-05-14 21:17   ` Peter Korsgaard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox