pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/sysutils/zabbix50-agent zabbix50-agent: simplify worka...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/7d62b97d0de4
branches:  trunk
changeset: 390577:7d62b97d0de4
user:      wiz <wiz%pkgsrc.org@localhost>
date:      Fri Dec 23 11:03:13 2022 +0000

description:
zabbix50-agent: simplify workaround for curl 7.87.0 issue

diffstat:

 sysutils/zabbix50-agent/Makefile                                          |   5 +-
 sysutils/zabbix50-agent/distinfo                                          |   3 +-
 sysutils/zabbix50-agent/patches/patch-src_libs_zbxsysinfo_simple_simple.c |  44 ----------
 3 files changed, 5 insertions(+), 47 deletions(-)

diffs (81 lines):

diff -r 0f4ffffadfb6 -r 7d62b97d0de4 sysutils/zabbix50-agent/Makefile
--- a/sysutils/zabbix50-agent/Makefile  Fri Dec 23 10:05:36 2022 +0000
+++ b/sysutils/zabbix50-agent/Makefile  Fri Dec 23 11:03:13 2022 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.11 2022/11/23 16:21:10 adam Exp $
+# $NetBSD: Makefile,v 1.12 2022/12/23 11:03:13 wiz Exp $
 
 PKGREVISION= 4
 .include "../../sysutils/zabbix50-server/Makefile.common"
@@ -18,6 +18,9 @@
 CONFIGURE_ARGS+=       --with-libpcre=${BUILDLINK_PREFIX.pcre}
 CONFIGURE_ARGS+=       --with-openssl=${BUILDLINK_PREFIX.openssl}
 
+# workaround for https://github.com/curl/curl/issues/10148
+CPPFLAGS+=     -DCURL_DISABLE_TYPECHECK
+
 EGDIR=         share/examples/${PKGBASE}
 CONF_FILES+=   ${EGDIR}/zabbix_agentd.conf ${PKG_SYSCONFDIR}/zabbix_agentd.conf
 
diff -r 0f4ffffadfb6 -r 7d62b97d0de4 sysutils/zabbix50-agent/distinfo
--- a/sysutils/zabbix50-agent/distinfo  Fri Dec 23 10:05:36 2022 +0000
+++ b/sysutils/zabbix50-agent/distinfo  Fri Dec 23 11:03:13 2022 +0000
@@ -1,9 +1,8 @@
-$NetBSD: distinfo,v 1.7 2022/12/23 09:25:17 wiz Exp $
+$NetBSD: distinfo,v 1.8 2022/12/23 11:03:13 wiz Exp $
 
 BLAKE2s (zabbix-5.0.17.tar.gz) = 7b5d674d79c41a0c9d9f6a8431408deaea101c5fe32034c115b3cb0350b9d647
 SHA512 (zabbix-5.0.17.tar.gz) = f7a23b51c3d2fb5f80ec888dc9eaf592dd13de3a61b9d065e6d54e1bb406e18ffef1b8e9d3ef516b2034d94fb7330bd80c2cb7b7d22eed7e57021bc66e1ee159
 Size (zabbix-5.0.17.tar.gz) = 21326776 bytes
 SHA1 (patch-configure) = cf647b9ee52a96882d31f8783ac19b66e3e65105
 SHA1 (patch-src_libs_zbxsysinfo_netbsd_net.c) = 468f2112a3d65b0a73f371194ae15ce0df0ad71c
-SHA1 (patch-src_libs_zbxsysinfo_simple_simple.c) = 4cadd37ec052eac400e6f1dd88f9945fc72c08ae
 SHA1 (patch-src_zabbix__agent_Makefile.in) = efbd804ecee4b99db36db5f4fd61583b2ef96a86
