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.

122 lines
3.9 KiB

  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:=gnupg
  9. PKG_VERSION:=2.2.23
  10. PKG_RELEASE:=1
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
  12. PKG_SOURCE_URL:=https://gnupg.org/ftp/gcrypt/gnupg
  13. PKG_HASH:=10b55e49d78b3e49f1edb58d7541ecbdad92ddaeeb885b6f486ed23d1cd1da5c
  14. PKG_LICENSE:=GPL-3.0-or-later
  15. PKG_LICENSE_FILES:=COPYING COPYING.CC0 COPYING.GPL2 COPYING.LGPL21 COPYING.LGPL3 COPYING.other
  16. PKG_INSTALL:=1
  17. PKG_BUILD_PARALLEL:=1
  18. include $(INCLUDE_DIR)/package.mk
  19. include $(INCLUDE_DIR)/nls.mk
  20. define Package/gnupg2/Default
  21. SECTION:=utils
  22. CATEGORY:=Utilities
  23. SUBMENU:=Encryption
  24. DEPENDS:=+libgpg-error +libnpth +libassuan +libksba +libgcrypt +zlib +libncurses +libreadline $(ICONV_DEPENDS) $(INTL_DEPENDS)
  25. TITLE:=GNU privacy guard (version 2) - a free PGP replacement
  26. URL:=http://www.gnupg.org/
  27. endef
  28. define Package/gnupg2
  29. $(call Package/gnupg2/Default)
  30. MENU:=1
  31. ALTERNATIVES:=300:/usr/bin/gpg:/usr/bin/gpg2
  32. endef
  33. define Package/gpgv2
  34. $(call Package/gnupg2/Default)
  35. TITLE:=GnuPG signature verification only (version 2)
  36. ALTERNATIVES:=300:/usr/bin/gpgv:/usr/bin/gpgv2
  37. endef
  38. define Package/gnupg2-utils
  39. $(call Package/gnupg2/Default)
  40. DEPENDS:=gnupg2 +libcurl
  41. TITLE:=Key management utilities for GnuPG (version 2)
  42. endef
  43. define Package/gnupg2/description
  44. GnuPG is a complete and free implementation of the OpenPGP standard as
  45. defined by RFC4880 (also known as PGP). GnuPG allows you to encrypt and
  46. sign your data and communications; it features a versatile key
  47. management system, along with access modules for all kinds of public
  48. key directories. GnuPG, also known as GPG, is a command line tool with
  49. features for easy integration with other applications. A wealth of
  50. frontend applications and libraries are available. GnuPG also provides
  51. support for S/MIME and Secure Shell (ssh).
  52. endef
  53. define Package/gpgv2/description
  54. GPGv is a stripped down version of GnuPG that only checks signatures.
  55. endef
  56. define Package/gnupg2-utils/description
  57. Key management utilies for GnuPG (version 2).
  58. This package is needed to import keys from a keyserver.
  59. endef
  60. CONFIGURE_ARGS += \
  61. --with-gpg-error-prefix="$(STAGING_DIR)/usr/" \
  62. --with-libgcrypt-prefix="$(STAGING_DIR)/usr/" \
  63. --with-libassuan-prefix="$(STAGING_DIR)/usr/" \
  64. --with-ksba-prefix="$(STAGING_DIR)/usr/" \
  65. --with-npth-prefix="$(STAGING_DIR)/usr/" \
  66. --disable-bzip2 \
  67. --disable-card-support \
  68. --disable-ccid-driver \
  69. --disable-dirmngr \
  70. --disable-gnutls \
  71. --disable-ldap \
  72. --disable-ntbtls \
  73. --disable-rpath \
  74. --disable-sqlite \
  75. --disable-tests \
  76. --disable-zip
  77. TARGET_CFLAGS += $(if $(CONFIG_GCC_USE_VERSION_10),-DEXTERN_UNLESS_MAIN_MODULE=static)
  78. define Package/gnupg2/install
  79. $(INSTALL_DIR) $(1)/usr/bin
  80. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpg $(1)/usr/bin/gpg2
  81. endef
  82. define Package/gpgv2/install
  83. $(INSTALL_DIR) $(1)/usr/bin
  84. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpgv $(1)/usr/bin/gpgv2
  85. endef
  86. define Package/gnupg2-utils/install
  87. $(INSTALL_DIR) $(1)/usr/bin $(1)/usr/sbin
  88. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpgtar $(1)/usr/bin
  89. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/kbxutil $(1)/usr/bin
  90. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpg-wks-server $(1)/usr/bin
  91. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpg-agent $(1)/usr/bin
  92. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpg-connect-agent $(1)/usr/bin
  93. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpgsplit $(1)/usr/bin
  94. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpgparsemail $(1)/usr/bin
  95. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gpgsm $(1)/usr/bin
  96. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/addgnupghome $(1)/usr/sbin
  97. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/applygnupgdefaults $(1)/usr/sbin
  98. $(INSTALL_DIR) $(1)/usr/lib
  99. $(CP) $(PKG_INSTALL_DIR)/usr/lib/gpg-* $(1)/usr/lib
  100. endef
  101. $(eval $(call BuildPackage,gnupg2))
  102. $(eval $(call BuildPackage,gpgv2))
  103. $(eval $(call BuildPackage,gnupg2-utils))