3 # This is free software, licensed under the GNU General Public License v3.
4 # See /LICENSE for more information.
5 include $(TOPDIR
)/rules.mk
7 PKG_NAME
:=openwisp-config
11 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
13 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.xz
14 PKG_SOURCE_URL
:=https
://github.com
/openwisp
/openwisp-config.git
15 PKG_SOURCE_VERSION
:=0.4.5
16 PKG_SOURCE_SUBDIR
:=$(PKG_NAME
)-$(PKG_SOURCE_VERSION
)
17 PKG_MIRROR_HASH
:=017a8ed35ebfda2805426e7da02559d5cc2845ee9ded60fdae8e848d377424fb
21 include $(INCLUDE_DIR
)/package.mk
23 define Package
/openwisp-config
/default
24 TITLE
:=Remote configuration management agent
($(2) variant
)
25 CATEGORY
:=Administration
28 DEPENDS
:=+curl
+lua
+libuci-lua
+luafilesystem
$(3)
30 MAINTAINER
:=Federico Capoano
<f.capoano@cineca.it
>
31 URL
:=http
://openwisp.org
34 Package
/openwisp-config-openssl
=$(call Package
/openwisp-config
/default
,openssl
,OpenSSL
,+ca-certificates
+libopenssl
)
35 Package
/openwisp-config-mbedtls
=$(call Package
/openwisp-config
/default
,mbedtls
,mbedTLS
,+ca-certificates
+libmbedtls
)
36 Package
/openwisp-config-cyassl
=$(call Package
/openwisp-config
/default
,cyassl
,CyaSSL
,+ca-certificates
+libcyassl
)
37 Package
/openwisp-config-nossl
=$(call Package
/openwisp-config
/default
,nossl
,No SSL
)
42 define Package
/openwisp-config-
$(BUILD_VARIANT
)/conffiles
46 ifeq ($(BUILD_VARIANT
),openssl
)
47 CONFIG_OPENWISP_UCI
:=ssl
49 ifeq ($(BUILD_VARIANT
),mbedtls
)
50 CONFIG_OPENWISP_UCI
:=ssl
52 ifeq ($(BUILD_VARIANT
),cyassl
)
53 CONFIG_OPENWISP_UCI
:=ssl
55 ifeq ($(BUILD_VARIANT
),nossl
)
56 CONFIG_OPENWISP_UCI
:=nossl
60 define Package
/openwisp-config-
$(BUILD_VARIANT
)/install
66 $(1)/usr
/lib
/lua
/openwisp
69 $(PKG_BUILD_DIR
)/openwisp-config
/files
/openwisp.agent \
70 $(1)/usr
/sbin
/openwisp_config
73 $(PKG_BUILD_DIR
)/openwisp-config
/files
/openwisp.init \
74 $(1)/etc
/init.d
/openwisp_config
76 $(INSTALL_CONF
) $(PKG_BUILD_DIR
)/openwisp-config
/files
/openwisp-
$(CONFIG_OPENWISP_UCI
).config \
77 $(1)/etc
/config
/openwisp
80 $(PKG_BUILD_DIR
)/openwisp-config
/files
/sbin
/openwisp-reload-config \
81 $(1)/usr
/sbin
/openwisp-reload-config
84 $(PKG_BUILD_DIR
)/openwisp-config
/files
/lib
/openwisp
/utils.lua \
85 $(1)/usr
/lib
/lua
/openwisp
/utils.lua
88 $(PKG_BUILD_DIR
)/openwisp-config
/files
/sbin
/openwisp-store-unmanaged.lua \
89 $(1)/usr
/sbin
/openwisp-store-unmanaged
92 $(PKG_BUILD_DIR
)/openwisp-config
/files
/sbin
/openwisp-restore-unmanaged.lua \
93 $(1)/usr
/sbin
/openwisp-restore-unmanaged
96 $(PKG_BUILD_DIR
)/openwisp-config
/files
/sbin
/openwisp-remove-default-wifi.lua \
97 $(1)/usr
/sbin
/openwisp-remove-default-wifi
100 $(PKG_BUILD_DIR
)/openwisp-config
/files
/sbin
/openwisp-uci-autoname.lua \
101 $(1)/usr
/sbin
/openwisp-uci-autoname
104 $(PKG_BUILD_DIR
)/openwisp-config
/files
/sbin
/openwisp-update-config.lua \
105 $(1)/usr
/sbin
/openwisp-update-config
107 $(CP
) $(PKG_BUILD_DIR
)/VERSION
$(1)/etc
/openwisp
/
110 $(eval
$(call BuildPackage
,openwisp-config-openssl
))
111 $(eval
$(call BuildPackage
,openwisp-config-mbedtls
))
112 $(eval
$(call BuildPackage
,openwisp-config-cyassl
))
113 $(eval
$(call BuildPackage
,openwisp-config-nossl
))