misc/133152: net-mgmt/net-snmp: fails building on recent -CURRENT

Scot Hetzel swhetzel at gmail.com
Sat Mar 28 00:50:03 PDT 2009


>Number:         133152
>Category:       misc
>Synopsis:       net-mgmt/net-snmp: fails building on recent -CURRENT
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Mar 28 07:50:02 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator:     Scot Hetzel
>Release:        8.0-CURRENT
>Organization:
>Environment:
FreeBSD hp010.hetzel.org 8.0-CURRENT FreeBSD 8.0-CURRENT #6: Tue Mar 24 05:47:19 CDT 2009     root at hp010.hetzel.org:/usr/obj/usr/src/sys/DV8135NR  amd64
>Description:
The port fails to build since the change to remove several in6p_* macros from f sys/netinet/in_pcb.h (SVN rev 189637).
>How-To-Repeat:
Install a recent 8.0-CURRENT system >= SVN rev 189637
cd /usr/ports/net-mgmt/net-snmp
make build

 cc -I../../include -I. -I../../agent -I../../agent/mibgroup -I../../snmplib -DNETSNMP_ENABLE_IPV6 -O2 -pipe -fno-strict-aliasing -Ufreebsd8 -Dfreebsd8=freebsd8 -DAPPLLIB_EXP=/usr/local/lib/perl5/5.8.9/BSDPAN -DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -fno-strict-aliasing -pipe -I/usr/local/include -I/usr/local/lib/perl5/5.8.9/mach/CORE -c mibII/ipv6.c  -fPIC -DPIC -o mibII/.libs/ipv6.o
mibII/ipv6.c: In function 'var_udp6':
mibII/ipv6.c:1335: error: 'struct inpcb' has no member named 'in6p_lport'
mibII/ipv6.c:1399: error: 'struct inpcb' has no member named 'in6p_lport'
mibII/ipv6.c: In function 'var_tcp6':
mibII/ipv6.c:1745: error: 'struct inpcb' has no member named 'in6p_ppcb'
mibII/ipv6.c:1746: error: 'struct inpcb' has no member named 'in6p_ppcb'
mibII/ipv6.c:1746: error: 'struct inpcb' has no member named 'in6p_ppcb'
mibII/ipv6.c:1754: error: 'struct inpcb' has no member named 'in6p_lport'
mibII/ipv6.c:1757: error: 'struct inpcb' has no member named 'in6p_fport'
mibII/ipv6.c:1771: error: 'struct inpcb' has no member named 'in6p_lport'
mibII/ipv6.c:1826: error: 'struct inpcb' has no member named 'in6p_lport'
mibII/ipv6.c:1832: error: 'struct inpcb' has no member named 'in6p_fport'
gmake[2]: *** [mibII/ipv6.lo] Error 1
gmake[2]: Leaving directory `/usr/ports/net-mgmt/net-snmp/work/net-snmp-5.4.2.1/agent/mibgroup'
gmake[1]: *** [subdirs] Error 1
gmake[1]: Leaving directory `/usr/ports/net-mgmt/net-snmp/work/net-snmp-5.4.2.1/agent'
gmake: *** [subdirs] Error 1

>Fix:
Apply the attached patch.

Note: These macros were removed a day after __FreeBSD_version was bumped to 800070 in sys/param.h, thus the patch also checks that in6p_lport is not defined.

Patch attached with submission follows:

--- agent/mibgroup/mibII/ipv6.c.orig	2009-03-28 01:27:21.421079000 -0500
+++ agent/mibgroup/mibII/ipv6.c	2009-03-28 02:24:35.225537715 -0500
@@ -166,6 +166,15 @@
 static int if_getindex (const char *);
 #endif
 
+/* These macros were removed in SVN rev 189637 of sys/netinet/in_pcb.h */
+#if __FreeBSD_version >= 800070
+#ifndef in6p_lport
+#define in6p_lport	inp_lport
+#define in6p_fport	inp_fport
+#define in6p_ppcb	inp_ppcb
+#endif
+#endif
+
 struct variable3 ipv6_variables[] = {
     {IPV6FORWARDING, ASN_INTEGER, RONLY, var_ipv6, 1, {1}},
     {IPV6DEFAULTHOPLIMIT, ASN_INTEGER, RONLY, var_ipv6, 1, {2}},


>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-bugs mailing list