public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] repo/gentoo:master commit in: net-voip/captagent/files/, net-voip/captagent/
@ 2021-06-15  7:27 Joonas Niilola
  0 siblings, 0 replies; 2+ messages in thread
From: Joonas Niilola @ 2021-06-15  7:27 UTC (permalink / raw
  To: gentoo-commits

commit:     da3e8b66f93029192b00e06e47d80e8803999387
Author:     Jaco Kroon <jaco <AT> uls <DOT> co <DOT> za>
AuthorDate: Mon May 17 15:25:08 2021 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Tue Jun 15 07:27:37 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=da3e8b66

net-voip/captagent: New Package. Version 6.3.1.

CaptAgent: 100% Open-Source Packet Capture Agent for HEP

autoconf patch from upstream (in response to issue report).
gcc10 patches pending on PR.

Package-Manager: Portage-3.0.18, Repoman-3.0.2
Signed-off-by: Jaco Kroon <jaco <AT> uls.co.za>
Closes: https://github.com/gentoo/gentoo/pull/20854
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 net-voip/captagent/Manifest                        |   1 +
 net-voip/captagent/captagent-6.3.1.ebuild          |  47 +++++
 .../files/captagent-6.3.1-configure.patch          | 189 +++++++++++++++++++
 .../captagent/files/captagent-6.3.1-gcc10.patch    | 207 +++++++++++++++++++++
 net-voip/captagent/metadata.xml                    |  15 ++
 5 files changed, 459 insertions(+)

diff --git a/net-voip/captagent/Manifest b/net-voip/captagent/Manifest
new file mode 100644
index 00000000000..f3158f78242
--- /dev/null
+++ b/net-voip/captagent/Manifest
@@ -0,0 +1 @@
+DIST captagent-6.3.1.tar.gz 1488741 BLAKE2B c59c5a4633f18b4eed07cc216ba939712140a244504e4263f10dec27f5937bbd54103f32a4c2a350c2560b56da18c98b6137d005010d5bb93e712d2d6fc86d0d SHA512 e4043ddb92a1228fb9e4e220e503e3bd0bf9009c893e9c153fc90d15f91902ff7b86ca4b01bf2ef40056bc16647a3838fcfb88f76503f41f4bea88d054e4d7de

diff --git a/net-voip/captagent/captagent-6.3.1.ebuild b/net-voip/captagent/captagent-6.3.1.ebuild
new file mode 100644
index 00000000000..fecb259850e
--- /dev/null
+++ b/net-voip/captagent/captagent-6.3.1.ebuild
@@ -0,0 +1,47 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools
+
+DESCRIPTION="CaptAgent: 100% Open-Source Packet Capture Agent for HEP"
+HOMEPAGE="https://sipcapture.org/ https://github.com/sipcapture/captagent"
+SRC_URI="https://github.com/sipcapture/captagent/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-3+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="ipv6 mysql pcre redis ssl"
+
+PATCHES=(
+	# https://github.com/sipcapture/captagent/pull/239 (should be accepted).
+	"${FILESDIR}/${P}-gcc10.patch"
+	# Already upstreamed for next version.
+	"${FILESDIR}/${P}-configure.patch"
+)
+
+DEPEND="dev-libs/json-c
+	net-libs/libpcap
+	dev-libs/libuv
+	mysql? ( dev-db/mysql-connector-c )
+	pcre? ( dev-libs/libpcre )
+	redis? ( dev-db/redis )
+	ssl? ( dev-libs/openssl )"
+RDEPEND="${DEPEND}"
+
+src_prepare() {
+	default
+	eautoreconf
+}
+
+src_configure() {
+	econf --enable-compression \
+		--disable-epan \
+		$(use_enable ipv6) \
+		$(use_enable mysql) \
+		$(use_enable pcre) \
+		$(use_enable redis) \
+		$(use_enable ssl tls) \
+		$(use_enable ssl)
+}

diff --git a/net-voip/captagent/files/captagent-6.3.1-configure.patch b/net-voip/captagent/files/captagent-6.3.1-configure.patch
new file mode 100644
index 00000000000..c50c6c6c0ff
--- /dev/null
+++ b/net-voip/captagent/files/captagent-6.3.1-configure.patch
@@ -0,0 +1,189 @@
+From a27139cd27aae3392c7b8e8bdeed0db50f0f2503 Mon Sep 17 00:00:00 2001
+From: Alexandr Dubovikov <alexandr.dubovikov@gmail.com>
+Date: Mon, 17 May 2021 14:34:23 +0200
+Subject: [PATCH] fixed disable/enable conditions
+
+---
+ configure.ac | 112 +++++++++++++++++++++++----------------------------
+ 1 file changed, 50 insertions(+), 62 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 67be26c..85789bd 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -1,5 +1,5 @@
+ AC_PREREQ(2.61)
+-AC_INIT(captagent,6.3.0,support@sipcapture.org,,[http://www.sipcapture.org])
++AC_INIT(captagent,6.3.1,support@sipcapture.org,,[http://www.sipcapture.org])
+ AC_COPYRIGHT("SIP Capture Solution")
+ AC_CONFIG_MACRO_DIR([m4])
+ AM_INIT_AUTOMAKE(foreign tar-ustar)
+@@ -28,67 +28,63 @@ AC_DEFINE_UNQUOTED(AGENT_PLAN_DIR, ["$agent_plan_dir"], [capture plans dir])
+ AC_DEFINE_UNQUOTED(MODULE_DIR, ["$module_dir"], [directory that modules will be installed to])
+ 
+ enableCompression=no
+-AC_ARG_ENABLE(compression,
+-   [  --enable-compression	Enable compression support)],
+-   [ZLIB="$enableval"]
+-   enableCompression=yes,
+-   [ZLIB="no"]
+-)
++AC_ARG_ENABLE([compression], AS_HELP_STRING([--enable-compression],[Enable compression support]))
++AS_IF([test "x$enable_compression" = "xyes"], [
++        enableCompression=yes
++        AC_DEFINE([ZLIB], [1], [Enable compression support])
++])
+ AC_MSG_RESULT([$ZLIB])
+ AC_SUBST([ZLIB])
+ 
+ AC_MSG_CHECKING([whether to use ssl])
++
+ enableSSL=no
+-AC_ARG_ENABLE(ssl,
+-   [  --enable-ssl	Enable SSL support],
+-   [SSL="$enableval"]
+-   enableSSL=yes,
+-   [SSL="no"]
+-)
++AC_ARG_ENABLE([ssl], AS_HELP_STRING([--enable-ssl],[Enable SSL support]))
++AS_IF([test "x$enable_ssl" = "xyes"], [
++        enableSSL=yes
++        AC_DEFINE([SSL], [1], [Enable SSL support])
++])
+ AC_MSG_RESULT([$SSL])
+ AC_SUBST([SSL])
+ 
+ useMysql=no
+ AC_MSG_CHECKING([whether to use mysql])
+-AC_ARG_ENABLE(mysql,
+-   [  --enable-mysql    Enable mysql support],
+-   [MYSQL="$enableval"]
+-   useMysql=yes,
+-   [MYSQL="no"]
+-)
++AC_ARG_ENABLE([mysql], AS_HELP_STRING([--enable-mysql],[Enable MySQL support]))
++AS_IF([test "x$enable_mysql" = "xyes"], [
++        useMysql=yes
++        AC_DEFINE([MYSQL], [1], [Enable MySQL support])
++])
+ AC_MSG_RESULT([$MYSQL])
+ AC_SUBST([MYSQL])
+ 
+ useEpan=no
+-AC_ARG_ENABLE(epan,
+-   [  --enable-epan	Enable EPAN support / Wireshark dissectors)],
+-   [EPAN="$enableval"]
+-   useEpan=yes,
+-   [EPAN="no"]
+-)
++AC_ARG_ENABLE([epan], AS_HELP_STRING([--enable-epan],[Enable EPAN support / Wireshark dissectors]))
++AS_IF([test "x$enable_epan" = "xyes"], [
++        useEpan=yes
++        AC_DEFINE([EPAN], [1], [Enable epan support])
++])
+ AC_MSG_RESULT([$EPAN])
+ AC_SUBST([EPAN])
+ 
+ 
+ usePCRE=no
+ AC_MSG_CHECKING([whether to use pcre])
+-AC_ARG_ENABLE(pcre,
+-   [  --enable-pcre    Enable pcre support],
+-   [PCRE="$enableval"]
+-   usePCRE=yes,
+-   [PCRE="no"]
+-)
++AC_ARG_ENABLE([pcre], AS_HELP_STRING([--enable-pcre],[Enable pcre support]))
++AS_IF([test "x$enable_pcre" = "xyes"], [
++        usePCRE=yes
++	AC_DEFINE([PCRE], [1], [Enable pcre support])
++])
+ AC_MSG_RESULT([$PCRE])
+ AC_SUBST([PCRE])
+ 
+ useRedis=no
+ AC_MSG_CHECKING([whether to use redis])
+-AC_ARG_ENABLE(redis,
+-   [  --enable-redis    Enable redis support],
+-   [REDIS="$enableval"]
+-   useRedis=yes,
+-   [REDIS="no"]
+-)
++AC_ARG_ENABLE([redis], AS_HELP_STRING([--enable-redis],[Enable redis support]))
++AS_IF([test "x$enable_redis" = "xyes"], [
++        useRedis=yes
++	AC_DEFINE([REDIS], [1], [Enable redis])
++])
++
+ AC_MSG_RESULT([$REDIS])
+ AC_SUBST([REDIS])
+ 
+@@ -98,22 +94,20 @@ AC_SUBST([LIBUV])
+ 
+ useTLS=no
+ AC_MSG_CHECKING([whether to use TLS])
+-AC_ARG_ENABLE(tls,
+-   [  --enable-tls    Enable TLS support],
+-   [TLS="$enableval"]
+-   useTLS=yes,
+-   [TLS="no"]
+-)
++AC_ARG_ENABLE([tls], AS_HELP_STRING([--enable-tls],[Enable TLS support]))
++AS_IF([test "x$enable_tls" = "xyes"], [
++        useTLS=yes
++	AC_DEFINE([TLS], [1], [Enable tls])
++])
+ AC_MSG_RESULT([$TLS])
+ AC_SUBST([TLS])
+ 
+ enableExtraModules=no
+-AC_ARG_ENABLE(extramodules,
+-   [  --enable-extramodules	Enable extra modules],
+-   [EXTRAMODULES="$enableval"]
+-   enableExtraModules=yes,
+-   [EXTRAMODULES="no"]
+-)
++AC_ARG_ENABLE([extramodules], AS_HELP_STRING([--enable-extramodules],[Enable extra modules]))
++AS_IF([test "x$enable_extramodules" = "xyes"], [
++        enableExtraModules=yes
++        AC_DEFINE([EXTRAMODULES], [1], [Enable extra modules support])
++])
+ AC_MSG_RESULT([$EXTRAMODULES])
+ AC_SUBST([EXTRAMODULES])
+ 
+@@ -330,20 +324,14 @@ dnl
+ dnl IPv6 (and ICMPv6) support
+ dnl
+ 
+-AC_ARG_ENABLE(ipv6,
+-[  --enable-ipv6                enable IPv6 (and ICMPv6) support],
+-[
+-  use_ipv6="$enableval"
+-],
+-[
+-  use_ipv6="no"
++useIPv6=no
++AC_ARG_ENABLE([ipv6], AS_HELP_STRING([--enable-ipv6],[Enable IPv6 support]))
++AS_IF([test "x$enable_ipv6" = "xyes"], [
++        useIPv6=yes
++        AC_DEFINE([USE_IPv6], [1], [IPv6 (and ICMPv6) support])
++        AC_SUBST(USE_IPv6, yes)
+ ])
+ 
+-if test $use_ipv6 = yes; then
+-   AC_DEFINE(USE_IPv6, [1], [IPv6 (and ICMPv6) support])
+-   AC_SUBST(USE_IPv6, yes)
+-fi
+-
+ 
+ # Checks for header files.
+ AC_CHECK_HEADER(pcap.h,,[AC_MSG_ERROR([$PACKAGE_NAME cannot find pcap.h])])
+@@ -388,7 +376,7 @@ echo
+ echo Build directory............. : $captagent_builddir
+ echo Installation prefix......... : $prefix
+ echo HEP Compression............. : $enableCompression
+-echo IPv6 support.................: $use_ipv6
++echo IPv6 support.................: $useIPv6
+ echo HEP SSL/TLS................. : $enableSSL
+ echo Flex........................ : ${LEX:-NONE}
+ echo Bison....................... : ${YACC:-NONE}

diff --git a/net-voip/captagent/files/captagent-6.3.1-gcc10.patch b/net-voip/captagent/files/captagent-6.3.1-gcc10.patch
new file mode 100644
index 00000000000..a03dd72dfea
--- /dev/null
+++ b/net-voip/captagent/files/captagent-6.3.1-gcc10.patch
@@ -0,0 +1,207 @@
+From 61ea167f9b4ab34a1437736cbda20d21efd06e30 Mon Sep 17 00:00:00 2001
+From: Jaco Kroon <jaco@uls.co.za>
+Date: Tue, 11 May 2021 16:44:55 +0200
+Subject: [PATCH] Minimum set of changes to make gcc10 compatible.
+
+This does not fix any of the other bugs I spotted along the way
+(module_path being assigned a static string and then later free()d for
+example).
+---
+ .gitignore                            |  2 ++
+ include/captagent/api.h               | 10 ++++++++--
+ include/captagent/modules.h           |  2 +-
+ src/captagent.c                       |  2 --
+ src/conf_function.c                   |  3 +++
+ src/conf_function.h                   |  2 --
+ src/modules.c                         |  3 +++
+ src/modules/protocol/tls/decryption.h |  6 +-----
+ src/modules/protocol/tls/parser_tls.h | 12 ++++++------
+ 9 files changed, 24 insertions(+), 18 deletions(-)
+
+diff --git a/.gitignore b/.gitignore
+index d2ed328..a7cd5a3 100644
+--- a/.gitignore
++++ b/.gitignore
+@@ -2,6 +2,7 @@ INSTALL
+ Makefile
+ Makefile.in
+ aclocal.m4
++compile
+ config.guess
+ src/config.h
+ src/config.h.in
+@@ -45,5 +46,6 @@ pkg/debian/files
+ pkg/debian/captagent/
+ pkg/debian/captagent.init
+ src/captagent
++src/capplan.tab.c
+ *.dh-orig
+ 
+diff --git a/include/captagent/api.h b/include/captagent/api.h
+index 4ec62de..d550875 100644
+--- a/include/captagent/api.h
++++ b/include/captagent/api.h
+@@ -43,6 +43,13 @@
+ 
+ #include "config.h"
+ 
++#ifdef __GNUC__
++/* GNU C */
++#define PACK_OFF __attribute__ ((__packed__));
++#else
++#define PACK_OFF
++#endif
++
+ #ifndef AGENT_CONFIG_DIR
+ #define AGENT_CONFIG_DIR "/usr/local/etc/captagent/"
+ #endif //DEF_CONF
+@@ -120,9 +127,8 @@ typedef struct stats_object {
+ 
+ extern struct stats_object stats_obj;
+ 
+-struct hep_module *hepmod;
+ extern int get_basestat(char *module, char *stats, size_t len);
+-struct module *module_list;
++extern struct module *module_list;
+ 
+ #ifndef TRUE
+ #define TRUE  1
+diff --git a/include/captagent/modules.h b/include/captagent/modules.h
+index 1eedabe..ec0676b 100644
+--- a/include/captagent/modules.h
++++ b/include/captagent/modules.h
+@@ -27,7 +27,7 @@
+ #ifndef MODULES_H_
+ #define MODULES_H_
+ 
+-char *module_path;
++extern char *module_path;
+ 
+ #define VAR_PARAM_NO  -128
+ 
+diff --git a/src/captagent.c b/src/captagent.c
+index b5c3081..6f5f533 100644
+--- a/src/captagent.c
++++ b/src/captagent.c
+@@ -321,8 +321,6 @@ int main(int argc, char *argv[]) {
+ 	/* PATH */
+ 	module_path = MODULE_DIR;
+ 
+-	hepmod = malloc(sizeof(hep_module_t));
+-
+ 	load_xml_config();
+ 
+ 	/*CORE CONFIG */
+diff --git a/src/conf_function.c b/src/conf_function.c
+index 478ce73..9f4648f 100644
+--- a/src/conf_function.c
++++ b/src/conf_function.c
+@@ -57,6 +57,9 @@
+ #define ROUTE_MAX_REC_LEV 10 /* maximum number of recursive calls
+                                                            for capture()*/
+ 
++struct sr_module* modules; /* global module list */
++
++
+ /* ret= 0! if action -> end of list(e.g DROP),
+       > 0 to continue processing next actions
+    and <0 on error */
+diff --git a/src/conf_function.h b/src/conf_function.h
+index 3ee82ba..ff532d9 100644
+--- a/src/conf_function.h
++++ b/src/conf_function.h
+@@ -79,8 +79,6 @@ struct sr_module{
+         struct sr_module* next;
+ };
+ 
+-struct sr_module* modules; /* global module list */
+-
+ int register_builtin_modules();
+ int load_module(char* path);
+ cmd_function find_export2(char* name, int param_no);
+diff --git a/src/modules.c b/src/modules.c
+index 0ad00b5..c0397e1 100644
+--- a/src/modules.c
++++ b/src/modules.c
+@@ -40,6 +40,9 @@
+ #include <captagent/modules_api.h>
+ #include <captagent/modules.h>
+ 
++struct module *module_list;
++char *module_path;
++
+ int register_module(char *resource_name, xml_node *config, bool global) {
+ 	const char *error;
+ 	module_exports_t *exp;
+diff --git a/src/modules/protocol/tls/decryption.h b/src/modules/protocol/tls/decryption.h
+index fd5e0d7..b553195 100644
+--- a/src/modules/protocol/tls/decryption.h
++++ b/src/modules/protocol/tls/decryption.h
+@@ -35,6 +35,7 @@
+ #include <gcrypt.h>
+ #include "define.h"
+ #include "uthash.h"
++#include "captagent/api.h"
+ 
+ #define SHA384 0x009d
+ #define SHA256 0x009c
+@@ -68,11 +69,6 @@ int private_decrypt(unsigned char * enc_data, int data_len, unsigned char * key,
+ 
+ /* **************************** */
+ 
+-#ifdef __GNUC__
+-/* GNU C */
+-#define PACK_OFF __attribute__ ((__packed__));
+-#endif
+-
+ 
+ /* ++++++++++++++++++++++++ CISCO HDLC +++++++++++++++++++++++++ */
+ struct chdlc_hdr
+diff --git a/src/modules/protocol/tls/parser_tls.h b/src/modules/protocol/tls/parser_tls.h
+index e6d6aec..c24076b 100644
+--- a/src/modules/protocol/tls/parser_tls.h
++++ b/src/modules/protocol/tls/parser_tls.h
+@@ -45,15 +45,15 @@
+ #define TLS12   0x0303
+ 
+ // Record Type values
+-enum {
++enum Record_Type {
+   CHANGE_CIPHER_SPEC = 20,
+   ALERT              = 21,
+   HANDSHAKE          = 22,
+   APPLICATION_DATA   = 23
+-} Record_Type;
++};
+ 
+ // Handshake Type values
+-enum {
++enum Handshake_Type {
+   HELLO_REQUEST       = 0,
+   CLIENT_HELLO        = 1,
+   SERVER_HELLO        = 2,
+@@ -66,10 +66,10 @@ enum {
+   CERTIFICATE_VERIFY  = 15,
+   CLIENT_KEY_EXCHANGE = 16,
+   FINISHED            = 20
+-} Handshake_Type;
++};
+ 
+ // Client Certificate types for Certificate Request
+-enum {
++enum Client_Certificate_Type {
+   RSA_SIGN                  = 1,
+   DSS_SIGN                  = 2,
+   RSA_FIXED_DH              = 3,
+@@ -77,7 +77,7 @@ enum {
+   RSA_EPHEMERAL_DH_RESERVED = 5,
+   DSS_EPHEMERAL_DH_RESERVED = 6,
+   FORTEZZA_DMS_RESERVED     = 20
+-} Client_Certificate_Type;
++};
+ 
+ 
+ // Chipher Suite availlable for decription
+-- 
+2.26.3
+

diff --git a/net-voip/captagent/metadata.xml b/net-voip/captagent/metadata.xml
new file mode 100644
index 00000000000..88e45e34f7c
--- /dev/null
+++ b/net-voip/captagent/metadata.xml
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+	<maintainer type="person" proxied="yes">
+		<email>jaco@uls.co.za</email>
+		<name>Jaco Kroon</name>
+	</maintainer>
+	<maintainer type="project" proxied="proxy">
+		<email>proxy-maint@gentoo.org</email>
+		<name>Proxy Maintainers</name>
+	</maintainer>
+	<use>
+		<flag name="redis">Enable redis support</flag>
+	</use>
+</pkgmetadata>


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [gentoo-commits] repo/gentoo:master commit in: net-voip/captagent/files/, net-voip/captagent/
@ 2022-01-20 12:39 Sam James
  0 siblings, 0 replies; 2+ messages in thread
From: Sam James @ 2022-01-20 12:39 UTC (permalink / raw
  To: gentoo-commits

commit:     b5b0a869b6d98b25d8494c48a9e21db4398dc4a3
Author:     Jaco Kroon <jaco <AT> uls <DOT> co <DOT> za>
AuthorDate: Thu Jan 20 09:14:12 2022 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Jan 20 12:37:09 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b5b0a869

net-voip/captagent: revision bump to fix clang compile

Upstream: https://github.com/sipcapture/captagent/pull/245

Not expecting a new release soon.

Closes: https://bugs.gentoo.org/831391
Package-Manager: Portage-3.0.28, Repoman-3.0.3
Signed-off-by: Jaco Kroon <jaco <AT> uls.co.za>
Closes: https://github.com/gentoo/gentoo/pull/23880
Signed-off-by: Sam James <sam <AT> gentoo.org>

 ...gent-6.3.1.ebuild => captagent-6.3.1-r1.ebuild} |  6 ++-
 .../captagent/files/captagent-6.3.1-r1-clang.patch | 63 ++++++++++++++++++++++
 2 files changed, 67 insertions(+), 2 deletions(-)

diff --git a/net-voip/captagent/captagent-6.3.1.ebuild b/net-voip/captagent/captagent-6.3.1-r1.ebuild
similarity index 82%
rename from net-voip/captagent/captagent-6.3.1.ebuild
rename to net-voip/captagent/captagent-6.3.1-r1.ebuild
index 7addb19c0e0d..3023031778b2 100644
--- a/net-voip/captagent/captagent-6.3.1.ebuild
+++ b/net-voip/captagent/captagent-6.3.1-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
@@ -15,8 +15,10 @@ KEYWORDS="~amd64 ~x86"
 IUSE="ipv6 mysql pcre redis ssl"
 
 PATCHES=(
-	# https://github.com/sipcapture/captagent/pull/239 (should be accepted).
+	# https://github.com/sipcapture/captagent/pull/239 (merged).
 	"${FILESDIR}/${P}-gcc10.patch"
+	# https://github.com/sipcapture/captagent/pull/245 (merged).
+	"${FILESDIR}/${P}-captagent-6.3.1-r1-clang.patch"
 	# Already upstreamed for next version.
 	"${FILESDIR}/${P}-configure.patch"
 )

diff --git a/net-voip/captagent/files/captagent-6.3.1-r1-clang.patch b/net-voip/captagent/files/captagent-6.3.1-r1-clang.patch
new file mode 100644
index 000000000000..02940147d30f
--- /dev/null
+++ b/net-voip/captagent/files/captagent-6.3.1-r1-clang.patch
@@ -0,0 +1,63 @@
+From a4b5cc7806861b75b03ea0d31e1413e3e293770c Mon Sep 17 00:00:00 2001
+From: Jaco Kroon <jaco@uls.co.za>
+Date: Thu, 20 Jan 2022 07:07:40 +0200
+Subject: [PATCH] Move declaration of usage() function to avoid conflicting
+ implicit declaration.
+
+Signed-off-by: Jaco Kroon <jaco@uls.co.za>
+---
+ src/captagent.c | 31 +++++++++++++++----------------
+ 1 file changed, 15 insertions(+), 16 deletions(-)
+
+diff --git a/src/captagent.c b/src/captagent.c
+index 6f5f533..052b0bb 100644
+--- a/src/captagent.c
++++ b/src/captagent.c
+@@ -108,6 +108,21 @@ void handler(int value) {
+ 	exit(0);
+ }
+ 
++void usage(int8_t e)
++{
++	printf(
++        "usage: Captagent <-vh> <-f config>\n"
++        "   -h  display help/usage\n"
++        "   -a  print a list of all availlable devices\n"
++        "   -v  display version information\n"
++        "   -c  validate configuration and exit\n"
++        "   -d  enable daemon mode\n"
++        "   -n  enable foreground mode\n"
++        "   -f  [/path/to/rtpagent.xml] to specify a config file\n"
++        "   -D  [/path/to/file.pcap] to specify a pcap file as input\n"
++        "   -x  [1 - 10] set debug level\n");
++	exit(e);
++}
+ 
+ // Print the list of availlable devices
+ static void print_all_devices()
+@@ -230,22 +245,6 @@ int daemonize(int nofork)
+ 	error: return -1;
+ }
+ 
+-void usage(int8_t e)
+-{
+-	printf(
+-        "usage: Captagent <-vh> <-f config>\n"
+-        "   -h  display help/usage\n"
+-        "   -a  print a list of all availlable devices\n"
+-        "   -v  display version information\n"
+-        "   -c  validate configuration and exit\n"
+-        "   -d  enable daemon mode\n"
+-        "   -n  enable foreground mode\n"
+-        "   -f  [/path/to/rtpagent.xml] to specify a config file\n"
+-        "   -D  [/path/to/file.pcap] to specify a pcap file as input\n"
+-        "   -x  [1 - 10] set debug level\n");
+-	exit(e);
+-}
+-
+ void print_hw() {
+ 
+ 	char k[33];
+-- 
+2.33.1
+


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-01-20 12:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-01-20 12:39 [gentoo-commits] repo/gentoo:master commit in: net-voip/captagent/files/, net-voip/captagent/ Sam James
  -- strict thread matches above, loose matches on Subject: below --
2021-06-15  7:27 Joonas Niilola

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox