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.

57 lines
1.7 KiB

  1. include $(TOPDIR)/rules.mk
  2. PKG_NAME:=overture
  3. PKG_VERSION:=1.7
  4. PKG_RELEASE:=1
  5. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  6. PKG_SOURCE_URL:=https://codeload.github.com/shawn1m/overture/tar.gz/v${PKG_VERSION}?
  7. PKG_HASH:=d3912fe53d2f6a60d20767a8dc5041333f8b5386b7d23d959b4de872d12b5024
  8. PKG_MAINTAINER:=Richard Yu <yurichard3839@gmail.com>
  9. PKG_LICENSE:=MIT
  10. PKG_LICENSE_FILES:=LICENSE
  11. PKG_BUILD_DEPENDS:=golang/host
  12. PKG_BUILD_PARALLEL:=1
  13. PKG_USE_MIPS16:=0
  14. GO_PKG:=github.com/shawn1m/overture
  15. GO_PKG_BUILD_PKG:=$(GO_PKG)/main
  16. GO_PKG_LDFLAGS_X:=main.version=$(PKG_VERSION)
  17. include $(INCLUDE_DIR)/package.mk
  18. include ../../lang/golang/golang-package.mk
  19. define Package/overture
  20. SECTION:=net
  21. CATEGORY:=Network
  22. SUBMENU:=IP Addresses and Names
  23. TITLE:=A customized DNS forwarder written in Go
  24. URL:=https://github.com/shawn1m/overture
  25. DEPENDS:=$(GO_ARCH_DEPENDS)
  26. endef
  27. define Package/overture/description
  28. Overture is a DNS server/forwarder/dispatcher written in Go.
  29. endef
  30. define Package/overture/conffiles
  31. /etc/overture/
  32. endef
  33. define Package/overture/install
  34. $(call GoPackage/Package/Install/Bin,$(PKG_INSTALL_DIR))
  35. $(INSTALL_DIR) $(1)/usr/bin
  36. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/main $(1)/usr/bin/overture
  37. $(INSTALL_DIR) $(1)/etc/overture
  38. $(INSTALL_DATA) $(PKG_BUILD_DIR)/config.sample.yml $(1)/etc/overture/config.yml
  39. $(SED) 's@\.\(/[^[:space:]]\{1,\}_sample\)@/etc/overture\1@g;s/^\(bindAddress:[[:space:]]\{0,\}\)[^[:space:]]\{0,\}$$$$/\1127.0.0.3:53/' $(1)/etc/overture/config.yml
  40. $(INSTALL_DATA) ./files/*_sample $(1)/etc/overture
  41. $(INSTALL_DIR) $(1)/etc/init.d
  42. $(INSTALL_BIN) ./files/overture.init $(1)/etc/init.d/overture
  43. endef
  44. $(eval $(call GoBinPackage,overture))
  45. $(eval $(call BuildPackage,overture))