summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--net-analyzer/nagios-check_varnish/Manifest1
-rw-r--r--net-analyzer/nagios-check_varnish/files/1.1-Attempt-at-fixing-4.1-compat.patch96
-rw-r--r--net-analyzer/nagios-check_varnish/files/1.1-Improve-help-output-to-differentiate-between-v3-and-.patch41
-rw-r--r--net-analyzer/nagios-check_varnish/files/1.1-Make-gcc-explicitly-link-libm.-Fix-10.patch21
-rw-r--r--net-analyzer/nagios-check_varnish/files/1.1-add-support-for-varnish-4.patch130
-rw-r--r--net-analyzer/nagios-check_varnish/metadata.xml8
-rw-r--r--net-analyzer/nagios-check_varnish/nagios-check_varnish-1.1.ebuild37
-rw-r--r--net-analyzer/ndoutils/Manifest2
8 files changed, 1 insertions, 335 deletions
diff --git a/net-analyzer/nagios-check_varnish/Manifest b/net-analyzer/nagios-check_varnish/Manifest
deleted file mode 100644
index fcb11634..00000000
--- a/net-analyzer/nagios-check_varnish/Manifest
+++ /dev/null
@@ -1 +0,0 @@
-DIST varnish-nagios-1.1.tar.gz 297915 SHA256 5a517b490edeb1a1362e53d0320eda42fb2360ee0261e6277b1df7c2c819871d WHIRLPOOL 68c6989bf31e58dc245320ae75774ce2bdd4804d7e2e13549d2d998ff5146d00fda9de7ef6034d27a1b7942cb16c8796a385d9ec7b0fe2e64f39da4b946c8964
diff --git a/net-analyzer/nagios-check_varnish/files/1.1-Attempt-at-fixing-4.1-compat.patch b/net-analyzer/nagios-check_varnish/files/1.1-Attempt-at-fixing-4.1-compat.patch
deleted file mode 100644
index 16469d4c..00000000
--- a/net-analyzer/nagios-check_varnish/files/1.1-Attempt-at-fixing-4.1-compat.patch
+++ /dev/null
@@ -1,96 +0,0 @@
-From 63505e40df567ec3623986051fe7146f63ac04e0 Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Denis=20Br=C3=A6khus?= <denis@varnish-software.com>
-Date: Thu, 10 Dec 2015 11:15:15 +0100
-Subject: [PATCH] Attempt at fixing 4.1 compat
-
----
- check_varnish.c | 22 +++++++++++++++++-----
- configure.ac | 14 +++++++++-----
- 2 files changed, 26 insertions(+), 10 deletions(-)
-
-diff --git a/check_varnish.c b/check_varnish.c
-index 6125ae6..773a7bb 100644
---- a/check_varnish.c
-+++ b/check_varnish.c
-@@ -43,7 +43,7 @@
- #include <locale.h>
- #include <assert.h>
-
--#if defined(HAVE_VARNISHAPI_4)
-+#if defined(HAVE_VARNISHAPI_4) || defined(HAVE_VARNISHAPI_4_1)
- #include <vapi/vsc.h>
- #include <vapi/vsm.h>
- #elif defined(HAVE_VARNISHAPI_3)
-@@ -185,7 +185,19 @@ check_stats_cb(void *priv, const struct VSC_point * const pt)
- if (pt == NULL)
- return(0);
-
--#if defined(HAVE_VARNISHAPI_4)
-+#if defined(HAVE_VARNISHAPI_4_1)
-+ assert(sizeof(tmp) > (strlen(pt->section->fantom->type) + 1 +
-+ strlen(pt->section->fantom->ident) + 1 +
-+ strlen(pt->desc->name) + 1));
-+ snprintf(tmp, sizeof(tmp), "%s%s%s%s%s",
-+ (pt->section->fantom->type[0] == 0 ? "" : pt->section->fantom->type),
-+ (pt->section->fantom->type[0] == 0 ? "" : "."),
-+ (pt->section->fantom->ident[0] == 0 ? "" : pt->section->fantom->ident),
-+ (pt->section->fantom->ident[0] == 0 ? "" : "."),
-+ pt->desc->name);
-+ p = priv;
-+ assert(!strcmp(pt->desc->ctype, "uint64_t"));
-+#elif defined(HAVE_VARNISHAPI_4)
- assert(sizeof(tmp) > (strlen(pt->section->fantom->type) + 1 +
- strlen(pt->section->fantom->ident) + 1 +
- strlen(pt->desc->name) + 1));
-@@ -212,7 +224,7 @@ check_stats_cb(void *priv, const struct VSC_point * const pt)
- #endif
- if (strcmp(tmp, p->param) == 0) {
- p->found = 1;
--#if defined(HAVE_VARNISHAPI_4)
-+#if defined(HAVE_VARNISHAPI_4) || defined(HAVE_VARNISHAPI_4_1)
- p->info = pt->desc->sdesc;
- #elif defined(HAVE_VARNISHAPI_3)
- p->info = pt->desc;
-@@ -241,7 +253,7 @@ check_stats(struct VSM_data *vd, char *param)
- priv.found = 0;
- priv.param = param;
-
--#if defined(HAVE_VARNISHAPI_4)
-+#if defined(HAVE_VARNISHAPI_4) || defined(HAVE_VARNISHAPI_4_1)
- (void)VSC_Iter(vd, NULL, check_stats_cb, &priv);
- #elif defined(HAVE_VARNISHAPI_3)
- (void)VSC_Iter(vd, check_stats_cb, &priv);
-@@ -351,7 +363,7 @@ main(int argc, char **argv)
- }
- }
-
--#if defined(HAVE_VARNISHAPI_4)
-+#if defined(HAVE_VARNISHAPI_4) || defined(HAVE_VARNISHAPI_4_1)
- if (VSM_Open(vd))
- exit(1);
- #elif defined(HAVE_VARNISHAPI_3)
-diff --git a/configure.ac b/configure.ac
-index a3df21e..f7b0258 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -21,11 +21,15 @@ AC_PROG_LIBTOOL
- AC_PROG_MAKE_SET
-
- # Checks for libraries.
--PKG_CHECK_MODULES([VARNISHAPI], [varnishapi >= 4],
-- [AC_DEFINE([HAVE_VARNISHAPI_4], [1], [Use VARNISHAPI v4])],
-- [PKG_CHECK_MODULES([VARNISHAPI], [varnishapi >= 3],
-- [AC_DEFINE([HAVE_VARNISHAPI_3], [1], [Use VARNISHAPI v3])],
-- [AC_MSG_ERROR([Could not find neither varnishapi v4 nor v3.])])
-+PKG_CHECK_MODULES([VARNISHAPI], [varnishapi >= 4.1],
-+ [AC_DEFINE([HAVE_VARNISHAPI_4_1], [1], [Use VARNISHAPI v4.1])],
-+ [PKG_CHECK_MODULES([VARNISHAPI], [varnishapi >= 4],
-+ [AC_DEFINE([HAVE_VARNISHAPI_4], [1], [Use VARNISHAPI v4])],
-+ [PKG_CHECK_MODULES([VARNISHAPI], [varnishapi >= 3],
-+ [AC_DEFINE([HAVE_VARNISHAPI_3], [1], [Use VARNISHAPI v3])],
-+ [AC_MSG_ERROR([Could not find neither varnishapi v4 nor v3.])])
-+ ]
-+ )
- ]
- )
-
diff --git a/net-analyzer/nagios-check_varnish/files/1.1-Improve-help-output-to-differentiate-between-v3-and-.patch b/net-analyzer/nagios-check_varnish/files/1.1-Improve-help-output-to-differentiate-between-v3-and-.patch
deleted file mode 100644
index 2d5ba8d5..00000000
--- a/net-analyzer/nagios-check_varnish/files/1.1-Improve-help-output-to-differentiate-between-v3-and-.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 6600ae018dc6d5169b1ebbeb06f0f8b027566abb Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Denis=20Br=C3=A6khus?= <denis@varnish-software.com>
-Date: Wed, 8 Jul 2015 15:41:40 +0200
-Subject: [PATCH] Improve help output to differentiate between v3 and v4.
-
----
- check_varnish.c | 20 ++++++++++++++------
- 1 file changed, 14 insertions(+), 6 deletions(-)
-
-diff --git a/check_varnish.c b/check_varnish.c
-index 95156f3..6125ae6 100644
---- a/check_varnish.c
-+++ b/check_varnish.c
-@@ -279,13 +279,21 @@ help(void)
- "-w [@][lo:]hi Set warning threshold\n"
- "\n"
- "All items reported by varnishstat(1) are available - use the\n"
-- "identifier listed in the left column by 'varnishstat -l'. In\n"
-- "addition, the following parameters are available:\n"
-+ "identifier listed in the left column by 'varnishstat -l'.\n"
- "\n"
-- "uptime How long the cache has been running (in seconds)\n"
-- "ratio The cache hit ratio expressed as a percentage of hits to\n"
-- " hits + misses. Default thresholds are 95 and 90.\n"
-- "usage Cache file usage as a percentage of the total cache space.\n"
-+ "Examples for Varnish 3.x:\n"
-+ "\n"
-+ "uptime How long the cache has been running (in seconds)\n"
-+ "ratio The cache hit ratio expressed as a percentage of hits to\n"
-+ " hits + misses. Default thresholds are 95 and 90.\n"
-+ "usage Cache file usage as a percentage of the total cache space.\n"
-+ "\n"
-+ "Examples for Varnish 4.x:\n"
-+ "\n"
-+ "ratio The cache hit ratio expressed as a percentage of hits to\n"
-+ " hits + misses. Default thresholds are 95 and 90.\n"
-+ "MAIN.uptime How long the cache has been running (in seconds).\n"
-+ "MAIN.n_purges Number of purge operations executed.\n"
- );
- exit(0);
- }
diff --git a/net-analyzer/nagios-check_varnish/files/1.1-Make-gcc-explicitly-link-libm.-Fix-10.patch b/net-analyzer/nagios-check_varnish/files/1.1-Make-gcc-explicitly-link-libm.-Fix-10.patch
deleted file mode 100644
index 2d4149e7..00000000
--- a/net-analyzer/nagios-check_varnish/files/1.1-Make-gcc-explicitly-link-libm.-Fix-10.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-From 258c48615c632ad15d6f421072ae30b2128963ab Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Denis=20Br=C3=A6khus?= <denis@varnish-software.com>
-Date: Mon, 14 Dec 2015 14:24:22 +0100
-Subject: [PATCH] Make gcc explicitly link libm. Fix #10
-
----
- configure.ac | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/configure.ac b/configure.ac
-index f7b0258..c7946c2 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -43,6 +43,7 @@ AC_C_CONST
-
- # Checks for library functions.
- AC_TYPE_SIZE_T
-+AC_SEARCH_LIBS([pow],[m],[],[AC_MSG_ERROR([unable to find libm])])
-
- # Now that we're done using the compiler to look for functions and
- # libraries, set CFLAGS to what we want them to be for our own code
diff --git a/net-analyzer/nagios-check_varnish/files/1.1-add-support-for-varnish-4.patch b/net-analyzer/nagios-check_varnish/files/1.1-add-support-for-varnish-4.patch
deleted file mode 100644
index d9d342a1..00000000
--- a/net-analyzer/nagios-check_varnish/files/1.1-add-support-for-varnish-4.patch
+++ /dev/null
@@ -1,130 +0,0 @@
-From 04555fb05cb5292b811f696cacd585435f6a9f3e Mon Sep 17 00:00:00 2001
-From: Evgeni Golov <evgeni.golov@credativ.de>
-Date: Sat, 26 Apr 2014 18:06:26 +0200
-Subject: [PATCH] add support for varnish 4
-
-closes #2
----
- check_varnish.c | 41 +++++++++++++++++++++++++++++++++++++++--
- configure.ac | 8 +++++++-
- 2 files changed, 46 insertions(+), 3 deletions(-)
-
-diff --git a/check_varnish.c b/check_varnish.c
-index 2ba36aa..95156f3 100644
---- a/check_varnish.c
-+++ b/check_varnish.c
-@@ -43,8 +43,13 @@
- #include <locale.h>
- #include <assert.h>
-
-+#if defined(HAVE_VARNISHAPI_4)
-+#include <vapi/vsc.h>
-+#include <vapi/vsm.h>
-+#elif defined(HAVE_VARNISHAPI_3)
- #include "vsc.h"
- #include "varnishapi.h"
-+#endif
-
- static int verbose = 0;
-
-@@ -177,6 +182,22 @@ check_stats_cb(void *priv, const struct VSC_point * const pt)
- struct stat_priv *p;
- char tmp[1024];
-
-+ if (pt == NULL)
-+ return(0);
-+
-+#if defined(HAVE_VARNISHAPI_4)
-+ assert(sizeof(tmp) > (strlen(pt->section->fantom->type) + 1 +
-+ strlen(pt->section->fantom->ident) + 1 +
-+ strlen(pt->desc->name) + 1));
-+ snprintf(tmp, sizeof(tmp), "%s%s%s%s%s",
-+ (pt->section->fantom->type[0] == 0 ? "" : pt->section->fantom->type),
-+ (pt->section->fantom->type[0] == 0 ? "" : "."),
-+ (pt->section->fantom->ident[0] == 0 ? "" : pt->section->fantom->ident),
-+ (pt->section->fantom->ident[0] == 0 ? "" : "."),
-+ pt->desc->name);
-+ p = priv;
-+ assert(!strcmp(pt->desc->fmt, "uint64_t"));
-+#elif defined(HAVE_VARNISHAPI_3)
- assert(sizeof(tmp) > (strlen(pt->class) + 1 +
- strlen(pt->ident) + 1 +
- strlen(pt->name) + 1));
-@@ -188,15 +209,20 @@ check_stats_cb(void *priv, const struct VSC_point * const pt)
- pt->name);
- p = priv;
- assert(!strcmp(pt->fmt, "uint64_t"));
-+#endif
- if (strcmp(tmp, p->param) == 0) {
- p->found = 1;
-+#if defined(HAVE_VARNISHAPI_4)
-+ p->info = pt->desc->sdesc;
-+#elif defined(HAVE_VARNISHAPI_3)
- p->info = pt->desc;
-+#endif
- p->value = *(const volatile uint64_t*)pt->ptr;
- } else if (strcmp(p->param, "ratio") == 0) {
-- if (strcmp(tmp, "cache_hit") == 0) {
-+ if (strcmp(tmp, "cache_hit") == 0 || strcmp(tmp, "MAIN.cache_hit") == 0) {
- p->found = 1;
- p->cache_hit = *(const volatile uint64_t*)pt->ptr;
-- } else if (strcmp(tmp, "cache_miss") == 0) {
-+ } else if (strcmp(tmp, "cache_miss") == 0 || strcmp(tmp, "MAIN.cache_miss") == 0) {
- p->cache_miss = *(const volatile uint64_t*)pt->ptr;
- }
- }
-@@ -215,7 +241,11 @@ check_stats(struct VSM_data *vd, char *param)
- priv.found = 0;
- priv.param = param;
-
-+#if defined(HAVE_VARNISHAPI_4)
-+ (void)VSC_Iter(vd, NULL, check_stats_cb, &priv);
-+#elif defined(HAVE_VARNISHAPI_3)
- (void)VSC_Iter(vd, check_stats_cb, &priv);
-+#endif
- if (strcmp(param, "ratio") == 0) {
- intmax_t total = priv.cache_hit + priv.cache_miss;
- priv.value = total ? (100 * priv.cache_hit / total) : 0;
-@@ -280,7 +310,9 @@ main(int argc, char **argv)
- setlocale(LC_ALL, "");
-
- vd = VSM_New();
-+#if defined(HAVE_VARNISHAPI_3)
- VSC_Setup(vd);
-+#endif
-
- while ((opt = getopt(argc, argv, VSC_ARGS "c:hn:p:vw:")) != -1) {
- switch (opt) {
-@@ -311,8 +343,13 @@ main(int argc, char **argv)
- }
- }
-
-+#if defined(HAVE_VARNISHAPI_4)
-+ if (VSM_Open(vd))
-+ exit(1);
-+#elif defined(HAVE_VARNISHAPI_3)
- if (VSC_Open(vd, 1))
- exit(1);
-+#endif
-
- /* Default: if no param specified, check hit ratio. If no warning
- * and critical values are specified either, set these to default.
-diff --git a/configure.ac b/configure.ac
-index feac2bd..a3df21e 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -21,7 +21,13 @@ AC_PROG_LIBTOOL
- AC_PROG_MAKE_SET
-
- # Checks for libraries.
--PKG_CHECK_MODULES([VARNISHAPI], [varnishapi])
-+PKG_CHECK_MODULES([VARNISHAPI], [varnishapi >= 4],
-+ [AC_DEFINE([HAVE_VARNISHAPI_4], [1], [Use VARNISHAPI v4])],
-+ [PKG_CHECK_MODULES([VARNISHAPI], [varnishapi >= 3],
-+ [AC_DEFINE([HAVE_VARNISHAPI_3], [1], [Use VARNISHAPI v3])],
-+ [AC_MSG_ERROR([Could not find neither varnishapi v4 nor v3.])])
-+ ]
-+)
-
- # Checks for header files.
- AC_HEADER_STDC
diff --git a/net-analyzer/nagios-check_varnish/metadata.xml b/net-analyzer/nagios-check_varnish/metadata.xml
deleted file mode 100644
index 82f7232e..00000000
--- a/net-analyzer/nagios-check_varnish/metadata.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
-<pkgmetadata>
- <maintainer type="person">
- <email>bertrand@jacquin.bzh</email>
- <name>Bertrand Jacquin</name>
- </maintainer>
-</pkgmetadata>
diff --git a/net-analyzer/nagios-check_varnish/nagios-check_varnish-1.1.ebuild b/net-analyzer/nagios-check_varnish/nagios-check_varnish-1.1.ebuild
deleted file mode 100644
index b2beea74..00000000
--- a/net-analyzer/nagios-check_varnish/nagios-check_varnish-1.1.ebuild
+++ /dev/null
@@ -1,37 +0,0 @@
-# Copyright 1999-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-inherit multilib autotools eutils
-
-MY_PN="varnish-nagios"
-
-DESCRIPTION="Nagios plugin for Varnish"
-HOMEPAGE="https://www.varnish-cache.org"
-SRC_URI="https://repo.varnish-cache.org/source/${MY_PN}-${PV}.tar.gz"
-
-LICENSE="BSD-2 GPL-2"
-SLOT="0"
-KEYWORDS="~amd64"
-IUSE=""
-
-DEPEND="www-servers/varnish"
-RDEPEND="${DEPEND}"
-
-S="${WORKDIR}/${MY_PN}-${PV}"
-
-src_prepare() {
- default
-
- eapply "${FILESDIR}/${PV}-add-support-for-varnish-4.patch"
- eapply "${FILESDIR}/${PV}-Improve-help-output-to-differentiate-between-v3-and-.patch"
- eapply "${FILESDIR}/${PV}-Attempt-at-fixing-4.1-compat.patch"
- eapply "${FILESDIR}/${PV}-Make-gcc-explicitly-link-libm.-Fix-10.patch"
-
- eautoreconf
-}
-
-src_install() {
- exeinto /usr/$(get_libdir)/nagios/plugins
- doexe check_varnish
-}
diff --git a/net-analyzer/ndoutils/Manifest b/net-analyzer/ndoutils/Manifest
index c6eecaf5..0bcb00ee 100644
--- a/net-analyzer/ndoutils/Manifest
+++ b/net-analyzer/ndoutils/Manifest
@@ -1 +1 @@
-DIST ndoutils-2.1.3.tar.gz 2182958 SHA256 8f0bcc098e5098b8c048c42000fc08c17b36d8bb3cc4fb6972b7b8e8edfa91b7 WHIRLPOOL b10611680f20b9fc7c805580d0facead334bbc95543d7f705323efaf7a55b9341a201f21d39f30a884fb7bf9a3a558c8e5976474e10b00792a553480cad5c20c
+DIST ndoutils-2.1.3.tar.gz 2182958 SHA512 7c41ec6a72ed46b19d555a7faf491bd40fc6e99ab38bd38e6b57ae2eaa6e227159dcfd5532f347297fdbdc8f070548d3dd4ce3bcc26e91fe95f225d44937eae0 WHIRLPOOL b10611680f20b9fc7c805580d0facead334bbc95543d7f705323efaf7a55b9341a201f21d39f30a884fb7bf9a3a558c8e5976474e10b00792a553480cad5c20c