* [Buildroot] [PATCH v2] package/xmlstarlet: fix host build
@ 2017-09-02 20:07 Romain Naour
2017-09-02 21:12 ` Thomas Petazzoni
2017-10-16 21:44 ` Peter Korsgaard
0 siblings, 2 replies; 3+ messages in thread
From: Romain Naour @ 2017-09-02 20:07 UTC (permalink / raw)
To: buildroot
Provide the path to HOST_DIR for libxml, libxslt and libiconv like for
the target variant to avoid a build issue on host where /bin is a
symlink to /usr/bin.
Indeed, the configure script use a custom m4 macro XSTAR_LIB_CHECK to
find xml2-config:
XSTAR_LIB_CHECK([LIBXML], [xml2-config])
This macro come from a local m4 file m4/xstar-check-libs.m4 where it
use:
AC_PATH_PROG(LIBXXX()_CONFIG, xxx_config(),
[], [$LIBXXX()_PREFIX/bin$PATH_SEPARATOR$PATH]
Since no prefix seems to be defined by $LIBXXX()_PREFIX, AC_PATH_PROG
look by itself at /bin/ for xml2-config. So the PATH variable set
by Buildroot containing HOST_DIR/bin is ignored.
The wrong xml2-config is used during the build and the build fail
when no xml2 headers are installed on the host.
Fixes:
src/xml_C14N.c:12:31: erreur fatale?: libxml/xmlversion.h : No such file or directory
#include <libxml/xmlversion.h>
^
In file included from src/trans.c:4:0:
src/trans.h:32:30: erreur fatale?: libxml/xmlmemory.h : No such file or directory
#include <libxml/xmlmemory.h>
Signed-off-by: Romain Naour <romain.naour@gmail.com>
Cc: Bernd Kuhls <bernd.kuhls@t-online.de>
---
v2: improve the commit message (ThomasP)
---
package/xmlstarlet/xmlstarlet.mk | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/package/xmlstarlet/xmlstarlet.mk b/package/xmlstarlet/xmlstarlet.mk
index 9920dcf..673eedb 100644
--- a/package/xmlstarlet/xmlstarlet.mk
+++ b/package/xmlstarlet/xmlstarlet.mk
@@ -26,5 +26,10 @@ endif
HOST_XMLSTARLET_DEPENDENCIES += host-libxml2 host-libxslt
+HOST_XMLSTARLET_CONF_OPTS += \
+ --with-libxml-prefix=$(HOST_DIR)/usr \
+ --with-libxslt-prefix=$(HOST_DIR)/usr \
+ --with-libiconv-prefix=$(HOST_DIR)/usr
+
$(eval $(autotools-package))
$(eval $(host-autotools-package))
--
2.9.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Buildroot] [PATCH v2] package/xmlstarlet: fix host build
2017-09-02 20:07 [Buildroot] [PATCH v2] package/xmlstarlet: fix host build Romain Naour
@ 2017-09-02 21:12 ` Thomas Petazzoni
2017-10-16 21:44 ` Peter Korsgaard
1 sibling, 0 replies; 3+ messages in thread
From: Thomas Petazzoni @ 2017-09-02 21:12 UTC (permalink / raw)
To: buildroot
Hello,
On Sat, 2 Sep 2017 22:07:41 +0200, Romain Naour wrote:
> Fixes:
> src/xml_C14N.c:12:31: erreur fatale?: libxml/xmlversion.h : No such file or directory
> #include <libxml/xmlversion.h>
> ^
> In file included from src/trans.c:4:0:
> src/trans.h:32:30: erreur fatale?: libxml/xmlmemory.h : No such file or directory
> #include <libxml/xmlmemory.h>
Still some french messages here, so I've fixed that.
> +HOST_XMLSTARLET_CONF_OPTS += \
> + --with-libxml-prefix=$(HOST_DIR)/usr \
> + --with-libxslt-prefix=$(HOST_DIR)/usr \
> + --with-libiconv-prefix=$(HOST_DIR)/usr
The last option is not needed, we don't have libiconv on the host.
Committed with those issues fixed. Thanks!
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Buildroot] [PATCH v2] package/xmlstarlet: fix host build
2017-09-02 20:07 [Buildroot] [PATCH v2] package/xmlstarlet: fix host build Romain Naour
2017-09-02 21:12 ` Thomas Petazzoni
@ 2017-10-16 21:44 ` Peter Korsgaard
1 sibling, 0 replies; 3+ messages in thread
From: Peter Korsgaard @ 2017-10-16 21:44 UTC (permalink / raw)
To: buildroot
>>>>> "Romain" == Romain Naour <romain.naour@gmail.com> writes:
> Provide the path to HOST_DIR for libxml, libxslt and libiconv like for
> the target variant to avoid a build issue on host where /bin is a
> symlink to /usr/bin.
> Indeed, the configure script use a custom m4 macro XSTAR_LIB_CHECK to
> find xml2-config:
> XSTAR_LIB_CHECK([LIBXML], [xml2-config])
> This macro come from a local m4 file m4/xstar-check-libs.m4 where it
> use:
> AC_PATH_PROG(LIBXXX()_CONFIG, xxx_config(),
> [], [$LIBXXX()_PREFIX/bin$PATH_SEPARATOR$PATH]
> Since no prefix seems to be defined by $LIBXXX()_PREFIX, AC_PATH_PROG
> look by itself at /bin/ for xml2-config. So the PATH variable set
> by Buildroot containing HOST_DIR/bin is ignored.
> The wrong xml2-config is used during the build and the build fail
> when no xml2 headers are installed on the host.
> Fixes:
> src/xml_C14N.c:12:31: erreur fatale?: libxml/xmlversion.h : No such file or directory
> #include <libxml/xmlversion.h>
> ^
> In file included from src/trans.c:4:0:
> src/trans.h:32:30: erreur fatale?: libxml/xmlmemory.h : No such file or directory
> #include <libxml/xmlmemory.h>
> Signed-off-by: Romain Naour <romain.naour@gmail.com>
> Cc: Bernd Kuhls <bernd.kuhls@t-online.de>
> ---
> v2: improve the commit message (ThomasP)
Committed to 2017.08.x, thanks.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-10-16 21:44 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-09-02 20:07 [Buildroot] [PATCH v2] package/xmlstarlet: fix host build Romain Naour
2017-09-02 21:12 ` Thomas Petazzoni
2017-10-16 21:44 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox