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.

93 lines
2.4 KiB

  1. #
  2. # Copyright (C) 2017-2018 Daniel Engberg <daniel.engberg.lists@pyret.net>
  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:=libidn2
  9. PKG_VERSION:=2.0.4
  10. PKG_RELEASE:=1
  11. PKG_MAINTAINER:=Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
  12. PKG_LICENSE:=GPL-2.0-or-later LGPL-3.0-or-later
  13. PKG_LICENSE_FILES:=COPYING COPYINGv2 COPYING.LESSERv3
  14. PKG_SOURCE_URL:=@GNU/libidn
  15. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  16. PKG_HASH:=644b6b03b285fb0ace02d241d59483d98bc462729d8bb3608d5cad5532f3d2f0
  17. PKG_INSTALL:=1
  18. include $(INCLUDE_DIR)/package.mk
  19. include $(INCLUDE_DIR)/nls.mk
  20. define Package/idn2/Default
  21. SECTION:=net
  22. CATEGORY:=Network
  23. URL:=http://www.gnu.org/software/libidn/
  24. endef
  25. define Package/idn2/Default/description
  26. Libidn2 is a free software implementation of IDNA2008,
  27. Punycode and TR46 in library form. It contains
  28. functionality to convert internationalized domain
  29. names to and from ASCII Compatible Encoding (ACE),
  30. following the IDNA2008 and TR46 standards.
  31. endef
  32. define Package/idn2
  33. $(call Package/idn2/Default)
  34. SUBMENU:=IP Addresses and Names
  35. TITLE:=GNU IDN2 (Internationalized Domain Name) tool
  36. DEPENDS:=+libidn2
  37. endef
  38. define Package/idn2/description
  39. $(call Package/idn2/Default/description)
  40. Command line tool using libidn2
  41. endef
  42. define Package/libidn2
  43. SECTION:=libs
  44. CATEGORY:=Libraries
  45. DEPENDS:=+libunistring $(ICONV_DEPENDS) $(INTL_DEPENDS)
  46. TITLE:=International domain name library (IDNA2008, Punycode and TR46)
  47. URL:=https://www.gnu.org/software/libidn/#libidn2
  48. endef
  49. define Package/libidn2/description
  50. $(call Package/idn2/Default/description)
  51. Library only package
  52. endef
  53. CONFIGURE_ARGS += \
  54. --disable-rpath \
  55. --disable-doc
  56. define Build/InstallDev
  57. $(INSTALL_DIR) $(1)/usr/include
  58. $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/idn2.h $(1)/usr/include
  59. $(INSTALL_DIR) $(1)/usr/lib
  60. $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.{la,so}* $(1)/usr/lib/
  61. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  62. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libidn2.pc $(1)/usr/lib/pkgconfig/
  63. endef
  64. define Package/idn2/install
  65. $(INSTALL_DIR) $(1)/usr/bin
  66. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
  67. endef
  68. define Package/libidn2/install
  69. $(INSTALL_DIR) $(1)/usr/lib/
  70. $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/
  71. endef
  72. $(eval $(call BuildPackage,idn2))
  73. $(eval $(call BuildPackage,libidn2))