[packages/zabbix] level up zabbix to version 2.0.0
git-svn-id: svn://svn.openwrt.org/openwrt/packages@32497 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
3bed00f5b9
commit
81938508b5
@ -1,5 +1,5 @@
|
|||||||
#
|
#
|
||||||
# Copyright (C) 2006-2011 OpenWrt.org
|
# Copyright (C) 2006-2012 OpenWrt.org
|
||||||
#
|
#
|
||||||
# This is free software, licensed under the GNU General Public License v2.
|
# This is free software, licensed under the GNU General Public License v2.
|
||||||
# See /LICENSE for more information.
|
# See /LICENSE for more information.
|
||||||
@ -8,17 +8,19 @@
|
|||||||
include $(TOPDIR)/rules.mk
|
include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=zabbix
|
PKG_NAME:=zabbix
|
||||||
PKG_VERSION:=1.6
|
PKG_VERSION:=2.0.0
|
||||||
PKG_RELEASE:=3
|
PKG_RELEASE:=1
|
||||||
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||||
PKG_SOURCE_URL:=@SF/zabbix
|
PKG_SOURCE_URL:=@SF/zabbix
|
||||||
PKG_MD5SUM:=39d4c871439b1b4f0429964b4abbfc45
|
PKG_MD5SUM:=d34d398beddee0eaa999789100cf74e3
|
||||||
|
|
||||||
PKG_BUILD_DEPENDS:=libsqlite3
|
|
||||||
PKG_INSTALL:=1
|
PKG_INSTALL:=1
|
||||||
|
|
||||||
|
PKG_FIXUP:=autoreconf
|
||||||
|
|
||||||
include $(INCLUDE_DIR)/package.mk
|
include $(INCLUDE_DIR)/package.mk
|
||||||
|
include $(INCLUDE_DIR)/nls.mk
|
||||||
|
|
||||||
define Package/zabbix/Default
|
define Package/zabbix/Default
|
||||||
SECTION:=admin
|
SECTION:=admin
|
||||||
@ -26,7 +28,7 @@ define Package/zabbix/Default
|
|||||||
TITLE:=Zabbix
|
TITLE:=Zabbix
|
||||||
URL:=http://www.zabbix.com/
|
URL:=http://www.zabbix.com/
|
||||||
SUBMENU:=zabbix
|
SUBMENU:=zabbix
|
||||||
DEPENDS:=+libcurl
|
MAINTAINER:=Mirko Vogt <mirko@openwrt.org>
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/zabbix-agent
|
define Package/zabbix-agent
|
||||||
@ -34,64 +36,114 @@ define Package/zabbix-agent
|
|||||||
TITLE+= agent
|
TITLE+= agent
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
define Package/zabbix-agentd
|
||||||
|
$(call Package/zabbix/Default)
|
||||||
|
TITLE+= agentd
|
||||||
|
endef
|
||||||
|
|
||||||
define Package/zabbix-sender
|
define Package/zabbix-sender
|
||||||
$(call Package/zabbix/Default)
|
$(call Package/zabbix/Default)
|
||||||
TITLE+= sender
|
TITLE+= sender
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
define Package/zabbix-get
|
||||||
|
$(call Package/zabbix/Default)
|
||||||
|
TITLE+= get
|
||||||
|
endef
|
||||||
|
|
||||||
define Package/zabbix-server
|
define Package/zabbix-server
|
||||||
$(call Package/zabbix/Default)
|
$(call Package/zabbix/Default)
|
||||||
TITLE+= server
|
TITLE+= server
|
||||||
DEPENDS += +libsqlite3
|
DEPENDS += +libsqlite3
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
define Package/zabbix-proxy
|
||||||
ifneq ($(SDK),)
|
$(call Package/zabbix/Default)
|
||||||
CONFIG_PACKAGE_zabbix-server:=m
|
TITLE+= proxy
|
||||||
endif
|
DEPENDS += +libsqlite3
|
||||||
|
endef
|
||||||
|
|
||||||
CONFIGURE_ARGS+= \
|
CONFIGURE_ARGS+= \
|
||||||
--bindir="/usr/sbin" \
|
--enable-agent \
|
||||||
--enable-agent
|
|
||||||
|
|
||||||
ifneq ($(CONFIG_PACKAGE_zabbix-server),)
|
|
||||||
CONFIGURE_ARGS+= \
|
|
||||||
--enable-server \
|
--enable-server \
|
||||||
|
--enable-proxy \
|
||||||
|
--disable-java \
|
||||||
--with-sqlite3="$(STAGING_DIR)/usr"
|
--with-sqlite3="$(STAGING_DIR)/usr"
|
||||||
endif
|
|
||||||
|
|
||||||
MAKE_FLAGS += ARCH="linux"
|
MAKE_FLAGS += ARCH="linux"
|
||||||
|
|
||||||
define Package/zabbix-agent/conffiles
|
define Package/zabbix/install/sbin
|
||||||
/etc/zabbix/zabbix_agentd.conf
|
$(INSTALL_DIR) \
|
||||||
|
$(1)/usr/sbin
|
||||||
|
|
||||||
|
$(INSTALL_BIN) \
|
||||||
|
$(PKG_INSTALL_DIR)/usr/sbin/zabbix_$(2) \
|
||||||
|
$(1)/usr/sbin/
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/zabbix/install/bin
|
||||||
|
$(INSTALL_DIR) \
|
||||||
|
$(1)/usr/bin
|
||||||
|
|
||||||
|
$(INSTALL_BIN) \
|
||||||
|
$(PKG_INSTALL_DIR)/usr/bin/zabbix_$(2) \
|
||||||
|
$(1)/usr/bin/
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/zabbix/install/etc
|
||||||
|
$(INSTALL_DIR) \
|
||||||
|
$(1)/etc
|
||||||
|
|
||||||
|
$(INSTALL_CONF) \
|
||||||
|
$(PKG_INSTALL_DIR)/etc/zabbix_$(2).conf \
|
||||||
|
$(1)/etc/
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/zabbix/install/init.d
|
||||||
|
$(INSTALL_DIR) \
|
||||||
|
$(1)/etc/init.d
|
||||||
|
|
||||||
|
$(INSTALL_BIN) \
|
||||||
|
./files/zabbix_$(2).init \
|
||||||
|
$(1)/etc/init.d/zabbix_$(2)
|
||||||
|
endef
|
||||||
|
|
||||||
|
define Package/zabbix-$(1)/conffiles
|
||||||
|
/etc/zabbix/zabbix_$(1).conf
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/zabbix-agent/install
|
define Package/zabbix-agent/install
|
||||||
$(INSTALL_DIR) $(1)/usr/sbin
|
$(call Package/zabbix/install/sbin,$(1),agent)
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/zabbix_agentd $(1)/usr/sbin/
|
$(call Package/zabbix/install/etc,$(1),agent)
|
||||||
$(INSTALL_DIR) $(1)/etc/zabbix
|
endef
|
||||||
$(INSTALL_CONF) ./files/zabbix_agentd.conf $(1)/etc/zabbix/
|
|
||||||
$(INSTALL_DIR) $(1)/etc/init.d
|
define Package/zabbix-agentd/install
|
||||||
$(INSTALL_BIN) ./files/zabbix_agentd.init $(1)/etc/init.d/zabbix_agentd
|
$(call Package/zabbix/install/sbin,$(1),agentd)
|
||||||
|
$(call Package/zabbix/install/etc,$(1),agentd)
|
||||||
|
$(call Package/zabbix/install/init.d,$(1),agentd)
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/zabbix-sender/install
|
define Package/zabbix-sender/install
|
||||||
$(INSTALL_DIR) $(1)/usr/sbin
|
$(call Package/zabbix/install/bin,$(1),sender)
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/zabbix_sender $(1)/usr/sbin/
|
|
||||||
$(INSTALL_DIR) $(1)/etc/zabbix
|
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/zabbix-server/conffiles
|
define Package/zabbix-get/install
|
||||||
/etc/zabbix/zabbix_server.conf
|
$(call Package/zabbix/install/bin,$(1),get)
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/zabbix-server/install
|
define Package/zabbix-server/install
|
||||||
$(INSTALL_DIR) $(1)/usr/sbin
|
$(call Package/zabbix/install/sbin,$(1),server)
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/zabbix_server $(1)/usr/sbin/
|
$(call Package/zabbix/install/etc,$(1),server)
|
||||||
$(INSTALL_DIR) $(1)/etc/zabbix
|
endef
|
||||||
$(INSTALL_CONF) $(PKG_BUILD_DIR)/misc/conf/zabbix_server.conf $(1)/etc/zabbix/
|
|
||||||
|
define Package/zabbix-proxy/install
|
||||||
|
$(call Package/zabbix/install/sbin,$(1),proxy)
|
||||||
|
$(call Package/zabbix/install/etc,$(1),proxy)
|
||||||
endef
|
endef
|
||||||
|
|
||||||
$(eval $(call BuildPackage,zabbix-agent))
|
$(eval $(call BuildPackage,zabbix-agent))
|
||||||
|
$(eval $(call BuildPackage,zabbix-agentd))
|
||||||
$(eval $(call BuildPackage,zabbix-sender))
|
$(eval $(call BuildPackage,zabbix-sender))
|
||||||
$(eval $(call BuildPackage,zabbix-server))
|
$(eval $(call BuildPackage,zabbix-server))
|
||||||
|
$(eval $(call BuildPackage,zabbix-proxy))
|
||||||
|
$(eval $(call BuildPackage,zabbix-get))
|
||||||
|
@ -1,13 +1,29 @@
|
|||||||
diff -urN zabbix-1.6/configure zabbix-1.6.new/configure
|
--- a/configure.in 2012-06-21 21:32:23.707912790 +0000
|
||||||
--- zabbix-1.6/configure 2008-09-18 22:15:39.000000000 +0200
|
+++ b/configure.in 2012-06-21 21:33:36.213554564 +0000
|
||||||
+++ zabbix-1.6.new/configure 2008-09-30 19:20:43.000000000 +0200
|
@@ -806,25 +806,8 @@
|
||||||
@@ -4826,8 +4826,7 @@
|
|
||||||
{ { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
|
|
||||||
See \`config.log' for more details." >&5
|
|
||||||
echo "$as_me: error: cannot run test program while cross compiling
|
|
||||||
-See \`config.log' for more details." >&2;}
|
|
||||||
- { (exit 1); exit 1; }; }
|
|
||||||
+See \`config.log' for more details." >&2;} }
|
|
||||||
else
|
|
||||||
cat >conftest.$ac_ext <<_ACEOF
|
|
||||||
|
|
||||||
|
dnl Check for %qu format (FreeBSD 4.x)
|
||||||
|
dnl FreeBSD 4.x does not support %llu
|
||||||
|
-AC_MSG_CHECKING(for long long format)
|
||||||
|
-AC_TRY_RUN(
|
||||||
|
-[
|
||||||
|
-#include <sys/types.h>
|
||||||
|
-int main()
|
||||||
|
-{
|
||||||
|
- uint64_t i;
|
||||||
|
-
|
||||||
|
- sscanf("200000000010020", "%qu", &i);
|
||||||
|
-
|
||||||
|
- if (i == 200000000010020) return 0;
|
||||||
|
- else return -1;
|
||||||
|
-}
|
||||||
|
-],
|
||||||
|
-AC_DEFINE(HAVE_LONG_LONG_QU, 1 ,[Define to 1 if format '%qu' exists.])
|
||||||
|
-AC_MSG_RESULT(yes),
|
||||||
|
-AC_MSG_RESULT(no))
|
||||||
|
-
|
||||||
|
dnl option -rdynamic is needed for readable backtraces
|
||||||
|
+
|
||||||
|
AC_MSG_CHECKING(for -rdynamic linking option)
|
||||||
|
saved_LDFLAGS="$LDFLAGS"
|
||||||
|
LDFLAGS="-rdynamic $LDFLAGS"
|
||||||
|
35
admin/zabbix/patches/002-fix-res_send-on-uclibc.patch
Normal file
35
admin/zabbix/patches/002-fix-res_send-on-uclibc.patch
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
--- a/configure.in 2012-05-21 14:07:37.000000000 +0000
|
||||||
|
+++ b/configure.in 2012-06-21 19:46:34.843662509 +0000
|
||||||
|
@@ -149,6 +149,10 @@
|
||||||
|
AC_MSG_ERROR([Unable to DNS lookup functions "${found_resolv}"])
|
||||||
|
fi
|
||||||
|
LIBS="${LIBS} ${RESOLV_LIBS}"
|
||||||
|
+AC_SEARCH_LIBS([res_mkquery], [], [AC_DEFINE([HAVE_RES_MKQUERY], 1, [Define if res_mkquery exists])])
|
||||||
|
+AC_SEARCH_LIBS([__res_mkquery], [], [AC_DEFINE([HAVE_RES_MKQUERY], 1, [Define if res_mkquery exists])])
|
||||||
|
+AC_SEARCH_LIBS([res_send], [], [AC_DEFINE([HAVE_RES_SEND], 1, [Define if res_send exists])])
|
||||||
|
+AC_SEARCH_LIBS([__res_send], [], [AC_DEFINE([HAVE_RES_SEND], 1, [Define if res_send exists])])
|
||||||
|
|
||||||
|
dnl *****************************************************************
|
||||||
|
dnl * *
|
||||||
|
--- a/src/libs/zbxsysinfo/common/net.c 2012-06-21 19:49:46.610567432 +0000
|
||||||
|
+++ b/src/libs/zbxsysinfo/common/net.c 2012-06-21 19:50:35.816628541 +0000
|
||||||
|
@@ -418,6 +418,7 @@
|
||||||
|
#else /* not _WINDOWS */
|
||||||
|
res_init(); /* initialize always, settings might have changed */
|
||||||
|
|
||||||
|
+#if defined(HAVE_RES_MKQUERY) && defined(HAVE_RES_SEND)
|
||||||
|
if (-1 == (res = res_mkquery(QUERY, zone, C_IN, type, NULL, 0, NULL, buf, sizeof(buf))))
|
||||||
|
return SYSINFO_RET_FAIL;
|
||||||
|
|
||||||
|
@@ -436,6 +437,11 @@
|
||||||
|
_res.retry = retry;
|
||||||
|
|
||||||
|
res = res_send(buf, res, answer.buffer, sizeof(answer.buffer));
|
||||||
|
+#else /* defined(HAVE_RES_QUERY) && defined(HAVE_RES_SEND) */
|
||||||
|
+ /* retrand and retry are ignored */
|
||||||
|
+ if (-1 == (res = res_query(zone, C_IN, type, answer.buffer, sizeof(answer.buffer))))
|
||||||
|
+ return SYSINFO_RET_FAIL;
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
hp = (HEADER *)answer.buffer;
|
||||||
|
|
Loading…
x
Reference in New Issue
Block a user