You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

139 lines
3.0 KiB

  1. #
  2. # Copyright (C) 2006-2016 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=libxml2
  9. PKG_VERSION:=2.9.5
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=http://gd.tuwien.ac.at/languages/libxml/ \
  13. http://xmlsoft.org/sources/ \
  14. ftp://fr.rpmfind.net/pub/libxml/
  15. PKG_HASH:=4031c1ecee9ce7ba4f313e91ef6284164885cdb69937a123f6a83bb6a72dcd38
  16. PKG_LICENSE:=MIT
  17. PKG_LICENSE_FILES:=COPYING
  18. PKG_MAINTAINER:=Michael Heimpold <mhei@heimpold.de>
  19. PKG_FIXUP:=autoreconf
  20. PKG_INSTALL:=1
  21. PKG_BUILD_PARALLEL:=0
  22. include $(INCLUDE_DIR)/host-build.mk
  23. include $(INCLUDE_DIR)/package.mk
  24. define Package/libxml2
  25. SECTION:=libs
  26. CATEGORY:=Libraries
  27. TITLE:=Gnome XML library
  28. URL:=http://xmlsoft.org/
  29. DEPENDS:=+libpthread +zlib
  30. endef
  31. define Package/libxml2/description
  32. A library for manipulating XML and HTML resources.
  33. endef
  34. TARGET_CFLAGS += $(FPIC)
  35. CONFIGURE_ARGS += \
  36. --enable-shared \
  37. --enable-static \
  38. --with-c14n \
  39. --without-catalog \
  40. --with-debug \
  41. --without-docbook \
  42. --with-html \
  43. --without-ftp \
  44. --without-http \
  45. --without-iconv \
  46. --without-iso8859x \
  47. --without-legacy \
  48. --with-output \
  49. --without-pattern \
  50. --without-push \
  51. --without-python \
  52. --with-reader \
  53. --without-readline \
  54. --without-regexps \
  55. --with-sax1 \
  56. --with-schemas \
  57. --with-threads \
  58. --with-tree \
  59. --with-valid \
  60. --with-writer \
  61. --with-xinclude \
  62. --with-xpath \
  63. --with-xptr \
  64. --with-zlib=$(STAGING_DIR)/usr \
  65. --without-lzma
  66. HOST_CONFIGURE_ARGS += \
  67. --enable-shared \
  68. --enable-static \
  69. --with-c14n \
  70. --without-catalog \
  71. --with-debug \
  72. --without-docbook \
  73. --with-html \
  74. --without-ftp \
  75. --without-http \
  76. --without-iconv \
  77. --without-iso8859x \
  78. --without-legacy \
  79. --with-output \
  80. --without-pattern \
  81. --without-push \
  82. --without-python \
  83. --with-reader \
  84. --without-readline \
  85. --without-regexps \
  86. --with-sax1 \
  87. --with-schemas \
  88. --with-threads \
  89. --with-tree \
  90. --with-valid \
  91. --with-writer \
  92. --with-xinclude \
  93. --with-xpath \
  94. --with-xptr \
  95. --with-zlib \
  96. --without-lzma
  97. define Build/InstallDev
  98. $(INSTALL_DIR) $(2)/bin
  99. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/xml2-config $(2)/bin/
  100. $(SED) 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' $(2)/bin/xml2-config
  101. $(INSTALL_DIR) $(1)/usr/include
  102. $(CP) $(PKG_INSTALL_DIR)/usr/include/libxml2 $(1)/usr/include/
  103. $(INSTALL_DIR) $(1)/usr/lib
  104. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libxml2.{la,a,so*} $(1)/usr/lib/
  105. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  106. $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libxml-2.0.pc $(1)/usr/lib/pkgconfig/
  107. $(INSTALL_DIR) $(2)/share/aclocal/
  108. $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/aclocal/* $(2)/share/aclocal
  109. endef
  110. define Package/libxml2/install
  111. $(INSTALL_DIR) $(1)/usr/lib
  112. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libxml2.so* $(1)/usr/lib/
  113. endef
  114. define Host/Install
  115. $(SED) 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' $(HOST_BUILD_DIR)/xml2-config
  116. $(call Host/Install/Default)
  117. endef
  118. $(eval $(call HostBuild))
  119. $(eval $(call BuildPackage,libxml2))