Makefile 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. #
  2. # Copyright (C) 2006-2015 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:=libiconv-full
  9. PKG_VERSION:=1.18
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=libiconv-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=@GNU/libiconv
  13. PKG_HASH:=3b08f5f4f9b4eb82f151a7040bfd6fe6c6fb922efe4b1659c66ea933276965e8
  14. PKG_BUILD_DIR:=$(BUILD_DIR)/libiconv-$(PKG_VERSION)
  15. HOST_BUILD_DIR:=$(BUILD_DIR_HOST)/libiconv-$(PKG_VERSION)
  16. PKG_MAINTAINER:=Jo-Philipp Wich <[email protected]>
  17. PKG_LICENSE:=LGPL-2.1-or-later
  18. PKG_LICENSE_FILES:=COPYING.LIB
  19. PKG_INSTALL:=1
  20. PKG_BUILD_PARALLEL:=1
  21. include $(INCLUDE_DIR)/package.mk
  22. include $(INCLUDE_DIR)/host-build.mk
  23. define Package/libiconv-full/Default
  24. URL:=https://www.gnu.org/software/libiconv/
  25. TITLE:=Character set conversion
  26. endef
  27. define Package/libiconv-full
  28. $(call Package/libiconv-full/Default)
  29. SECTION:=libs
  30. CATEGORY:=Libraries
  31. TITLE+= library
  32. ABI_VERSION:=2
  33. endef
  34. define Package/libcharset
  35. $(call Package/libiconv-full/Default)
  36. SECTION:=libs
  37. CATEGORY:=Libraries
  38. TITLE+= library
  39. ABI_VERSION:=1
  40. endef
  41. define Package/iconv
  42. $(call Package/libiconv-full/Default)
  43. DEPENDS:=+libiconv-full +libcharset
  44. SECTION:=utils
  45. CATEGORY:=Utilities
  46. TITLE+= utility
  47. endef
  48. CONFIGURE_ARGS += \
  49. --enable-shared \
  50. --enable-static \
  51. --disable-rpath \
  52. --enable-relocatable
  53. HOST_CONFIGURE_ARGS += \
  54. --disable-shared \
  55. --with-pic
  56. define Build/InstallDev
  57. $(INSTALL_DIR) $(1)/usr/lib/libiconv-full/include
  58. $(CP) $(PKG_INSTALL_DIR)/usr/include/iconv.h $(1)/usr/lib/libiconv-full/include/
  59. $(INSTALL_DIR) $(1)/usr/lib/libiconv-full/lib
  60. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libcharset.{a,so*} $(1)/usr/lib/libiconv-full/lib/
  61. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libiconv.{a,so*} $(1)/usr/lib/libiconv-full/lib/
  62. endef
  63. define Package/libcharset/install
  64. $(INSTALL_DIR) $(1)/usr/lib
  65. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libcharset.so.* $(1)/usr/lib/
  66. endef
  67. define Package/libiconv-full/install
  68. $(INSTALL_DIR) $(1)/usr/lib
  69. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libiconv.so.* $(1)/usr/lib/
  70. endef
  71. define Package/iconv/install
  72. $(INSTALL_DIR) $(1)/usr/bin
  73. $(CP) $(PKG_INSTALL_DIR)/usr/bin/iconv $(1)/usr/bin/
  74. endef
  75. $(eval $(call BuildPackage,libcharset))
  76. $(eval $(call BuildPackage,libiconv-full))
  77. $(eval $(call BuildPackage,iconv))
  78. $(eval $(call HostBuild))