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.

69 lines
2.0 KiB

  1. #
  2. # Copyright (C) 2015, 2016 gxcreator
  3. # Copyright (C) 2017 OpenWrt.org
  4. #
  5. # This is free software, licensed under the GNU General Public License v2.
  6. # See /LICENSE for more information.
  7. #
  8. include $(TOPDIR)/rules.mk
  9. PKG_NAME:=i2pd
  10. PKG_VERSION:=2.24.0
  11. PKG_RELEASE:=1
  12. PKG_BUILD_PARALLEL:=1
  13. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  14. PKG_SOURCE_URL:=https://codeload.github.com/PurpleI2P/i2pd/tar.gz/$(PKG_VERSION)?
  15. PKG_HASH:=809b37100f0f176432b01ab6edee96dc62b0f65d5bf7531e008a87117e742566
  16. PKG_MAINTAINER:=David Yang <mmyangfl@gmail.com>
  17. PKG_LICENSE:=BSD-3-Clause
  18. PKG_LICENSE_FILES:=LICENSE
  19. include $(INCLUDE_DIR)/package.mk
  20. define Package/i2pd
  21. SECTION:=net
  22. CATEGORY:=Network
  23. DEPENDS:=+libopenssl +boost +boost-system +boost-filesystem \
  24. +boost-program_options +boost-date_time +libatomic +zlib
  25. TITLE:=full-featured C++ implementation of I2P client
  26. URL:=https://github.com/PurpleI2P/i2pd
  27. USERID:=i2pd:i2pd
  28. endef
  29. define Package/i2pd/description
  30. I2P (Invisible Internet Protocol) is a universal anonymous network layer. All
  31. communications over I2P are anonymous and end-to-end encrypted, participants
  32. don't reveal their real IP addresses.
  33. endef
  34. define Package/i2pd/conffiles
  35. /etc/config/i2pd
  36. /etc/i2pd/i2pd.conf
  37. /etc/i2pd/tunnels.conf
  38. endef
  39. TARGET_LDFLAGS+=-latomic
  40. MAKE_FLAGS+=USE_AESNI=no USE_AVX=no
  41. define Package/i2pd/install
  42. $(INSTALL_DIR) $(1)/usr/sbin
  43. $(INSTALL_BIN) $(PKG_BUILD_DIR)/i2pd $(1)/usr/sbin
  44. $(INSTALL_DIR) $(1)/usr/share/i2pd
  45. $(CP) $(PKG_BUILD_DIR)/contrib/certificates $(1)/usr/share/i2pd
  46. $(INSTALL_DIR) $(1)/etc/config
  47. $(INSTALL_CONF) ./files/i2pd.config $(1)/etc/config/i2pd
  48. $(INSTALL_DIR) $(1)/etc/i2pd
  49. $(INSTALL_CONF) $(PKG_BUILD_DIR)/contrib/i2pd.conf $(1)/etc/i2pd
  50. $(SED) ' \
  51. s/127.0.0.1/192.168.1.1/g; \
  52. s/datadir = \/var\/lib/datadir = \/etc/ \
  53. ' $(1)/etc/i2pd/i2pd.conf
  54. $(INSTALL_CONF) $(PKG_BUILD_DIR)/contrib/tunnels.conf $(1)/etc/i2pd
  55. $(INSTALL_DIR) $(1)/etc/init.d
  56. $(INSTALL_BIN) ./files/i2pd.init $(1)/etc/init.d/i2pd
  57. endef
  58. $(eval $(call BuildPackage,i2pd))