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.

79 lines
1.9 KiB

  1. #
  2. # Copyright (C) 2006-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:=cryptsetup
  9. PKG_VERSION:=1.7.2
  10. PKG_RELEASE:=1
  11. PKG_LICENSE:=GPL-2.0+ LGPL-2.1+
  12. PKG_LICENSE_FILES:=COPYING COPYING.LGPL
  13. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  14. PKG_SOURCE_URL:=@KERNEL/linux/utils/cryptsetup/v1.7
  15. PKG_MD5SUM:=a11a140cea496961222170944db01fc1
  16. PKG_MAINTAINER:=Daniel Golle <daniel@makrotopia.org>
  17. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
  18. include $(INCLUDE_DIR)/package.mk
  19. TARGET_LDFLAGS+=-Wl,-rpath-link=$(STAGING_DIR)/usr/lib
  20. define Package/cryptsetup/Default
  21. SECTION:=utils
  22. CATEGORY:=Utilities
  23. SUBMENU:=Encryption
  24. TITLE:=Cryptsetup
  25. DEPENDS:=+libblkid +libuuid +libpopt +lvm2 +libdevmapper +@KERNEL_DIRECT_IO
  26. URL:=http://code.google.com/p/cryptsetup/
  27. endef
  28. define Package/cryptsetup
  29. $(call Package/cryptsetup/Default)
  30. DEPENDS+=+libgcrypt
  31. VARIANT:=gcrypt
  32. endef
  33. define Package/cryptsetup-openssl
  34. $(call Package/cryptsetup/Default)
  35. TITLE+= (with openssl support)
  36. DEPENDS+=+libopenssl
  37. VARIANT:=openssl
  38. endef
  39. define Package/cryptsetup/Default/description
  40. Cryptsetup-luks
  41. endef
  42. define Package/cryptsetup/description
  43. $(call Package/cryptsetup/Default/description)
  44. linked against libgcrypt
  45. endef
  46. define Package/cryptsetup-openssl/description
  47. $(call Package/cryptsetup/Default/description)
  48. linked against openssl
  49. endef
  50. ifeq ($(BUILD_VARIANT),openssl)
  51. CONFIGURE_ARGS+= \
  52. --with-crypto_backend=openssl
  53. endif
  54. define Package/cryptsetup/install
  55. $(INSTALL_DIR) $(1)/usr/sbin
  56. $(CP) $(PKG_BUILD_DIR)/src/.libs/cryptsetup $(1)/usr/sbin
  57. $(INSTALL_DIR) $(1)/usr/lib
  58. $(CP) $(PKG_BUILD_DIR)/lib/.libs/libcryptsetup.so* $(1)/usr/lib
  59. endef
  60. Package/cryptsetup-openssl/install = $(Package/cryptsetup/install)
  61. $(eval $(call BuildPackage,cryptsetup))
  62. $(eval $(call BuildPackage,cryptsetup-openssl))