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.

97 lines
2.3 KiB

  1. #
  2. # Copyright (C) 2009-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:=libidn
  9. PKG_VERSION:=1.33
  10. PKG_RELEASE:=2
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=@GNU/libidn
  13. PKG_MD5SUM:=a9aa7e003665de9c82bd3f9fc6ccf308
  14. PKG_LICENSE:=GPL-2.0+ GPL-3.0+ LGPL-2.1+ LGPL-3.0+ Apache-2.0
  15. PKG_LICENSE_FILES:=COPYING COPYINGv2 COPYINGv3 COPYING.LESSERv2 COPYING.LESSERv3 java/LICENSE-2.0.txt
  16. PKG_FIXUP:=autoreconf
  17. PKG_REMOVE_FILES:=GNUmakefile aclocal.m4
  18. PKG_INSTALL:=1
  19. include $(INCLUDE_DIR)/package.mk
  20. define Package/idn/Default
  21. SECTION:=net
  22. CATEGORY:=Network
  23. URL:=http://www.gnu.org/software/libidn/
  24. MAINTAINER:=Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
  25. endef
  26. define Package/idn/Default/description
  27. GNU Libidn is a fully documented implementation of the Stringprep,
  28. Punycode and IDNA specifications. Libidn's purpose is to encode and
  29. decode internationalized domain names.
  30. endef
  31. define Package/idn
  32. $(call Package/idn/Default)
  33. SUBMENU:=IP Addresses and Names
  34. TITLE:=GNU IDN (Internationalized Domain Name) tool
  35. DEPENDS:=+libidn
  36. endef
  37. define Package/idn/description
  38. $(call Package/idn/Default/description)
  39. Command line tool using libidn
  40. endef
  41. define Package/libidn
  42. $(call Package/idn/Default)
  43. SECTION:=libs
  44. CATEGORY:=Libraries
  45. TITLE:=Stringprep, Punycode and IDNA implementation
  46. endef
  47. define Package/libidn/description
  48. $(call Package/idn/Default/description)
  49. Library only package
  50. endef
  51. TARGET_CFLAGS += $(FPIC)
  52. CONFIGURE_ARGS += \
  53. --enable-shared \
  54. --enable-static \
  55. MAKE_FLAGS += \
  56. CC="$(TARGET_CC)" \
  57. define Build/InstallDev
  58. $(INSTALL_DIR) $(1)/usr/include
  59. $(CP) $(PKG_INSTALL_DIR)/usr/include/*.h $(1)/usr/include/
  60. $(INSTALL_DIR) $(1)/usr/lib
  61. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libidn.{a,so*} $(1)/usr/lib/
  62. $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
  63. $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libidn.pc $(1)/usr/lib/pkgconfig/
  64. endef
  65. define Package/idn/install
  66. $(INSTALL_DIR) $(1)/usr/bin
  67. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
  68. endef
  69. define Package/libidn/install
  70. $(INSTALL_DIR) $(1)/usr/lib
  71. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libidn.so* $(1)/usr/lib/
  72. endef
  73. $(eval $(call BuildPackage,idn))
  74. $(eval $(call BuildPackage,libidn))