Index: head/net/packetdrill/pkg-plist =================================================================== --- head/net/packetdrill/pkg-plist (revision 423743) +++ head/net/packetdrill/pkg-plist (nonexistent) @@ -1,4 +0,0 @@ -bin/packetdrill -bin/checksum_test -bin/packet_parser_test -bin/packet_to_string_test Property changes on: head/net/packetdrill/pkg-plist ___________________________________________________________________ Deleted: fbsd:nokeywords ## -1 +0,0 ## -yes \ No newline at end of property Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property Index: head/net/packetdrill/Makefile =================================================================== --- head/net/packetdrill/Makefile (revision 423743) +++ head/net/packetdrill/Makefile (revision 423744) @@ -1,53 +1,44 @@ # $FreeBSD$ PORTNAME= packetdrill -PORTVERSION= 0.0.20130820 +PORTVERSION= 0.0.20161001 CATEGORIES= net ipv6 -MASTER_SITES= LOCAL/hrs -DISTNAME= ${PORTNAME}-ea8f2fec724d -MAINTAINER= hrs@FreeBSD.org +MAINTAINER= gnn@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 " "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 post-install: @${MKDIR} ${STAGEDIR}${DATADIR} cd ${WRKSRC}/contrib && ${INSTALL_DATA} ${PORTDATA} \ ${STAGEDIR}${DATADIR} 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} .include Index: head/net/packetdrill/distinfo =================================================================== --- head/net/packetdrill/distinfo (revision 423743) +++ head/net/packetdrill/distinfo (revision 423744) @@ -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 Index: head/net/packetdrill/files/Makefile.packet_to_string_test =================================================================== --- head/net/packetdrill/files/Makefile.packet_to_string_test (revision 423743) +++ head/net/packetdrill/files/Makefile.packet_to_string_test (nonexistent) @@ -1,5 +0,0 @@ -# $FreeBSD$ - -PROG= packet_to_string_test - -.include Property changes on: head/net/packetdrill/files/Makefile.packet_to_string_test ___________________________________________________________________ Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:keywords ## -1 +0,0 ## -FreeBSD=%H \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property Index: head/net/packetdrill/files/Makefile.checksum_test =================================================================== --- head/net/packetdrill/files/Makefile.checksum_test (revision 423743) +++ head/net/packetdrill/files/Makefile.checksum_test (nonexistent) @@ -1,5 +0,0 @@ -# $FreeBSD$ - -PROG= checksum_test - -.include Property changes on: head/net/packetdrill/files/Makefile.checksum_test ___________________________________________________________________ Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:keywords ## -1 +0,0 ## -FreeBSD=%H \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property Index: head/net/packetdrill/files/Makefile.packet_parser_test =================================================================== --- head/net/packetdrill/files/Makefile.packet_parser_test (revision 423743) +++ head/net/packetdrill/files/Makefile.packet_parser_test (nonexistent) @@ -1,5 +0,0 @@ -# $FreeBSD$ - -PROG= packet_parser_test - -.include Property changes on: head/net/packetdrill/files/Makefile.packet_parser_test ___________________________________________________________________ Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:keywords ## -1 +0,0 ## -FreeBSD=%H \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property Index: head/net/packetdrill/files/Makefile =================================================================== --- head/net/packetdrill/files/Makefile (revision 423743) +++ head/net/packetdrill/files/Makefile (revision 423744) @@ -1,5 +1,5 @@ # $FreeBSD$ -SUBDIR= libpd packetdrill checksum_test packet_parser_test packet_to_string_test +SUBDIR= libpd packetdrill .include Index: head/net/packetdrill/files/Makefile.inc =================================================================== --- head/net/packetdrill/files/Makefile.inc (revision 423743) +++ head/net/packetdrill/files/Makefile.inc (revision 423744) @@ -1,11 +1,12 @@ # $FreeBSD$ PREFIX?= /usr/local BINDIR?= ${PREFIX}/bin 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 Index: head/net/packetdrill/files/Makefile.libpd =================================================================== --- head/net/packetdrill/files/Makefile.libpd (revision 423743) +++ head/net/packetdrill/files/Makefile.libpd (revision 423744) @@ -1,28 +1,30 @@ # $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}/.. parser.c: parser.y bison --output=${.TARGET} --defines=parser.h --report=state ${.IMPSRC} lexer.c: parser.c CLEANFILES= parser.h parser.c parser.output lexer.c install: .include Index: head/net/packetdrill/files/patch-platforms.h =================================================================== --- head/net/packetdrill/files/patch-platforms.h (revision 423743) +++ head/net/packetdrill/files/patch-platforms.h (revision 423744) @@ -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 @@ +--- platforms.h.orig 2016-10-01 08:55:57 UTC ++++ platforms.h +@@ -50,11 +50,12 @@ - #if defined(__FreeBSD__) - + #include + #include +#include + #if __FreeBSD_version >= 1001000 + #include + #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 Index: head/net/packetdrill/files/patch-symbols_freebsd.c =================================================================== --- head/net/packetdrill/files/patch-symbols_freebsd.c (revision 423743) +++ head/net/packetdrill/files/patch-symbols_freebsd.c (revision 423744) @@ -1,22 +1,22 @@ ---- 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" }, +#ifdef SO_USER_COOKIE { 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" }, +#ifdef ECAPMODE { ECAPMODE, "ECAPMODE" }, +#endif - }; - + /* Sentinel marking the end of the table. */ + { 0, NULL }, Index: head/net/packetdrill/pkg-descr =================================================================== --- head/net/packetdrill/pkg-descr (revision 423743) +++ head/net/packetdrill/pkg-descr (revision 423744) @@ -1,8 +1,9 @@ The packetdrill scripting tool enables quick, precise tests for entire TCP/UDP/IPv4/IPv6 network stacks, from the system call layer down to the NIC hardware. packetdrill currently works on Linux, FreeBSD, OpenBSD, and NetBSD. It can test network stack behavior over physical 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