1
0

Makefile 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. #
  2. # This is free software, licensed under the GNU General Public License v2.
  3. # See /LICENSE for more information.
  4. #
  5. include $(TOPDIR)/rules.mk
  6. PKG_NAME:=expat
  7. PKG_VERSION:=2.2.7
  8. PKG_RELEASE:=1
  9. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  10. PKG_SOURCE_URL:=@SF/expat
  11. PKG_HASH:=30e3f40acf9a8fdbd5c379bdcc8d1178a1d9af306de29fc8ece922bc4c57bef8
  12. PKG_MAINTAINER:=Ted Hess <thess@kitschensync.net>
  13. PKG_LICENSE:=MIT
  14. PKG_LICENSE_FILES:=COPYING
  15. PKG_CPE_ID:=cpe:/a:libexpat:expat
  16. PKG_FIXUP:=autoreconf
  17. PKG_INSTALL:=1
  18. PKG_BUILD_PARALLEL:=1
  19. include $(INCLUDE_DIR)/host-build.mk
  20. include $(INCLUDE_DIR)/package.mk
  21. define Package/libexpat
  22. SECTION:=libs
  23. CATEGORY:=Libraries
  24. TITLE:=An XML parsing library
  25. URL:=https://libexpat.github.io/
  26. endef
  27. define Package/libexpat/description
  28. A fast, non-validating, stream-oriented XML parsing library.
  29. endef
  30. TARGET_CFLAGS += $(FPIC)
  31. CONFIGURE_ARGS += \
  32. --enable-shared \
  33. --enable-static \
  34. --without-docbook
  35. HOST_CONFIGURE_ARGS += \
  36. --without-docbook
  37. define Host/Install
  38. $(MAKE) -C $(HOST_BUILD_DIR) install
  39. endef
  40. define Build/InstallDev
  41. $(INSTALL_DIR) $(1)/usr/include
  42. $(CP) $(PKG_INSTALL_DIR)/usr/include/expat{,_external}.h $(1)/usr/include/
  43. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  44. $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/expat.pc $(1)/usr/lib/pkgconfig/
  45. $(INSTALL_DIR) $(1)/usr/lib
  46. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libexpat.{a,so*} $(1)/usr/lib/
  47. endef
  48. define Package/libexpat/install
  49. $(INSTALL_DIR) $(1)/usr/lib
  50. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libexpat.so.* $(1)/usr/lib/
  51. endef
  52. $(eval $(call HostBuild))
  53. $(eval $(call BuildPackage,libexpat))