2 # Copyright (C) 2006-2015 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
14 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
15 PKG_SOURCE_URL
:=@SF
/zabbix
16 PKG_MD5SUM
:=890d9eec69304ad552959fabe0a5d122
19 PKG_LICENSE_FILES
:=COPYING
25 include $(INCLUDE_DIR
)/package.mk
26 include $(INCLUDE_DIR
)/nls.mk
28 define Package
/zabbix
/Default
30 CATEGORY
:=Administration
32 URL
:=http
://www.zabbix.com
/
34 MAINTAINER
:=Etienne CHAMPETIER
<champetier.etienne@gmail.com
>
35 USERID
:=zabbix
=53:zabbix
=53
36 DEPENDS
+= $(ICONV_DEPENDS
)
39 define Package
/zabbix-agentd
40 $(call Package
/zabbix
/Default
)
44 define Package
/zabbix-extra-mac80211
45 $(call Package
/zabbix
/Default
)
46 TITLE
+= discovery
/userparameters for mac80211
47 DEPENDS
= +zabbix-agentd @PACKAGE_MAC80211_DEBUGFS @KERNEL_DEBUG_FS
50 define Package
/zabbix-extra-network
51 $(call Package
/zabbix
/Default
)
52 TITLE
+= discovery
/userparameters for network
53 DEPENDS
= +zabbix-agentd
+libuci-lua
+lua
56 define Package
/zabbix-extra-wifi
57 $(call Package
/zabbix
/Default
)
58 TITLE
+= discovery
/userparameters for wifi
59 DEPENDS
= +zabbix-agentd
+libiwinfo-lua
+libuci-lua
+lua
62 define Package
/zabbix-sender
63 $(call Package
/zabbix
/Default
)
67 define Package
/zabbix-get
68 $(call Package
/zabbix
/Default
)
72 define Package
/zabbix-server
73 $(call Package
/zabbix
/Default
)
75 DEPENDS
+= +libsqlite3
78 define Package
/zabbix-proxy
79 $(call Package
/zabbix
/Default
)
81 DEPENDS
+= +libsqlite3
84 define Package
/zabbix-extra-mac80211
/description
85 An extra package for zabbix-agentd that adds a discovery rule for mac80211 wifi phy and many userparameters.
86 It contains an suid helper to allow zabbix-agentd to still run
as zabbix user and not
as root.
87 See http
://wiki.openwrt.org
/doc
/howto
/zabbix for ready to use zabbix templates.
90 define Package
/zabbix-extra-network
/description
91 An extra package for zabbix-agentd that adds a discovery rule for openwrt network interfaces.
92 The idea here is to discover only interfaces listed in
/etc
/config
/network
(discover br-lan and not eth0.1 and wlan0
)
93 See http
://wiki.openwrt.org
/doc
/howto
/zabbix for ready to use zabbix templates.
96 define Package
/zabbix-extra-wifi
/description
97 An extra package for zabbix-agentd that adds a discovery rule for wifi interfaces and many userparameters.
98 As it uses libiwinfo
, it works with
all wifi devices supported by openwrt.
99 See http
://wiki.openwrt.org
/doc
/howto
/zabbix for ready to use zabbix templates.
106 $(call autoconf_bool
,CONFIG_IPV6
,ipv6
) \
108 --with-sqlite3
="$(STAGING_DIR)/usr"
110 MAKE_FLAGS
+= ARCH
="linux"
112 define Package
/zabbix
/install/sbin
117 $(PKG_INSTALL_DIR
)/usr
/sbin
/zabbix_
$(2) \
121 define Package
/zabbix
/install/bin
126 $(PKG_INSTALL_DIR
)/usr
/bin
/zabbix_
$(2) \
130 define Package
/zabbix
/install/etc
135 $(PKG_INSTALL_DIR
)/etc
/zabbix_
$(2).conf \
139 define Package
/zabbix
/install/init.d
144 .
/files
/zabbix_
$(2).init \
145 $(1)/etc
/init.d
/zabbix_
$(2)
148 define Package
/zabbix
/install/zabbix.conf.d
150 $(1)/etc
/zabbix_agentd.conf.d
154 $(1)/etc
/zabbix_agentd.conf.d
/$(2)
157 define Package
/zabbix-agentd
/conffiles
158 /etc
/zabbix_agentd.conf
160 define Package
/zabbix-server
/conffiles
161 /etc
/zabbix_server.conf
163 define Package
/zabbix-proxy
/conffiles
164 /etc
/zabbix_proxy.conf
167 ifdef CONFIG_PACKAGE_zabbix-extra-mac80211
168 define Build
/Prepare
/zabbix-extra-mac80211
169 mkdir
-p
$(PKG_BUILD_DIR
)/zabbix-extra-mac80211
170 $(CP
) .
/files
/zabbix_helper_mac80211.c
$(PKG_BUILD_DIR
)/zabbix-extra-mac80211
/
173 define Build
/Compile
/zabbix-extra-mac80211
174 $(TARGET_CC
) $(TARGET_CFLAGS
) $(PKG_BUILD_DIR
)/zabbix-extra-mac80211
/zabbix_helper_mac80211.c
-o
$(PKG_BUILD_DIR
)/zabbix-extra-mac80211
/zabbix_helper_mac80211
179 $(call Build
/Prepare
/Default
)
180 $(call Build
/Prepare
/zabbix-extra-mac80211
)
184 $(call Build
/Compile
/Default
)
185 $(call Build
/Compile
/zabbix-extra-mac80211
)
188 define Package
/zabbix-agentd
/install
189 $(INSTALL_DIR
) $(1)/etc
/zabbix_agentd.conf.d
190 $(call Package
/zabbix
/install/sbin
,$(1),agentd
)
191 $(call Package
/zabbix
/install/etc
,$(1),agentd
)
192 $(call Package
/zabbix
/install/init.d
,$(1),agentd
)
195 define Package
/zabbix-extra-mac80211
/install
196 $(call Package
/zabbix
/install/zabbix.conf.d
,$(1),mac80211
)
197 $(INSTALL_DIR
) $(1)/usr
/bin
198 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/zabbix-extra-mac80211
/zabbix_helper_mac80211
$(1)/usr
/bin
/
199 chmod
4755 $(1)/usr
/bin
/zabbix_helper_mac80211
202 define Package
/zabbix-extra-network
/install
203 $(call Package
/zabbix
/install/zabbix.conf.d
,$(1),network
)
206 define Package
/zabbix-extra-wifi
/install
207 $(call Package
/zabbix
/install/zabbix.conf.d
,$(1),wifi
)
210 define Package
/zabbix-sender
/install
211 $(call Package
/zabbix
/install/bin
,$(1),sender
)
214 define Package
/zabbix-get
/install
215 $(call Package
/zabbix
/install/bin
,$(1),get)
218 define Package
/zabbix-server
/install
219 $(call Package
/zabbix
/install/sbin
,$(1),server
)
220 $(call Package
/zabbix
/install/etc
,$(1),server
)
223 define Package
/zabbix-proxy
/install
224 $(call Package
/zabbix
/install/sbin
,$(1),proxy
)
225 $(call Package
/zabbix
/install/etc
,$(1),proxy
)
228 $(eval
$(call BuildPackage
,zabbix-agentd
))
229 $(eval
$(call BuildPackage
,zabbix-extra-mac80211
))
230 $(eval
$(call BuildPackage
,zabbix-extra-network
))
231 $(eval
$(call BuildPackage
,zabbix-extra-wifi
))
232 $(eval
$(call BuildPackage
,zabbix-sender
))
233 $(eval
$(call BuildPackage
,zabbix-server
))
234 $(eval
$(call BuildPackage
,zabbix-proxy
))
235 $(eval
$(call BuildPackage
,zabbix-get
))