Patchwork [07/16] libxml2: don't use ldl dependency with mingw32

login
register
mail settings
Submitter Yann Diorcet
Date Oct. 21, 2012, 3:37 p.m.
Message ID <1350833876-9499-7-git-send-email-diorcet.yann@gmail.com>
Download mbox | patch
Permalink /patch/193031/
State Accepted
Delegated to: Esben Haabendal
Headers show

Comments

Yann Diorcet - Oct. 21, 2012, 3:37 p.m.
From: Yann Diorcet <yann.diorcet@belledonne-communications.com>

---
 recipes/libxml/libxml2.inc |   14 +++++++++-----
 1 file changed, 9 insertions(+), 5 deletions(-)
Esben Haabendal - Feb. 28, 2013, 1:22 p.m.
Yann Diorcet <diorcet.yann@gmail.com> writes:

> From: Yann Diorcet <yann.diorcet@belledonne-communications.com>
>
> ---
>  recipes/libxml/libxml2.inc |   14 +++++++++-----
>  1 file changed, 9 insertions(+), 5 deletions(-)
>
> diff --git a/recipes/libxml/libxml2.inc b/recipes/libxml/libxml2.inc
> index ac3993c..ef4a854 100644
> --- a/recipes/libxml/libxml2.inc
> +++ b/recipes/libxml/libxml2.inc
> @@ -6,8 +6,10 @@ inherit autotools pkgconfig library binconfig
>  
>  SRC_URI = "ftp://xmlsoft.org/${PN}/${PN}-${PV}.tar.gz"
>  
> -DEPENDS = "libdl libm"
> -RDEPENDS_${PN} = "libdl libm"
> +DEPENDS = "${DEPENDS_LIBDL} libm"
> +DEPENDS_LIBDL = "libdl"
> +DEPENDS_LIBDL:TARGET_OS_mingw32 = ""
> +RDEPENDS_${PN} = "${DEPENDS}"

I renamed it to DEPENDS_HOST_OS while merging.

>  
>  EXTRA_OECONF = "\
>   --without-legacy \
> @@ -16,10 +18,12 @@ EXTRA_OECONF = "\
>   --without-python \
>   --with-c14n"
>  
> -export LDFLAGS += "-ldl"
> +LDFLAGS_LDL = "-ldl"
> +LDFLAGS_LDL:TARGET_OS_mingw32 = ""
> +export LDFLAGS += "${LDFLAGS_LDL}"
>  
>  PACKAGES =+ "${PN}-utils"
> -FILES_${PN} = "${libexecdir}/* ${libdir}/lib*${SOLIBS} \
> +FILES_${PN} = "${libexecdir}/* ${sharedlibdir}/lib*${SOLIBS} \
>              ${sysconfdir} ${sharedstatedir} ${localstatedir} \
>              ${base_libdir}/*${SOLIBS} \
>              ${datadir}/${PN} ${libdir}/${PN}/* \
> @@ -27,5 +31,5 @@ FILES_${PN} = "${libexecdir}/* ${libdir}/lib*${SOLIBS} \
>              ${datadir}/idl ${datadir}/omf ${datadir}/sounds \
>              ${libdir}/bonobo/servers"
>  
> -FILES_${PN}-utils = "${bindir}/xmllint ${bindir}/xmlcatalog ${libdir}/*.sh"
> +FILES_${PN}-utils = "${bindir}/xmllint* ${bindir}/xmlcatalog* ${libdir}/*.sh"
>  FILES_${PN}-doc += "${datadir}/gtk-doc"

Merged to master with the small change described above, thanks.

/Esben

Patch

diff --git a/recipes/libxml/libxml2.inc b/recipes/libxml/libxml2.inc
index ac3993c..ef4a854 100644
--- a/recipes/libxml/libxml2.inc
+++ b/recipes/libxml/libxml2.inc
@@ -6,8 +6,10 @@  inherit autotools pkgconfig library binconfig
 
 SRC_URI = "ftp://xmlsoft.org/${PN}/${PN}-${PV}.tar.gz"
 
-DEPENDS = "libdl libm"
-RDEPENDS_${PN} = "libdl libm"
+DEPENDS = "${DEPENDS_LIBDL} libm"
+DEPENDS_LIBDL = "libdl"
+DEPENDS_LIBDL:TARGET_OS_mingw32 = ""
+RDEPENDS_${PN} = "${DEPENDS}"
 
 EXTRA_OECONF = "\
  --without-legacy \
@@ -16,10 +18,12 @@  EXTRA_OECONF = "\
  --without-python \
  --with-c14n"
 
-export LDFLAGS += "-ldl"
+LDFLAGS_LDL = "-ldl"
+LDFLAGS_LDL:TARGET_OS_mingw32 = ""
+export LDFLAGS += "${LDFLAGS_LDL}"
 
 PACKAGES =+ "${PN}-utils"
-FILES_${PN} = "${libexecdir}/* ${libdir}/lib*${SOLIBS} \
+FILES_${PN} = "${libexecdir}/* ${sharedlibdir}/lib*${SOLIBS} \
             ${sysconfdir} ${sharedstatedir} ${localstatedir} \
             ${base_libdir}/*${SOLIBS} \
             ${datadir}/${PN} ${libdir}/${PN}/* \
@@ -27,5 +31,5 @@  FILES_${PN} = "${libexecdir}/* ${libdir}/lib*${SOLIBS} \
             ${datadir}/idl ${datadir}/omf ${datadir}/sounds \
             ${libdir}/bonobo/servers"
 
-FILES_${PN}-utils = "${bindir}/xmllint ${bindir}/xmlcatalog ${libdir}/*.sh"
+FILES_${PN}-utils = "${bindir}/xmllint* ${bindir}/xmlcatalog* ${libdir}/*.sh"
 FILES_${PN}-doc += "${datadir}/gtk-doc"