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.

86 lines
2.2 KiB

  1. include $(TOPDIR)/rules.mk
  2. PKG_NAME:=dnsdist
  3. PKG_VERSION:=1.3.3
  4. PKG_RELEASE:=3
  5. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
  6. PKG_SOURCE_URL:=https://downloads.powerdns.com/releases/
  7. PKG_HASH:=9fb24f9032025955169f3c6e9b0a05b6aa9d6441ec47da08d22de1c1aa23e8cf
  8. PKG_MAINTAINER:=James Taylor <james@jtaylor.id.au>
  9. PKG_LICENSE:=GPL-2.0-only
  10. PKG_LICENSE_FILES:=COPYING
  11. PKG_INSTALL:=1
  12. PKG_CONFIG_DEPENDS:= \
  13. CONFIG_DNSDIST_GNUTLS \
  14. CONFIG_DNSDIST_OPENSSL
  15. include $(INCLUDE_DIR)/package.mk
  16. define Package/dnsdist/config
  17. comment "SSL support"
  18. choice
  19. prompt "Selected SSL library"
  20. default DNSDIST_OPENSSSL
  21. config DNSDIST_OPENSSL
  22. bool "OpenSSL"
  23. config DNSDIST_GNUTLS
  24. bool "GnuTLS"
  25. config DNSDIST_NOSSL
  26. bool "No SSL support"
  27. endchoice
  28. endef
  29. define Package/dnsdist
  30. SECTION:=net
  31. CATEGORY:=Network
  32. SUBMENU:=IP Addresses and Names
  33. TITLE:=dnsdist DNS-, DOS- and abuse-aware loadbalancer
  34. DEPENDS:=+DNSDIST_OPENSSL:libopenssl +DNSDIST_GNUTLS:libgnutls +protobuf +re2 +libedit +libfstrm +libsodium +lua +boost +libnetsnmp +libatomic
  35. URL:=https://dnsdist.org/
  36. endef
  37. define Package/dnsdist/description
  38. dnsdist is a highly DNS-, DoS- and abuse-aware loadbalancer. Its goal in life
  39. is to route traffic to the best server, delivering top performance to legitimate
  40. users while shunting or blocking abusive traffic.
  41. endef
  42. define Package/dnsdist/conffiles
  43. /etc/dnsdist.conf
  44. /etc/config/dnsdist
  45. /etc/init.d/dnsdist
  46. endef
  47. CONFIGURE_ARGS+= \
  48. --enable-dnscrypt \
  49. $(if $(CONFIG_DNSDIST_NOSSL),,--enable-dns-over-tls) \
  50. --enable-fstrm \
  51. --enable-libsodium \
  52. --enable-protobuf \
  53. --enable-re2 \
  54. --with-lua=lua \
  55. --with-net-snmp \
  56. $(if $(CONFIG_DNSDIST_GNUTLS),--enable,--disable)-gnutls \
  57. $(if $(CONFIG_DNSDIST_OPENSSL),--enable,--disable)-libssl
  58. define Package/dnsdist/install
  59. $(INSTALL_DIR) $(1)/etc
  60. $(INSTALL_CONF) ./files/dnsdist.conf $(1)/etc/dnsdist.conf
  61. $(INSTALL_DIR) $(1)/etc/config
  62. $(INSTALL_CONF) ./files/dnsdist.config $(1)/etc/config/dnsdist
  63. $(INSTALL_DIR) $(1)/etc/init.d
  64. $(INSTALL_BIN) ./files/dnsdist.init $(1)/etc/init.d/dnsdist
  65. $(INSTALL_DIR) $(1)/usr/bin
  66. $(INSTALL_BIN) $(PKG_BUILD_DIR)/dnsdist $(1)/usr/bin/
  67. endef
  68. $(eval $(call BuildPackage,dnsdist))