svn commit: r380835 - in head/net/netselect: . files

Mikhail Teterin mi at FreeBSD.org
Mon Mar 9 06:48:14 UTC 2015


Author: mi
Date: Mon Mar  9 06:48:12 2015
New Revision: 380835
URL: https://svnweb.freebsd.org/changeset/ports/380835
QAT: https://qat.redports.org/buildarchive/r380835/

Log:
  Unbreak -- seems to work for me, no errors quoted in the BROKEN-message
  appear. While here resolve a worning and arrange for installing the
  author's README-file, if DOCS-option is on.

Modified:
  head/net/netselect/Makefile
  head/net/netselect/files/patch-netselect.c
  head/net/netselect/pkg-plist

Modified: head/net/netselect/Makefile
==============================================================================
--- head/net/netselect/Makefile	Mon Mar  9 06:21:47 2015	(r380834)
+++ head/net/netselect/Makefile	Mon Mar  9 06:48:12 2015	(r380835)
@@ -12,18 +12,24 @@ COMMENT=	Ultrafast implementation of pin
 
 LICENSE=	BSD3CLAUSE
 
-BROKEN=		Does not work (sendto: Invalid argument)
-
-OPTIONS_DEFINE=	SUID
+OPTIONS_DEFINE=	SUID DOCS
 OPTIONS_SUB=	yes
-SUID_DESC=	Install with the setuid bit (mode 4110)
+SUID_DESC=	Install with the setuid bit to allow use by non-root users
+EXTRACT_AFTER_ARGS=netselect/netselect.c netselect/README
 
 WRKSRC=		${WRKDIR}/${PORTNAME}
 
 do-build:
 	${CC} ${CFLAGS} -o ${WRKSRC}/${PORTNAME} ${WRKSRC}/${PORTNAME}.c
+	${REINPLACE_CMD} -E -i "" -e 's|[[:blank:]]+$$||' ${WRKSRC}/README
+
+.include <bsd.port.options.mk>
 
 do-install:
 	${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin
+.if ${PORT_OPTIONS:MDOCS}
+	${MKDIR} ${STAGEDIR}${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/README ${STAGEDIR}${DOCSDIR}
+.endif
 
 .include <bsd.port.mk>

Modified: head/net/netselect/files/patch-netselect.c
==============================================================================
--- head/net/netselect/files/patch-netselect.c	Mon Mar  9 06:21:47 2015	(r380834)
+++ head/net/netselect/files/patch-netselect.c	Mon Mar  9 06:48:12 2015	(r380835)
@@ -1,5 +1,5 @@
---- netselect.c.orig	2006-07-14 22:59:18.000000000 +0200
-+++ netselect.c	2006-07-14 22:57:22.000000000 +0200
+--- netselect.c	2001-08-29 05:18:57.000000000 -0400
++++ netselect.c	2015-03-09 02:31:02.000000000 -0400
 @@ -39,14 +39,13 @@
   * hey, great!  Let me know. -- apenwarr
   */
@@ -53,3 +53,18 @@
      ip->ip_ttl = ttl;
      ip->ip_v = IPVERSION;
      ip->ip_id = htons(ident + seq);
+@@ -771,12 +776,8 @@
+     int cc = 0;
+     time_t msec_used;
+     HostData *host;
+-    
+-#if !defined(__GLIBC__)
+-    int fromlen = sizeof(from);
+-#else				/* __GLIBC__ */
+-    size_t fromlen = sizeof(from);
+-#endif				/* __GLIBC__ */
++ 
++    socklen_t fromlen = sizeof(from);
+ 
+     FD_ZERO(&fds);
+     FD_SET(sock, &fds);

Modified: head/net/netselect/pkg-plist
==============================================================================
--- head/net/netselect/pkg-plist	Mon Mar  9 06:21:47 2015	(r380834)
+++ head/net/netselect/pkg-plist	Mon Mar  9 06:48:12 2015	(r380835)
@@ -1,2 +1,3 @@
 %%SUID%%@(root,wheel,4110) bin/netselect
 %%NO_SUID%%@(root,wheel,100) bin/netselect
+%%PORTDOCS%%%%DOCSDIR%%/README


More information about the svn-ports-head mailing list