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.

100 lines
2.6 KiB

  1. # openwisp.org
  2. #
  3. # This is free software, licensed under the GNU General Public License v3.
  4. # See /LICENSE for more information.
  5. include $(TOPDIR)/rules.mk
  6. PKG_NAME:=openwisp-config
  7. PKG_RELEASE:=1
  8. PKG_MAINTAINER:=Federico Capoano <f.capoano@openwisp.io>
  9. PKG_LICENSE:=GPL3.0-or-later
  10. PKG_SOURCE_URL:=https://github.com/openwisp/openwisp-config.git
  11. PKG_MIRROR_HASH:=7daa10a9d170e665f33a5555a246b4da2223c2d8d0e8a047edb01701c8886986
  12. PKG_SOURCE_PROTO:=git
  13. PKG_SOURCE_VERSION:=1.0.1
  14. include $(INCLUDE_DIR)/package.mk
  15. define Package/openwisp-config
  16. TITLE:=Remote configuration management agent
  17. CATEGORY:=Administration
  18. SECTION:=admin
  19. SUBMENU:=openwisp
  20. DEPENDS:=+curl \
  21. +lua \
  22. +libuci-lua \
  23. +luafilesystem \
  24. +luci-lib-nixio \
  25. +ca-certificates
  26. PKGARCH:=all
  27. URL:=https://openwisp.org
  28. endef
  29. define Build/Compile
  30. endef
  31. define Package/openwisp-config/conffiles
  32. /etc/config/openwisp
  33. endef
  34. define Package/openwisp-config/install
  35. $(INSTALL_DIR) \
  36. $(1)/usr/sbin \
  37. $(1)/etc/init.d \
  38. $(1)/etc/config \
  39. $(1)/etc/openwisp \
  40. $(1)/usr/lib/lua/openwisp
  41. $(INSTALL_BIN) \
  42. $(PKG_BUILD_DIR)/openwisp-config/files/openwisp.agent \
  43. $(1)/usr/sbin/openwisp_config
  44. $(INSTALL_BIN) \
  45. $(PKG_BUILD_DIR)/openwisp-config/files/openwisp.init \
  46. $(1)/etc/init.d/openwisp_config
  47. $(INSTALL_CONF) $(PKG_BUILD_DIR)/openwisp-config/files/openwisp.config \
  48. $(1)/etc/config/openwisp
  49. $(INSTALL_BIN) \
  50. $(PKG_BUILD_DIR)/openwisp-config/files/sbin/openwisp-reload-config \
  51. $(1)/usr/sbin/openwisp-reload-config
  52. $(INSTALL_BIN) \
  53. $(PKG_BUILD_DIR)/openwisp-config/files/lib/openwisp/utils.lua \
  54. $(1)/usr/lib/lua/openwisp/utils.lua
  55. $(INSTALL_BIN) \
  56. $(PKG_BUILD_DIR)/openwisp-config/files/lib/openwisp/net.lua \
  57. $(1)/usr/lib/lua/openwisp/net.lua
  58. $(INSTALL_BIN) \
  59. $(PKG_BUILD_DIR)/openwisp-config/files/sbin/openwisp-store-unmanaged.lua \
  60. $(1)/usr/sbin/openwisp-store-unmanaged
  61. $(INSTALL_BIN) \
  62. $(PKG_BUILD_DIR)/openwisp-config/files/sbin/openwisp-restore-unmanaged.lua \
  63. $(1)/usr/sbin/openwisp-restore-unmanaged
  64. $(INSTALL_BIN) \
  65. $(PKG_BUILD_DIR)/openwisp-config/files/sbin/openwisp-remove-default-wifi.lua \
  66. $(1)/usr/sbin/openwisp-remove-default-wifi
  67. $(INSTALL_BIN) \
  68. $(PKG_BUILD_DIR)/openwisp-config/files/sbin/openwisp-uci-autoname.lua \
  69. $(1)/usr/sbin/openwisp-uci-autoname
  70. $(INSTALL_BIN) \
  71. $(PKG_BUILD_DIR)/openwisp-config/files/sbin/openwisp-update-config.lua \
  72. $(1)/usr/sbin/openwisp-update-config
  73. $(INSTALL_BIN) \
  74. $(PKG_BUILD_DIR)/openwisp-config/files/sbin/openwisp-get-address.lua \
  75. $(1)/usr/sbin/openwisp-get-address
  76. $(CP) $(PKG_BUILD_DIR)/VERSION $(1)/etc/openwisp/
  77. endef
  78. $(eval $(call BuildPackage,openwisp-config))