svn commit: r349476 - in head/net/anet: . files

John Marino marino at FreeBSD.org
Sat Mar 29 01:22:56 UTC 2014


Author: marino
Date: Sat Mar 29 01:22:55 2014
New Revision: 349476
URL: http://svnweb.freebsd.org/changeset/ports/349476
QAT: https://qat.redports.org/buildarchive/r349476/

Log:
  net/anet: Fix build for gcc 4.9 and fix documentation too
  
  Reported by:	pkg-fallout

Modified:
  head/net/anet/Makefile
  head/net/anet/files/patch-src_anet-sockets-inet.adb
  head/net/anet/files/patch-src_anet-sockets.ads
  head/net/anet/pkg-plist

Modified: head/net/anet/Makefile
==============================================================================
--- head/net/anet/Makefile	Sat Mar 29 00:52:54 2014	(r349475)
+++ head/net/anet/Makefile	Sat Mar 29 01:22:55 2014	(r349476)
@@ -3,7 +3,7 @@
 
 PORTNAME=	anet
 PORTVERSION=	0.2.3
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	net
 MASTER_SITES=	http://www.codelabs.ch/download/
 DISTNAME=	libanet-${PORTVERSION}
@@ -20,7 +20,7 @@ ALL_TARGET=	build_lib
 MAKE_ARGS+=	NUM_CPUS=${MAKE_JOBS_NUMBER} \
 		LIBRARY_KIND=static
 
-OPTIONS_DEFINE=	TEST #DOCS
+OPTIONS_DEFINE=	TEST DOCS
 TEST_DESC=	Run unit test suite before installation
 
 .include <bsd.port.options.mk>
@@ -34,12 +34,12 @@ BUILD_DEPENDS+=	${LOCALBASE}/lib/gnat/ah
 ALL_TARGET+=	tests
 .endif
 
-# DOCS disabled -- asciidoc generation missing source highlights
-#.if ${PORT_OPTIONS:MDOCS}
-#BUILD_DEPENDS+= asciidoc:${PORTSDIR}/textproc/asciidoc
-#ALL_TARGET+=	doc
-#USES+=		gmake
-#.endif
+.if ${PORT_OPTIONS:MDOCS}
+BUILD_DEPENDS+= asciidoc:${PORTSDIR}/textproc/asciidoc \
+		source-highlight:${PORTSDIR}/textproc/source-highlight
+ALL_TARGET+=	doc
+USES+=		gmake
+.endif
 
 post-patch:
 	@${REINPLACE_CMD} -e 's|"lo"|"lo0"|g' \
