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.

77 lines
1.8 KiB

  1. #
  2. # Copyright (C) 2014 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:=libarchive
  9. PKG_VERSION:=3.1.2
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=http://www.libarchive.org/downloads
  13. PKG_MD5SUM:=efad5a503f66329bb9d2f4308b5de98a
  14. PKG_MAINTAINER:=Johannes Morgenroth <morgenroth@ibr.cs.tu-bs.de>
  15. PKG_LICENSE:=BSD-2-Clause
  16. PKG_INSTALL:=1
  17. PKG_FIXUP:=autoreconf
  18. include $(INCLUDE_DIR)/package.mk
  19. define Package/$(PKG_NAME)/Default
  20. SECTION:=libs
  21. CATEGORY:=Libraries
  22. DEPENDS:=+zlib
  23. TITLE:=Multi-format archive and compression library
  24. URL:=http://www.libarchive.org/
  25. endef
  26. define Package/$(PKG_NAME)
  27. $(call Package/$(PKG_NAME)/Default)
  28. DEPENDS += +libopenssl
  29. endef
  30. define Package/$(PKG_NAME)-noopenssl
  31. $(call Package/$(PKG_NAME)/Default)
  32. TITLE += (without OpenSSL dependency)
  33. VARIANT:=noopenssl
  34. endef
  35. CONFIGURE_ARGS += \
  36. --disable-bsdcpio \
  37. --disable-bsdtar \
  38. --disable-acl \
  39. --disable-xattr \
  40. --without-bz2lib \
  41. --without-lzma \
  42. --without-lzmadec \
  43. --without-lzo2 \
  44. --without-nettle \
  45. --without-expat \
  46. --without-xml2
  47. ifeq ($(BUILD_VARIANT),noopenssl)
  48. CONFIGURE_ARGS += --without-openssl
  49. else
  50. CONFIGURE_ARGS += --with-openssl
  51. endif
  52. define Build/InstallDev
  53. $(INSTALL_DIR) $(1)/usr/include
  54. $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
  55. $(INSTALL_DIR) $(1)/usr/lib
  56. $(CP) $(PKG_INSTALL_DIR)/usr/lib/* $(1)/usr/lib/
  57. endef
  58. define Package/libarchive/install
  59. $(INSTALL_DIR) $(1)/usr/lib
  60. $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so.* $(1)/usr/lib/
  61. endef
  62. Package/$(PKG_NAME)-noopenssl/install = $(Package/$(PKG_NAME)/install)
  63. $(eval $(call BuildPackage,libarchive))
  64. $(eval $(call BuildPackage,libarchive-noopenssl))