diff -r 0f4ffffadfb6 -r 7d62b97d0de4 sysutils/zabbix50-agent/patches/patch-src_libs_zbxsysinfo_simple_simple.c
--- a/sysutils/zabbix50-agent/patches/patch-src_libs_zbxsysinfo_simple_simple.c Fri Dec 23 10:05:36 2022 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,44 +0,0 @@
-$NetBSD: patch-src_libs_zbxsysinfo_simple_simple.c,v 1.1 2022/12/23 09:25:17 wiz Exp $
-
-Fix build with curl 7.87.0.
-
---- src/libs/zbxsysinfo/simple/simple.c.orig   2021-10-18 08:01:42.000000000 +0000
-+++ src/libs/zbxsysinfo/simple/simple.c
-@@ -164,25 +164,25 @@ static int       check_https(const char *host,
-       else
-               zbx_snprintf(https_host, sizeof(https_host), "%s%s", (0 == strncmp(host, "https://";, 8) ? "" : "https://";), host);
- 
--      if (CURLE_OK != (err = curl_easy_setopt(easyhandle, opt = CURLOPT_USERAGENT, "Zabbix " ZABBIX_VERSION)) ||
--              CURLE_OK != (err = curl_easy_setopt(easyhandle, opt = CURLOPT_URL, https_host)) ||
--              CURLE_OK != (err = curl_easy_setopt(easyhandle, opt = CURLOPT_PORT, (long)port)) ||
--              CURLE_OK != (err = curl_easy_setopt(easyhandle, opt = CURLOPT_NOBODY, 1L)) ||
--              CURLE_OK != (err = curl_easy_setopt(easyhandle, opt = CURLOPT_SSL_VERIFYPEER, 0L)) ||
--              CURLE_OK != (err = curl_easy_setopt(easyhandle, opt = CURLOPT_SSL_VERIFYHOST, 0L)) ||
--              CURLE_OK != (err = curl_easy_setopt(easyhandle, opt = CURLOPT_TIMEOUT, (long)timeout)))
-+      if (CURLE_OK != (err = curl_easy_setopt(easyhandle, CURLOPT_USERAGENT, "Zabbix " ZABBIX_VERSION)) ||
-+              CURLE_OK != (err = curl_easy_setopt(easyhandle, CURLOPT_URL, https_host)) ||
-+              CURLE_OK != (err = curl_easy_setopt(easyhandle, CURLOPT_PORT, (long)port)) ||
-+              CURLE_OK != (err = curl_easy_setopt(easyhandle, CURLOPT_NOBODY, 1L)) ||
-+              CURLE_OK != (err = curl_easy_setopt(easyhandle, CURLOPT_SSL_VERIFYPEER, 0L)) ||
-+              CURLE_OK != (err = curl_easy_setopt(easyhandle, CURLOPT_SSL_VERIFYHOST, 0L)) ||
-+              CURLE_OK != (err = curl_easy_setopt(easyhandle, CURLOPT_TIMEOUT, (long)timeout)))
-       {
--              zabbix_log(LOG_LEVEL_DEBUG, "%s: could not set cURL option [%d]: %s",
--                              __func__, (int)opt, curl_easy_strerror(err));
-+              zabbix_log(LOG_LEVEL_DEBUG, "%s: could not set cURL option: %s",
-+                              __func__, curl_easy_strerror(err));
-               goto clean;
-       }
- 
-       if (NULL != CONFIG_SOURCE_IP)
-       {
--              if (CURLE_OK != (err = curl_easy_setopt(easyhandle, opt = CURLOPT_INTERFACE, CONFIG_SOURCE_IP)))
-+              if (CURLE_OK != (err = curl_easy_setopt(easyhandle, CURLOPT_INTERFACE, CONFIG_SOURCE_IP)))
-               {
--                      zabbix_log(LOG_LEVEL_DEBUG, "%s: could not set source interface option [%d]: %s",
--                                      __func__, (int)opt, curl_easy_strerror(err));
-+                      zabbix_log(LOG_LEVEL_DEBUG, "%s: could not set source interface option: %s",
-+                                      __func__, curl_easy_strerror(err));
-                       goto clean;
-               }
-       }



Home | Main Index | Thread Index | Old Index