@@ -64,5 +64,9 @@ do-install:
 		${STAGEDIR}${PREFIX}/include/anet
 	${INSTALL_DATA} ${WRKSRC}/lib/static/* ${STAGEDIR}${PREFIX}/lib/anet
 	${INSTALL_DATA} ${WRKSRC}/gnat/anet.gpr ${STAGEDIR}${PREFIX}/lib/gnat
+.if ${PORT_OPTIONS:MDOCS}
+	${MKDIR} ${STAGEDIR}${DOCSDIR}
+	(cd ${WRKSRC}/doc && ${COPYTREE_SHARE} html ${STAGEDIR}${DOCSDIR})
+.endif
 
 .include <bsd.port.mk>

Modified: head/net/anet/files/patch-src_anet-sockets-inet.adb
==============================================================================
--- head/net/anet/files/patch-src_anet-sockets-inet.adb	Sat Mar 29 00:52:54 2014	(r349475)
+++ head/net/anet/files/patch-src_anet-sockets-inet.adb	Sat Mar 29 01:22:55 2014	(r349476)
@@ -127,7 +127,7 @@
                Sin_Family => Constants.Sys.AF_INET6,
                Sin_Port   => C.unsigned_short
                  (Byte_Swapping.Host_To_Network (Input => Port)),
-@@ -253,6 +261,51 @@ package body Anet.Sockets.Inet is
+@@ -253,6 +261,52 @@ package body Anet.Sockets.Inet is
  
     -------------------------------------------------------------------------
  
@@ -157,7 +157,8 @@
 +               Interfaces.C.Strings.Value (frame.all.ifa_name);
 +         begin
 +            if testname = String (Iface_Name) and then
-+              frame.all.ifa_addr.all.Sin_Family = Constants.Sys.AF_INET6 then
++              frame.all.ifa_addr.all.Sin_Family = Constants.Sys.AF_INET6
++            then
 +               found := True;
 +               IPv6_Address := frame.all.ifa_addr.all.Sin6_Addr;
 +            end if;
@@ -179,7 +180,7 @@
     procedure Init (Socket : in out UDPv4_Socket_Type)
     is
     begin
-@@ -301,15 +354,15 @@ package body Anet.Sockets.Inet is
+@@ -301,15 +355,15 @@ package body Anet.Sockets.Inet is
        use type C.unsigned_short;
  
        Mreq      : Thin.IPv4_Mreq_Type;
@@ -198,7 +199,7 @@
  
        Res := Thin.C_Setsockopt
          (S       => Socket.Sock_FD,
-@@ -335,10 +388,14 @@ package body Anet.Sockets.Inet is
+@@ -335,10 +389,14 @@ package body Anet.Sockets.Inet is
  
        Mreq6     : Thin.IPv6_Mreq_Type;
        Iface_Idx : Natural := 0;
@@ -214,7 +215,7 @@
        end if;
  
        Mreq6.IPv6mr_Multiaddr := Group;
-@@ -349,7 +406,7 @@ package body Anet.Sockets.Inet is
+@@ -349,7 +407,7 @@ package body Anet.Sockets.Inet is
           Level   => Constants.IPPROTO_IPV6,
           Optname => Constants.IPV6_ADD_MEMBERSHIP,
           Optval  => Mreq6'Address,
@@ -223,7 +224,7 @@
  
        if Res = C_Failure then
           raise Socket_Error with "Unable to join multicast group "
-@@ -440,7 +497,8 @@ package body Anet.Sockets.Inet is
+@@ -440,7 +498,8 @@ package body Anet.Sockets.Inet is
        Dst_Addr : IPv4_Addr_Type;
        Dst_Port : Port_Type)
     is
@@ -233,7 +234,7 @@
        Dst : constant Thin.Sockaddr_In_Type := Create_Inet4
          (Address => Dst_Addr,
           Port    => Dst_Port);
-@@ -450,7 +508,7 @@ package body Anet.Sockets.Inet is
+@@ -450,7 +509,7 @@ package body Anet.Sockets.Inet is
                              Len   => Item'Length,
                              Flags => 0,
                              To    => Dst'Address,
@@ -242,7 +243,7 @@
  
        if Res = C_Failure then
           raise Socket_Error with "Error sending data to "
-@@ -473,7 +531,8 @@ package body Anet.Sockets.Inet is
+@@ -473,7 +532,8 @@ package body Anet.Sockets.Inet is
        Dst_Addr : IPv6_Addr_Type;
        Dst_Port : Port_Type)
     is
@@ -252,7 +253,7 @@
        Dst : constant Thin.Sockaddr_In_Type := Create_Inet6
          (Address => Dst_Addr,
           Port    => Dst_Port);
-@@ -483,7 +542,7 @@ package body Anet.Sockets.Inet is
+@@ -483,7 +543,7 @@ package body Anet.Sockets.Inet is
                              Len   => Item'Length,
                              Flags => 0,
                              To    => Dst'Address,

Modified: head/net/anet/files/patch-src_anet-sockets.ads
==============================================================================
--- head/net/anet/files/patch-src_anet-sockets.ads	Sat Mar 29 00:52:54 2014	(r349475)
+++ head/net/anet/files/patch-src_anet-sockets.ads	Sat Mar 29 01:22:55 2014	(r349476)
@@ -6,7 +6,7 @@
  
 +   procedure Set_Multicast_Interface
 +     (Socket : Socket_Type;
-+      IPAddr : IPv4_Addr_type);
++      IPAddr : IPv4_Addr_Type);
 +   --  Set multicast interface socket option for IPv4
 +
 +   procedure Set_Multicast_Interface

Modified: head/net/anet/pkg-plist
==============================================================================
--- head/net/anet/pkg-plist	Sat Mar 29 00:52:54 2014	(r349475)
+++ head/net/anet/pkg-plist	Sat Mar 29 01:22:55 2014	(r349476)
@@ -58,6 +58,10 @@ lib/anet/anet-util.ali
 lib/anet/anet.ali
 lib/anet/libanet.a
 lib/gnat/anet.gpr
+%%PORTDOCS%%%%DOCSDIR%%/html/asciidoc.css
+%%PORTDOCS%%%%DOCSDIR%%/html/index.html
+%%PORTDOCS%%@dirrmtry %%DOCSDIR%%/html
+%%PORTDOCS%%@dirrmtry %%DOCSDIR%%
 @dirrmtry lib/gnat
 @dirrm lib/anet
 @dirrm include/anet


More information about the svn-ports-head mailing list