- Update to 1.5beta7

- Remove DEPRECATED and EXPIRATION_DATE
- Change MASTER_SITES to github
- Install tcptraceroute to PREFIX/bin
- Add DOCS options and PORTDOCS
- Use new @(user,group,perm) format in PLIST
- Reformat pkg-desc

Changes:	https://github.com/mct/tcptraceroute/blob/master/ChangeLog
This commit is contained in:
Sunpoet Po-Chuan Hsieh 2014-09-09 18:41:28 +00:00
parent 8c82bff238
commit 8c4b2dfb39
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=367760
7 changed files with 102 additions and 90 deletions

View file

@ -2,23 +2,27 @@
# $FreeBSD$ # $FreeBSD$
PORTNAME= tcptraceroute PORTNAME= tcptraceroute
PORTVERSION= 1.4 PORTVERSION= 1.5beta7
PORTREVISION= 2
CATEGORIES= net CATEGORIES= net
MASTER_SITES= http://michael.toren.net/code/tcptraceroute/ \
LOCAL/sunpoet
MAINTAINER= sunpoet@FreeBSD.org MAINTAINER= sunpoet@FreeBSD.org
COMMENT= Traceroute implementation using TCP packets COMMENT= Traceroute implementation using TCP packets
LICENSE= GPLv2 LICENSE= GPLv2
DEPRECATED= Depends on expired net/libnet10 LIB_DEPENDS= libnet.so:${PORTSDIR}/net/libnet
EXPIRATION_DATE= 2014-09-30
BUILD_DEPENDS= ${LOCALBASE}/bin/libnet10-config:${PORTSDIR}/net/libnet10 OPTIONS_DEFINE= DOCS
post-patch: GNU_CONFIGURE= yes
@${REINPLACE_CMD} -e 's|libnet-config|libnet10-config|' ${WRKSRC}/Makefile USES= gmake
PORTDOCS= *
USE_GITHUB= yes
GH_ACCOUNT= mct
GH_COMMIT= 1ec970e
GH_PROJECT= ${PORTNAME}
GH_TAGNAME= ${PORTNAME}-${PORTVERSION}
.include <bsd.port.mk> .include <bsd.port.mk>

View file

@ -1,2 +1,2 @@
SHA256 (tcptraceroute-1.4.tar.gz) = 1ef6c4736b55f47d3a2bb26b999cbb409953a112f637bcbec4106da2a0937bde SHA256 (tcptraceroute-1.5beta7.tar.gz) = 3b27b7c67e2eb00ef800c83e496f1198b992f038de5d3d13aa530ee3b22c77bb
SIZE (tcptraceroute-1.4.tar.gz) = 31918 SIZE (tcptraceroute-1.5beta7.tar.gz) = 119068

View file

@ -1,36 +0,0 @@
--- Makefile.orig Mon May 20 03:11:38 2002
+++ Makefile Tue Aug 20 01:49:27 2002
@@ -3,20 +3,27 @@
# tcptraceroute -- A traceroute implementation using TCP packets
# Copyright (c) 2001, 2002 Michael C. Toren <mct@toren.net>
-CC = gcc
-CFLAGS = -O2 -Wall
-DESTDIR=/usr/local/bin
+CC?= cc
+CFLAGS?= -O -pipe -Wall
+LNETINC= `libnet-config --cflags`
+LNETLIB= `libnet-config --libs`
+
+BINDIR= ${PREFIX}/sbin
+MANDIR= ${PREFIX}/man
+
+all: tcptraceroute
tcptraceroute: tcptraceroute.c
- $(CC) $(CFLAGS) `libnet-config --defines` \
+ $(CC) $(CFLAGS) `libnet-config --defines` $(LNETINC) \
-o tcptraceroute tcptraceroute.c \
- `libnet-config --libs` -lpcap
+ $(LNETLIB) -lpcap
static:
$(MAKE) tcptraceroute CFLAGS="$(CFLAGS) -static"
install: tcptraceroute
- install -D tcptraceroute $(DESTDIR)/tcptraceroute
+ install -c -s tcptraceroute $(DESTDIR)$(BINDIR)/tcptraceroute
+ install -c -m 444 tcptraceroute.8 $(DESTDIR)$(MANDIR)/man8/tcptraceroute.8
distrib: clean changelog man

View file

