1
0

Makefile 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. #
  2. # Copyright (C) 2006-2017 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:=unzip
  9. PKG_REV:=60
  10. PKG_VERSION:=6.0
  11. PKG_RELEASE:=5
  12. PKG_SOURCE:=$(PKG_NAME)$(PKG_REV).tar.gz
  13. PKG_SOURCE_URL:=@SF/infozip
  14. PKG_MD5SUM:=62b490407489521db863b523a7f86375
  15. PKG_MAINTAINER:=Álvaro Fernández Rojas <noltari@gmail.com>
  16. PKG_LICENSE:=BSD-4-Clause
  17. PKG_LICENSE_FILES:=LICENSE
  18. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)/unzip$(PKG_REV)
  19. PKG_CHECK_FORMAT_SECURITY:=0
  20. include $(INCLUDE_DIR)/package.mk
  21. define Package/unzip
  22. SECTION:=utils
  23. CATEGORY:=Utilities
  24. DEPENDS:=
  25. TITLE:=De-archiver for .zip files
  26. URL:=http://infozip.sourceforge.net/UnZip.html
  27. SUBMENU:=Compression
  28. endef
  29. define Package/unzip/description
  30. InfoZIP's unzip program. With the exception of multi-volume archives
  31. (ie, .ZIP files that are split across several disks using PKZIP's /& option),
  32. this can handle any file produced either by PKZIP, or the corresponding
  33. InfoZIP zip program.
  34. endef
  35. define Build/Configure
  36. endef
  37. TARGET_CFLAGS += \
  38. -DNO_LCHMOD \
  39. -DLARGE_FILE_SUPPORT \
  40. -DUNICODE_WCHAR \
  41. -DUNICODE_SUPPORT \
  42. -DUTF8_MAYBE_NATIVE \
  43. -DZIP64_SUPPORT
  44. define Build/Compile
  45. $(MAKE) -C $(PKG_BUILD_DIR) -f unix/Makefile unzips \
  46. $(TARGET_CONFIGURE_OPTS) \
  47. prefix="$(PKG_INSTALL_DIR)/usr" \
  48. CFLAGS="$(TARGET_CFLAGS)" \
  49. CF="$(TARGET_CFLAGS) -O $(TARGET_CPPFLAGS) -I. -DUNIX" \
  50. CC="$(TARGET_CC)" \
  51. LD="$(TARGET_CC) $(TARGET_LDFLAGS)" \
  52. install
  53. endef
  54. define Package/unzip/install
  55. $(INSTALL_DIR) $(1)/usr/bin/
  56. $(INSTALL_BIN) \
  57. $(PKG_INSTALL_DIR)/usr/bin/{funzip,unzip,unzipsfx,zipgrep} \
  58. $(1)/usr/bin/
  59. $(LN) unzip $(1)/usr/bin/zipinfo
  60. endef
  61. $(eval $(call BuildPackage,unzip))