svn commit: r423744 - in head/net/packetdrill: . files
Hiroki Sato
hrs at FreeBSD.org
Tue Oct 11 03:12:05 UTC 2016
Author: hrs
Date: Tue Oct 11 03:12:03 2016
New Revision: 423744
URL: https://svnweb.freebsd.org/changeset/ports/423744
Log:
- Update to use freebsd-net/packetdrill repository instead of
Google's one. It includes various fixes for FreeBSD and has been
maintained by FreeBSD developers.
- Drop binaries for testing.
- Set maintainership to gnn at .
Discussed with: tuexen and gnn
Deleted:
head/net/packetdrill/files/Makefile.checksum_test
head/net/packetdrill/files/Makefile.packet_parser_test
head/net/packetdrill/files/Makefile.packet_to_string_test
head/net/packetdrill/pkg-plist
Modified:
head/net/packetdrill/Makefile
head/net/packetdrill/distinfo
head/net/packetdrill/files/Makefile
head/net/packetdrill/files/Makefile.inc
head/net/packetdrill/files/Makefile.libpd
head/net/packetdrill/files/patch-platforms.h
head/net/packetdrill/files/patch-symbols_freebsd.c
head/net/packetdrill/pkg-descr
Modified: head/net/packetdrill/Makefile
==============================================================================
--- head/net/packetdrill/Makefile Tue Oct 11 02:54:31 2016 (r423743)
+++ head/net/packetdrill/Makefile Tue Oct 11 03:12:03 2016 (r423744)
@@ -1,37 +1,29 @@
# $FreeBSD$
PORTNAME= packetdrill
-PORTVERSION= 0.0.20130820
+PORTVERSION= 0.0.20161001
CATEGORIES= net ipv6
-MASTER_SITES= LOCAL/hrs
-DISTNAME= ${PORTNAME}-ea8f2fec724d
-MAINTAINER= hrs at FreeBSD.org
+MAINTAINER= gnn at FreeBSD.org
COMMENT= Network stack testing tool
LICENSE= GPLv2
USES= bison uidfix
+USE_GITHUB= yes
+GH_ACCOUNT= freebsd-net
+GH_TAGNAME= 467b39b
+WRKSRC= ${WRKDIR}/${PORTNAME}-${GH_TAGNAME}/gtests/net/packetdrill
+PLIST_FILES= bin/${PORTNAME}
PORTDATA= packetdrill.el packetdrill.vim
PORTDOCS= README
PORTEXAMPLES= tests
OPTIONS_DEFINE= DOCS EXAMPLES
-do-configure:
- ${PRINTF} "%s\n" "#include <stdio.h>" "int main(void) {" \
- "char *p = fmemopen; char *q = open_memstream; return 0; }" \
- > ${WRKDIR}/configure.c
- ${TOUCH} ${WRKSRC}/ports_config.h
- cd ${WRKDIR} && \
- if ${CC} -o /dev/null configure.c > /dev/null 2>&1; then \
- ${PRINTF} "%s\n" "#define HAVE_FMEMOPEN 1" \
- "#define HAVE_OPEN_MEMSTREAM 1" > ${WRKSRC}/ports_config.h; \
- fi
-
pre-build:
${INSTALL_DATA} ${FILESDIR}/Makefile ${FILESDIR}/Makefile.inc ${WRKSRC}
-.for F in libpd packetdrill checksum_test packet_parser_test packet_to_string_test
+.for F in libpd packetdrill
${MKDIR} ${WRKSRC}/${F}
${INSTALL_DATA} ${FILESDIR}/Makefile.${F} ${WRKSRC}/${F}/Makefile
.endfor
@@ -45,7 +37,6 @@ post-install-EXAMPLES-on:
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
cd ${WRKSRC} && ${COPYTREE_SHARE} ${PORTEXAMPLES} \
${STAGEDIR}${EXAMPLESDIR}
-
post-install-DOCS-on:
@${MKDIR} ${STAGEDIR}${DOCSDIR}
cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${STAGEDIR}${DOCSDIR}
Modified: head/net/packetdrill/distinfo
==============================================================================
--- head/net/packetdrill/distinfo Tue Oct 11 02:54:31 2016 (r423743)
+++ head/net/packetdrill/distinfo Tue Oct 11 03:12:03 2016 (r423744)
@@ -1,3 +1,3 @@
-TIMESTAMP = 1475852995
-SHA256 (packetdrill-ea8f2fec724d.tar.gz) = f07c46f4adfd273f09c0bb98e0eadef83d8d13b080d2c9f5a59c6fd91120aa2b
-SIZE (packetdrill-ea8f2fec724d.tar.gz) = 146043
+TIMESTAMP = 1475877519
+SHA256 (freebsd-net-packetdrill-0.0.20161001-467b39b_GH0.tar.gz) = c5d948d2d56c829dbba95eefcc3f10fcac77f32b70c059de23b37aab968b47f5
+SIZE (freebsd-net-packetdrill-0.0.20161001-467b39b_GH0.tar.gz) = 316573
Modified: head/net/packetdrill/files/Makefile
==============================================================================
--- head/net/packetdrill/files/Makefile Tue Oct 11 02:54:31 2016 (r423743)
+++ head/net/packetdrill/files/Makefile Tue Oct 11 03:12:03 2016 (r423744)
@@ -1,5 +1,5 @@
# $FreeBSD$
-SUBDIR= libpd packetdrill checksum_test packet_parser_test packet_to_string_test
+SUBDIR= libpd packetdrill
.include <bsd.subdir.mk>
Modified: head/net/packetdrill/files/Makefile.inc
==============================================================================
--- head/net/packetdrill/files/Makefile.inc Tue Oct 11 02:54:31 2016 (r423743)
+++ head/net/packetdrill/files/Makefile.inc Tue Oct 11 03:12:03 2016 (r423744)
@@ -8,4 +8,5 @@ MAN=
.PATH: ${.CURDIR}/..
CFLAGS+= -I${.CURDIR}/.. -I${.CURDIR}
-LDADD= ${.CURDIR}/../libpd/libpd.a -lpthread -lpcap
+LDADD= ${.CURDIR}/../libpd/libpd.a -lprocstat -lutil \
+ -lkvm -lelf -lpthread -lpcap
Modified: head/net/packetdrill/files/Makefile.libpd
==============================================================================
--- head/net/packetdrill/files/Makefile.libpd Tue Oct 11 02:54:31 2016 (r423743)
+++ head/net/packetdrill/files/Makefile.libpd Tue Oct 11 03:12:03 2016 (r423744)
@@ -1,18 +1,20 @@
# $FreeBSD$
LIB= pd
-SRCS= checksum.c code.c config.c hash.c hash_map.c \
- ip_address.c netdev.c net_utils.c packet.c \
+SRCS= checksum.c code.c config.c hash.c hash_map.c ip_address.c \
+ ip_prefix.c netdev.c net_utils.c packet.c \
packet_socket_linux.c packet_socket_pcap.c packet_checksum.c \
packet_parser.c packet_to_string.c symbols_linux.c \
symbols_freebsd.c symbols_openbsd.c symbols_netbsd.c \
- icmp_packet.c ip_packet.c tcp_packet.c udp_packet.c run.c \
- run_command.c run_packet.c run_system_call.c script.c \
- socket.c system.c tcp_options.c tcp_options_iterator.c \
- tcp_options_to_string.c logging.c types.c lexer.c parser.c \
- fmemopen.c open_memstream.c link_layer.c wire_conn.c \
- wire_protocol.c wire_client.c wire_client_netdev.c \
- wire_server.c wire_server_netdev.c
+ gre_packet.c icmp_packet.c ip_packet.c sctp_packet.c \
+ tcp_packet.c udp_packet.c udplite_packet.c mpls_packet.c \
+ run.c run_command.c run_packet.c run_system_call.c script.c \
+ socket.c system.c sctp_chunk_to_string.c sctp_iterator.c \
+ tcp_options.c tcp_options_iterator.c tcp_options_to_string.c \
+ logging.c types.c lexer.c parser.c fmemopen.c \
+ open_memstream.c link_layer.c wire_conn.c wire_protocol.c \
+ wire_client.c wire_client_netdev.c wire_server.c \
+ wire_server_netdev.c
.PATH: ${.CURDIR}/..
Modified: head/net/packetdrill/files/patch-platforms.h
==============================================================================
--- head/net/packetdrill/files/patch-platforms.h Tue Oct 11 02:54:31 2016 (r423743)
+++ head/net/packetdrill/files/patch-platforms.h Tue Oct 11 03:12:03 2016 (r423744)
@@ -1,18 +1,16 @@
---- platforms.h.orig 2013-07-21 04:53:41.000000000 +0900
-+++ platforms.h 2013-09-04 10:34:56.000000000 +0900
-@@ -43,12 +43,14 @@
-
- #if defined(__FreeBSD__)
+--- platforms.h.orig 2016-10-01 08:55:57 UTC
++++ platforms.h
+@@ -50,11 +50,12 @@
+ #include <netinet/sctp.h>
+ #include <sys/param.h>
+#include <paths.h>
+ #if __FreeBSD_version >= 1001000
+ #include <netinet/udplite.h>
+ #endif
#define USE_LIBPCAP 1
-#define TUN_PATH "/dev/tun0"
+#define TUN_PATH _PATH_DEV "tun0"
#define TUN_DEV "tun0"
-
#define HAVE_TCP_INFO 1
-
-+#include "ports_config.h"
- #include "open_memstream.h"
- #include "fmemopen.h"
-
+ #if (__FreeBSD_version < 1000000 && __FreeBSD_version > 902000) || __FreeBSD_version > 1000028
Modified: head/net/packetdrill/files/patch-symbols_freebsd.c
==============================================================================
--- head/net/packetdrill/files/patch-symbols_freebsd.c Tue Oct 11 02:54:31 2016 (r423743)
+++ head/net/packetdrill/files/patch-symbols_freebsd.c Tue Oct 11 03:12:03 2016 (r423744)
@@ -1,6 +1,6 @@
---- symbols_freebsd.c.orig 2013-09-04 15:08:25.000000000 +0900
-+++ symbols_freebsd.c 2013-09-04 15:08:28.000000000 +0900
-@@ -76,7 +76,9 @@
+--- symbols_freebsd.c.orig 2016-10-01 08:55:57 UTC
++++ symbols_freebsd.c
+@@ -76,7 +76,9 @@ struct int_symbol platform_symbols_table
{ SO_LISTENQLEN, "SO_LISTENQLEN" },
{ SO_LISTENINCQLEN, "SO_LISTENINCQLEN" },
{ SO_SETFIB, "SO_SETFIB" },
@@ -8,9 +8,9 @@
{ SO_USER_COOKIE, "SO_USER_COOKIE" },
+#endif
- /* /usr/include/netinet/tcp.h */
- { TCP_NODELAY, "TCP_NODELAY" },
-@@ -296,7 +298,9 @@
+ /* /usr/include/netinet/sctp.h and /usr/include/netinet/sctp_uio.h */
+ { SCTP_RTOINFO, "SCTP_RTOINFO" },
+@@ -525,7 +527,9 @@ struct int_symbol platform_symbols_table
{ ENOLINK, "ENOLINK" },
{ EPROTO, "EPROTO" },
{ ENOTCAPABLE, "ENOTCAPABLE" },
@@ -18,5 +18,5 @@
{ ECAPMODE, "ECAPMODE" },
+#endif
- };
-
+ /* Sentinel marking the end of the table. */
+ { 0, NULL },
Modified: head/net/packetdrill/pkg-descr
==============================================================================
--- head/net/packetdrill/pkg-descr Tue Oct 11 02:54:31 2016 (r423743)
+++ head/net/packetdrill/pkg-descr Tue Oct 11 03:12:03 2016 (r423744)
@@ -5,4 +5,5 @@ OpenBSD, and NetBSD. It can test network
NICs on a LAN, or on a single machine using a tun virtual network
device.
-WWW: https://code.google.com/p/packetdrill/
+WWW: https://github.com/google/packetdrill
+WWW: https://github.com/freebsd-net/packetdrill
More information about the svn-ports-all
mailing list