@ -0,0 +1,73 @@
--- configure.orig 2006-03-28 13:00:00.000000000 +0800
+++ configure 2014-09-10 00:44:22.750008451 +0800
@@ -3713,37 +3713,39 @@
fi;
-LIBNET_CONFIG="libnet-config" # relative, using $PATH
-
-# Check whether --with-libnet or --without-libnet was given.
-if test "${with_libnet+set}" = set; then
- withval="$with_libnet"
-
- LIBNETCC=""
- LIBNETLD=""
-
- test -x "$withval/bin/libnet-config" && LIBNET_CONFIG="$withval/bin/libnet-config"
- test -x "$withval/libnet-config" && LIBNET_CONFIG="$withval/libnet-config"
-
- test -f "$withval/libnet.h" && LIBNETCC="$LIBNETCC -I$withval"
- test -f "$withval/include/libnet.h" && LIBNETCC="$LIBNETCC -I$withval/include"
-
- test -f "$withval/libnet.a" && LIBNETLD="$LIBNETLD -L$withval"
- test -f "$withval/lib/libnet.a" && LIBNETLD="$LIBNETLD -L$withval/lib"
-
- if test -z "$LIBNETCC" -o -z "$LIBNETLD"
- then
- { { echo "$as_me:$LINENO: error: No valid libnet library found in $withval" >&5
-echo "$as_me: error: No valid libnet library found in $withval" >&2;}
- { (exit 1); exit 1; }; }
- else
- CPPFLAGS="$CPPFLAGS $LIBNETCC"
- LDFLAGS="$LDFLAGS $LIBNETLD"
- { echo "$as_me:$LINENO: using libnet in $withval" >&5
-echo "$as_me: using libnet in $withval" >&6;}
- fi
-
-fi;
+LIBNET_CONFIG="libnet11-config" # relative, using $PATH
+CPPFLAGS="$CPPFLAGS $(${LIBNET_CONFIG} --cflags)"
+LDFLAGS="$LDFLAGS $(${LIBNET_CONFIG} --libs)"
+
+## Check whether --with-libnet or --without-libnet was given.
+#if test "${with_libnet+set}" = set; then
+# withval="$with_libnet"
+#
+# LIBNETCC=""
+# LIBNETLD=""
+#
+# test -x "$withval/bin/libnet-config" && LIBNET_CONFIG="$withval/bin/libnet-config"
+# test -x "$withval/libnet-config" && LIBNET_CONFIG="$withval/libnet-config"
+#
+# test -f "$withval/libnet.h" && LIBNETCC="$LIBNETCC -I$withval"
+# test -f "$withval/include/libnet.h" && LIBNETCC="$LIBNETCC -I$withval/include"
+#
+# test -f "$withval/libnet.a" && LIBNETLD="$LIBNETLD -L$withval"
+# test -f "$withval/lib/libnet.a" && LIBNETLD="$LIBNETLD -L$withval/lib"
+#
+# if test -z "$LIBNETCC" -o -z "$LIBNETLD"
+# then
+# { { echo "$as_me:$LINENO: error: No valid libnet library found in $withval" >&5
+#echo "$as_me: error: No valid libnet library found in $withval" >&2;}
+# { (exit 1); exit 1; }; }
+# else
+# CPPFLAGS="$CPPFLAGS $LIBNETCC"
+# LDFLAGS="$LDFLAGS $LIBNETLD"
+# { echo "$as_me:$LINENO: using libnet in $withval" >&5
+#echo "$as_me: using libnet in $withval" >&6;}
+# fi
+#
+#fi;
echo "$as_me:$LINENO: checking for pcap_open_live in -lpcap" >&5

View file

@ -1,26 +0,0 @@
--- tcptraceroute.c.orig Tue Oct 7 16:04:50 2003
+++ tcptraceroute.c Tue Oct 7 16:05:22 2003
@@ -391,9 +391,9 @@
void usage(void)
{
printf("\n%s\n%s\n", VERSION, BANNER);
- fatal("Usage: %s [-nNFSAE] [-i <interface>] [-f <first ttl>]
- [-l <packet length>] [-q <number of queries>] [-t <tos>]
- [-m <max ttl>] [-pP] <source port>] [-s <source address>]
+ fatal("Usage: %s [-nNFSAE] [-i <interface>] [-f <first ttl>] \
+ [-l <packet length>] [-q <number of queries>] [-t <tos>] \
+ [-m <max ttl>] [-pP] <source port>] [-s <source address>] \
[-w <wait time>] <host> [destination port] [packet length]\n\n", name);
}
@@ -1182,8 +1182,8 @@
if (! (pcap = pcap_open_live(device, offset + SNAPLEN, 0, 10, errbuf)))
fatal("pcap_open_live failed: %s", errbuf);
- safe_snprintf(filter, TEXTSIZE, "
- (tcp and src host %s and src port %d and dst host %s)
+ safe_snprintf(filter, TEXTSIZE, " \
+ (tcp and src host %s and src port %d and dst host %s) \
or ((icmp[0] == 11 or icmp[0] == 3) and dst host %s)",
iptos(dst_ip), dst_prt, iptos(src_ip), iptos(src_ip));

View file

@ -1,18 +1,17 @@
tcptraceroute is a traceroute implementation using TCP packets. tcptraceroute is a traceroute implementation using TCP packets.
The more traditional traceroute(8) sends out either UDP or ICMP ECHO The more traditional traceroute(8) sends out either UDP or ICMP ECHO packets
packets with a TTL of one, and increments the TTL until the destination with a TTL of one, and increments the TTL until the destination has been
has been reached. By printing the gateways that generate ICMP time reached. By printing the gateways that generate ICMP time exceeded messages
exceeded messages along the way, it is able to determine the path along the way, it is able to determine the path packets are taking to reach the
packets are taking to reach the destination. destination.
The problem is that with the widespread use of firewalls on the modern The problem is that with the widespread use of firewalls on the modern Internet,
Internet, many of the packets that traceroute(8) sends out end up being many of the packets that traceroute(8) sends out end up being filtered, making
filtered, making it impossible to completely trace the path to the it impossible to completely trace the path to the destination. However, in many
destination. However, in many cases, these firewalls will permit inbound cases, these firewalls will permit inbound TCP packets to specific ports that
TCP packets to specific ports that hosts sitting behind the firewall are hosts sitting behind the firewall are listening for connections on. By sending
listening for connections on. By sending out TCP SYN packets instead of out TCP SYN packets instead of UDP or ICMP ECHO packets, tcptraceroute is able
UDP or ICMP ECHO packets, tcptraceroute is able to bypass the most to bypass the most common firewall filters.
common firewall filters.
WWW: https://github.com/mct/tcptraceroute WWW: https://github.com/mct/tcptraceroute

View file

@ -1,4 +1,2 @@
man/man8/tcptraceroute.8.gz @(root,wheel,4555) bin/tcptraceroute
@mode 4555 man/man1/tcptraceroute.1.gz
sbin/tcptraceroute
@mode