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.

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