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
2.2 KiB

  1. #
  2. # Copyright (C) 2018 Dengfeng Liu
  3. #
  4. # This is free software, licensed under the GNU General Public License v3.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=apfree-wifidog
  9. PKG_VERSION:=3.11.1716
  10. PKG_RELEASE=1
  11. PKG_LICENSE:=GPL-3.0-or-later
  12. PKG_LICENSE_FILES:=COPYING
  13. PKG_MAINTAINER:=Dengfeng Liu <liudf0716@gmail.com>
  14. PKG_SOURCE_PROTO:=git
  15. PKG_SOURCE_URL:=https://github.com/liudf0716/apfree_wifidog.git
  16. PKG_SOURCE_VERSION:=$(PKG_VERSION)
  17. PKG_MIRROR_HASH:=76eda57e40b919091281305344bc57fc732a779d7944f57bd5de87914ba127d1
  18. include $(INCLUDE_DIR)/package.mk
  19. include $(INCLUDE_DIR)/cmake.mk
  20. define Package/apfree-wifidog
  21. SUBMENU:=Captive Portals
  22. SECTION:=net
  23. CATEGORY:=Network
  24. DEPENDS:=+zlib +iptables-mod-extra +iptables-mod-ipopt +kmod-ipt-nat +iptables-mod-nat-extra \
  25. +libjson-c +ipset +libip4tc +libevent2 +libevent2-openssl +libuci +px5g
  26. TITLE:=Apfree's wireless captive portal solution
  27. URL:=https://github.com/liudf0716/apfree_wifidog
  28. endef
  29. define Package/apfree-wifidog/description
  30. The ApFree Wifidog project is a complete and embeddable captive portal
  31. solution for wireless community groups or individuals who wish to open a free
  32. Hotspot while still preventing abuse of their Internet connection.
  33. It's enhanced wifidog
  34. endef
  35. define Package/apfree-wifidog/install
  36. $(INSTALL_DIR) $(1)/usr/bin
  37. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/wifidogx $(1)/usr/bin/wifidogx
  38. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/wdctlx $(1)/usr/bin/wdctlx
  39. $(INSTALL_DIR) $(1)/usr/sbin
  40. $(INSTALL_BIN) ./files/wdping $(1)/usr/sbin/
  41. $(INSTALL_DIR) $(1)/etc
  42. $(INSTALL_DATA) $(PKG_BUILD_DIR)/wifidog-msg.html $(1)/etc/
  43. $(INSTALL_DATA) $(PKG_BUILD_DIR)/wifidog-redir.html $(1)/etc/
  44. $(INSTALL_DATA) $(PKG_BUILD_DIR)/wifidog-redir.html.front $(1)/etc/
  45. $(INSTALL_DATA) $(PKG_BUILD_DIR)/wifidog-redir.html.rear $(1)/etc/
  46. $(INSTALL_DATA) $(PKG_BUILD_DIR)/authserver-offline.html $(1)/etc/
  47. $(INSTALL_DATA) $(PKG_BUILD_DIR)/internet-offline.html $(1)/etc/
  48. $(INSTALL_DIR) $(1)/etc/init.d
  49. $(INSTALL_BIN) ./files/wifidogx.init $(1)/etc/init.d/wifidogx
  50. $(INSTALL_DIR) $(1)/etc/config
  51. $(CP) ./files/wifidogx.conf $(1)/etc/config/wifidogx
  52. endef
  53. $(eval $(call BuildPackage,apfree-wifidog))