package/xmlstarlet: fix static linking
authorRomain Naour <romain.naour@openwide.fr>
Mon, 18 Aug 2014 21:35:42 +0000 (23:35 +0200)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Thu, 21 Aug 2014 13:25:50 +0000 (15:25 +0200)
The static linking with libxml2 and lib(e)xslt (--enable-static-libs)
need to be enabled when BR2_PREFER_STATIC_LIB is set.

Fixes:
http://autobuild.buildroot.net/results/0fd/0fd4a65ab98a4cf3fe893c29628608a71e96ecbc/build-end.log

Signed-off-by: Romain Naour <romain.naour@openwide.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/xmlstarlet/xmlstarlet.mk

index 16f736ee88833f86ad0b51fe5f8c32e7b68d5892..7a8451fcd98d3f0106299f42a22d102d43a72ac9 100644 (file)
@@ -12,9 +12,15 @@ XMLSTARLET_LICENSE_FILES = COPYING
 XMLSTARLET_DEPENDENCIES += libxml2 libxslt \
        $(if $(BR2_PACKAGE_LIBICONV),libiconv)
 
-XMLSTARLET_CONF_OPT += --disable-static-libs \
+XMLSTARLET_CONF_OPT += \
        --with-libxml-prefix=${STAGING_DIR}/usr \
        --with-libxslt-prefix=${STAGING_DIR}/usr \
        --with-libiconv-prefix=${STAGING_DIR}/usr
 
+ifeq ($(BR2_PREFER_STATIC_LIB),y)
+XMLSTARLET_CONF_OPT += --enable-static-libs
+else
+XMLSTARLET_CONF_OPT += --disable-static-libs
+endif
+
 $(eval $(autotools-package))