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.

47 lines
1.1 KiB

  1. #
  2. # Copyright (C) 2010-2014 OpenWrt.org
  3. # Copyright (C) 2010 segal.di.ubi.pt
  4. # Copyright (C) 2016 Karol Babioch <karol@babioch.de>
  5. #
  6. # This is free software, licensed under the GNU General Public License v2.
  7. # See /LICENSE for more information.
  8. #
  9. include $(TOPDIR)/rules.mk
  10. PKG_NAME:=wifitoggle
  11. PKG_VERSION:=1
  12. PKG_RELEASE:=5
  13. PKG_LICENSE:=GPL-2.0+
  14. PKG_MAINTAINER:=Nuno Goncalves <nunojpg@gmail.com>
  15. include $(INCLUDE_DIR)/package.mk
  16. define Package/wifitoggle
  17. SECTION:=utils
  18. CATEGORY:=Utilities
  19. TITLE:=Script to toggle Wi-Fi with a button and UCI config
  20. PKGARCH:=all
  21. endef
  22. define Package/wifitoggle/description
  23. Very versatile script to toggle Wi-Fi with a button. Allows to set
  24. timeouts, persist changes after boot, and set LEDs according to the state.
  25. endef
  26. define Package/wifitoggle/conffiles
  27. /etc/config/wifitoggle
  28. endef
  29. define Build/Compile
  30. endef
  31. define Package/wifitoggle/install
  32. $(INSTALL_DIR) $(1)/etc/hotplug.d/button
  33. $(INSTALL_BIN) ./files/wifitoggle.hotplug $(1)/etc/hotplug.d/button/50-wifitoggle
  34. $(INSTALL_DIR) $(1)/etc/config
  35. $(INSTALL_DATA) ./files/wifitoggle.config $(1)/etc/config/wifitoggle
  36. endef
  37. $(eval $(call BuildPackage,wifitoggle))