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.

63 lines
1.6 KiB

  1. #
  2. # Copyright (C) 2011-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:=rng-tools
  9. PKG_VERSION:=5
  10. PKG_RELEASE:=6
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=@SF/gkernel/rng-tools/$(PKG_VERSION)/
  13. PKG_HASH:=60a102b6603bbcce2da341470cad42eeaa9564a16b4490e7867026ca11a3078e
  14. PKG_LICENSE:=GPLv2
  15. PKG_MAINTAINER:=Nathaniel Wesley Filardo <nwfilardo@gmail.com>
  16. PKG_FIXUP:=autoreconf
  17. PKG_BUILD_DEPENDS:=USE_UCLIBC:argp-standalone USE_MUSL:argp-standalone
  18. include $(INCLUDE_DIR)/package.mk
  19. define Package/rng-tools
  20. SECTION:=utils
  21. CATEGORY:=Utilities
  22. TITLE:=Daemon for adding entropy to kernel entropy pool
  23. URL:=http://sourceforge.net/projects/gkernel/
  24. endef
  25. define Package/rng-tools/description
  26. Daemon for adding entropy to kernel entropy pool. By default it uses
  27. /dev/urandom as the source but the init script can be modified
  28. to use a hardware source like /dev/hwrng if present
  29. endef
  30. ifdef CONFIG_USE_UCLIBC
  31. CONFIGURE_VARS += \
  32. LIBS="-largp"
  33. endif
  34. ifdef CONFIG_USE_MUSL
  35. CONFIGURE_VARS += \
  36. LIBS="-largp"
  37. endif
  38. CONFIGURE_ARGS += \
  39. --without-libgcrypt
  40. define Package/rng-tools/install
  41. $(INSTALL_DIR) $(1)/etc/init.d
  42. $(INSTALL_BIN) ./files/rngd.init $(1)/etc/init.d/rngd
  43. $(INSTALL_DIR) $(1)/etc/uci-defaults
  44. $(INSTALL_BIN) ./files/rngd.uci_defaults $(1)/etc/uci-defaults/rngd
  45. $(INSTALL_DIR) $(1)/usr/bin
  46. $(INSTALL_BIN) $(PKG_BUILD_DIR)/rngtest $(1)/usr/bin/
  47. $(INSTALL_DIR) $(1)/sbin
  48. $(INSTALL_BIN) $(PKG_BUILD_DIR)/rngd $(1)/sbin/
  49. endef
  50. $(eval $(call BuildPackage,rng-tools))