Makefile 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include ${TOPDIR}/rules.mk
  4. PKG_NAME:= libxml2
  5. PKG_VERSION:= 2.9.1
  6. PKG_RELEASE:= 6
  7. PKG_MD5SUM:= 9c0cfef285d5c4a5c80d00904ddab380
  8. PKG_DESCR:= xml parser and toolkit
  9. PKG_SECTION:= libs/data
  10. PKG_DEPENDS:= zlib
  11. PKG_BUILDDEP:= libxml2-host zlib
  12. HOST_BUILDDEP:= python2-host
  13. PKG_URL:= http://www.xmlsoft.org/
  14. PKG_SITES:= http://xmlsoft.org/sources/
  15. PKG_OPTS:= dev
  16. DISTFILES:= ${PKG_NAME}-${PKG_VERSION}.tar.gz
  17. PKG_SUBPKGS:= LIBXML2 LIBXML2_PYTHON
  18. PKGSD_LIBXML2_PYTHON:= XML python bindings
  19. PKGSC_LIBXML2_PYTHON:= libs/misc
  20. PKGSB_LIBXML2_PYTHON:= python2
  21. PKGSS_LIBXML2_PYTHON:= python2
  22. include ${TOPDIR}/mk/host.mk
  23. include ${TOPDIR}/mk/package.mk
  24. $(eval $(call HOST_template,LIBXML2,libxml2,${PKG_VERSION}-${PKG_RELEASE}))
  25. $(eval $(call PKG_template,LIBXML2,libxml2,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION},${PKG_OPTS}))
  26. $(eval $(call PKG_template,LIBXML2_PYTHON,libxml2-python,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKGSD_LIBXML2_PYTHON},${PKGSC_LIBXML2_PYTHON}))
  27. include $(TOPDIR)/mk/python.mk
  28. HOST_STYLE:= auto
  29. HOST_CONFIGURE_ARGS+= --with-python \
  30. --without-iconv \
  31. --without-lzma \
  32. --without-zlib
  33. HOST_MAKE_FLAGS+= LDFLAGS=-lpthread
  34. AUTOTOOL_STYLE:= autoreconf
  35. TARGET_LDFLAGS+= -lpthread
  36. ifneq ($(ADK_PACKAGE_LIBXML2_PYTHON),)
  37. CONFIGURE_ARGS+= --with-python
  38. else
  39. CONFIGURE_ARGS+= --without-python
  40. endif
  41. CONFIGURE_ARGS+= --without-c14n \
  42. --without-debug \
  43. --without-docbook \
  44. --with-catalog \
  45. --with-html \
  46. --without-ftp \
  47. --without-http \
  48. --without-iconv \
  49. --without-iso8859x \
  50. --without-legacy \
  51. --with-output \
  52. --without-pattern \
  53. --without-push \
  54. --with-reader \
  55. --without-readline \
  56. --without-regexps \
  57. --with-sax1 \
  58. --with-schemas \
  59. --with-threads \
  60. --with-tree \
  61. --with-valid \
  62. --with-writer \
  63. --with-xinclude \
  64. --with-xpath \
  65. --with-xptr \
  66. --with-zlib
  67. libxml2-install:
  68. ${INSTALL_DIR} ${IDIR_LIBXML2}/usr/lib
  69. ${CP} ${WRKINST}/usr/lib/libxml2.so* ${IDIR_LIBXML2}/usr/lib
  70. libxml2-python-install:
  71. $(INSTALL_DIR) $(IDIR_LIBXML2_PYTHON)/usr/lib/python$(PYTHON_VERSION)/site-packages
  72. $(CP) $(WRKINST)/usr/lib/python$(PYTHON_VERSION)/site-packages/*.{so,py} \
  73. $(IDIR_LIBXML2_PYTHON)/usr/lib/python$(PYTHON_VERSION)/site-packages
  74. include ${TOPDIR}/mk/host-bottom.mk
  75. include ${TOPDIR}/mk/pkg-bottom.mk