public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-analyzer/tcptrace/files/, net-analyzer/tcptrace/
Date: Wed, 20 Mar 2024 06:26:45 +0000 (UTC)	[thread overview]
Message-ID: <1710915421.b29b05a7c97ec83ea7074ed87d0b87796914c58d.sam@gentoo> (raw)

commit:     b29b05a7c97ec83ea7074ed87d0b87796914c58d
Author:     Eli Schwartz <eschwartz93 <AT> gmail <DOT> com>
AuthorDate: Wed Mar 20 05:10:01 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed Mar 20 06:17:01 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b29b05a7

net-analyzer/tcptrace: fix Modern C porting

Closes: https://bugs.gentoo.org/900042
Signed-off-by: Eli Schwartz <eschwartz93 <AT> gmail.com>
Signed-off-by: Sam James <sam <AT> gentoo.org>

 ...n-fix-implicit-function-declaration-causi.patch | 26 ++++++++
 net-analyzer/tcptrace/tcptrace-6.6.7_p6-r2.ebuild  | 73 ++++++++++++++++++++++
 2 files changed, 99 insertions(+)

diff --git a/net-analyzer/tcptrace/files/0001-configure.in-fix-implicit-function-declaration-causi.patch b/net-analyzer/tcptrace/files/0001-configure.in-fix-implicit-function-declaration-causi.patch
new file mode 100644
index 000000000000..d9158bae6981
--- /dev/null
+++ b/net-analyzer/tcptrace/files/0001-configure.in-fix-implicit-function-declaration-causi.patch
@@ -0,0 +1,26 @@
+From f199970cdb38259f0748e79ece844dc2cd676cdf Mon Sep 17 00:00:00 2001
+From: Eli Schwartz <eschwartz93@gmail.com>
+Date: Tue, 19 Mar 2024 21:39:10 -0400
+Subject: [PATCH] configure.in: fix implicit function declaration causing test
+ to mistest
+
+---
+ configure.in | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/configure.in b/configure.in
+index 38132e0..e973815 100644
+--- a/configure.in
++++ b/configure.in
+@@ -51,6 +51,8 @@ dnl If strcmp returns 0, we are on an enironment that uses %llu, otherwise
+ dnl we are on a MacOSX environment that uses %qu
+ AC_TRY_RUN([
+ #include <stdio.h>
++#include <string.h>
++#include <stdlib.h>
+ 
+ #define NIX "%llu"
+ 
+-- 
+2.43.2
+

diff --git a/net-analyzer/tcptrace/tcptrace-6.6.7_p6-r2.ebuild b/net-analyzer/tcptrace/tcptrace-6.6.7_p6-r2.ebuild
new file mode 100644
index 000000000000..cce2849f482b
--- /dev/null
+++ b/net-analyzer/tcptrace/tcptrace-6.6.7_p6-r2.ebuild
@@ -0,0 +1,73 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+inherit autotools flag-o-matic
+
+DESCRIPTION="A Tool for analyzing network packet dumps"
+HOMEPAGE="http://www.tcptrace.org/"
+SRC_URI="
+	http://www.tcptrace.org/download/${P/_p*}.tar.gz
+	http://www.tcptrace.org/download/old/$(ver_cut 1-2)/${P/_p*}.tar.gz
+	mirror://debian/pool/main/t/${PN}/${PN}_${PV/_p*}-${PV/*_p}.debian.tar.xz
+"
+
+SLOT="0"
+LICENSE="GPL-2"
+KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
+
+DEPEND="
+	net-libs/libpcap
+"
+RDEPEND="
+	${DEPEND}
+"
+PATCHES=(
+	"${FILESDIR}"/${P/_p*}-cross-compile.patch
+	"${FILESDIR}"/${P/_p*}-_DEFAULT_SOURCE.patch
+	"${FILESDIR}"/${P/_p*}-fix-build-clang16.patch
+	"${FILESDIR}"/0001-configure.in-fix-implicit-function-declaration-causi.patch
+)
+S=${WORKDIR}/${P/_p*}
+
+src_prepare() {
+	default
+
+	eapply \
+		$(awk '{ print "'"${WORKDIR}"'/debian/patches/" $0; }' < "${WORKDIR}"/debian/patches/series)
+
+	eautoreconf
+}
+
+src_configure() {
+	# -Werror=strict-aliasing
+	# https://bugs.gentoo.org/861260
+	#
+	# Upstream site no longer exists.
+	#
+	# Do not trust with LTO either.
+	append-flags -fno-strict-aliasing
+	filter-lto
+
+	default
+}
+
+src_compile() {
+	emake CCOPT="${CFLAGS}"
+}
+
+src_install() {
+	dobin tcptrace xpl2gpl
+
+	newman tcptrace.man tcptrace.1
+	dodoc CHANGES COPYRIGHT FAQ README* THANKS WWW
+}
+
+pkg_postinst() {
+	if ! has_version ${CATEGORY}/${PN}; then
+		elog "Note: tcptrace outputs its graphs in the xpl (xplot)"
+		elog "format. Since xplot is unavailable, you will have to"
+		elog "use the included xpl2gpl utility to convert it to"
+		elog "the gnuplot format."
+	fi
+}


             reply	other threads:[~2024-03-20  6:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-20  6:26 Sam James [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-09-14 18:08 [gentoo-commits] repo/gentoo:master commit in: net-analyzer/tcptrace/files/, net-analyzer/tcptrace/ Arthur Zamarin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1710915421.b29b05a7c97ec83ea7074ed87d0b87796914c58d.sam@gentoo \
    --to=sam@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox