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.

92 lines
2.8 KiB

  1. #
  2. # Copyright (C) 2015-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:=xerces-c
  9. PKG_VERSION:=3.2.3
  10. PKG_RELEASE:=3
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  12. PKG_SOURCE_URL:=@APACHE/xerces/c/3/sources
  13. PKG_HASH:=12fc99a9fc1d1a79bd0e927b8b5637a576d6656f45b0d5e70ee3694d379cc149
  14. PKG_MAINTAINER:=Álvaro Fernández Rojas <noltari@gmail.com>
  15. PKG_LICENSE:=Apache-2.0
  16. PKG_LICENSE_FILES:=LICENSE
  17. PKG_BUILD_PARALLEL:=1
  18. include $(INCLUDE_DIR)/nls.mk
  19. include $(INCLUDE_DIR)/package.mk
  20. include $(INCLUDE_DIR)/cmake.mk
  21. define Package/libxerces-c/Default
  22. SECTION:=libs
  23. CATEGORY:=Libraries
  24. TITLE:=Validating XML parser library for C++
  25. URL:=https://xerces.apache.org/
  26. endef
  27. define Package/libxerces-c
  28. $(call Package/libxerces-c/Default)
  29. DEPENDS:=$(ICONV_DEPENDS) +libstdcpp
  30. endef
  31. define Package/libxerces-c-samples
  32. $(call Package/libxerces-c/Default)
  33. TITLE+= (samples)
  34. DEPENDS+=+libxerces-c
  35. endef
  36. define Package/libxerces-c/description
  37. Xerces-C++ is a validating XML parser written in a portable subset of
  38. C++. Xerces-C++ makes it easy to give your application the ability
  39. to read and write XML data. A shared library is provided for parsing,
  40. generating, manipulating, and validating XML documents. Xerces-C++ is
  41. faithful to the XML 1.0 recommendation and associated standards (DOM
  42. 1.0, DOM 2.0, SAX 1.0, SAX 2.0, Namespaces, XML Schema Part 1 and
  43. Part 2). It also provides experimental implementations of XML 1.1
  44. and DOM Level 3.0. The parser provides high performance, modularity,
  45. and scalability.
  46. endef
  47. define Package/libxerces-c-samples/description
  48. Validating XML parser library for C++ (samples)
  49. endef
  50. CMAKE_OPTIONS += \
  51. -DCMAKE_DISABLE_FIND_PACKAGE_ICU=ON \
  52. -Dmessage-loader=inmemory \
  53. -Dnetwork-accessor=socket \
  54. -Dtranscoder=iconv
  55. define Build/InstallDev
  56. $(INSTALL_DIR) $(1)/usr/include/xercesc
  57. $(CP) $(PKG_INSTALL_DIR)/usr/include/xercesc/* $(1)/usr/include/xercesc/
  58. $(INSTALL_DIR) $(1)/usr/lib
  59. $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so $(1)/usr/lib/
  60. $(INSTALL_DIR) $(1)/usr/lib/cmake/XercesC
  61. $(CP) $(PKG_INSTALL_DIR)/usr/lib/cmake/XercesC/* $(1)/usr/lib/cmake/XercesC
  62. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  63. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/xerces-c.pc $(1)/usr/lib/pkgconfig/xerces-c.pc
  64. $(SED) 's,/usr/include,$$$${prefix}/include,g' $(1)/usr/lib/pkgconfig/xerces-c.pc
  65. $(SED) 's,/usr/lib,$$$${exec_prefix}/lib,g' $(1)/usr/lib/pkgconfig/xerces-c.pc
  66. endef
  67. define Package/libxerces-c/install
  68. $(INSTALL_DIR) $(1)/usr/lib
  69. $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so $(1)/usr/lib/
  70. endef
  71. define Package/libxerces-c-samples/install
  72. $(INSTALL_DIR) $(1)/usr/bin
  73. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
  74. endef
  75. $(eval $(call BuildPackage,libxerces-c))
  76. $(eval $(call BuildPackage,libxerces-c-samples))