diff -urN ucd-snmp.old/Makefile ucd-snmp/Makefile --- ucd-snmp.old/Makefile Tue May 4 13:30:35 1999 +++ ucd-snmp/Makefile Thu Jun 17 16:14:47 1999 @@ -22,6 +22,9 @@ # provide path to libtool's lib directory: MAKE_ENV= CC_RUNTIME_ARG="-L../snmplib/.libs -L../../snmplib/.libs" +# force configure to use -Dnetbsd1 +LOWER_OPSYS= netbsd1 + # deal with libwrap bogosity by providing these variables to programs which # do not supply them: post-extract: diff -urN ucd-snmp.old/patches/patch-ac ucd-snmp/patches/patch-ac --- ucd-snmp.old/patches/patch-ac Thu Jan 1 01:00:00 1970 +++ ucd-snmp/patches/patch-ac Thu Jun 17 16:12:19 1999 @@ -0,0 +1,45 @@ +diff -ru agent/mibgroup/mibII/interfaces.c.orig agent/mibgroup/mibII/interfaces.c +--- agent/mibgroup/mibII/interfaces.c.orig Tue Mar 16 00:46:12 1999 ++++ agent/mibgroup/mibII/interfaces.c Thu Jun 17 10:21:06 1999 +@@ -114,7 +114,7 @@ + + #if HAVE_SYS_SYSCTL_H + #include +-# if defined(CTL_NET) && !defined(freebsd2) ++# if defined(CTL_NET) && !defined(freebsd2) && !defined(netbsd1) + # ifdef PF_ROUTE + # ifdef NET_RT_IFLIST + # define USE_SYSCTL_IFLIST +@@ -1462,16 +1462,31 @@ + cp = strchr(saveName, '\0'); + string_append_int (cp, ifnet.if_unit); + #endif +- if (1 || strcmp(saveName,"lo0") != 0) { /* XXX */ ++ if (1) { /* XXX */ + /* + * Try to find an address for this interface + */ + + auto_nlist(IFADDR_SYMBOL, (char *)&ia, sizeof(ia)); ++#ifdef netbsd1 ++ ia=(struct in_ifaddr *)ifnet.if_addrlist.tqh_first; ++#endif + while (ia) { + klookup((unsigned long)ia , (char *)&in_ifaddr, sizeof(in_ifaddr)); ++#ifdef netbsd1 ++#define CP(x) ((char *)(x)) ++{ char *cp; struct sockaddr * sa; ++ cp = (CP(in_ifaddr.ia_ifa.ifa_addr) - CP(ia)) + ++ CP(&in_ifaddr); sa = (struct sockaddr *)cp; ++if (sa->sa_family==AF_INET) ++#endif + if (in_ifaddr.ia_ifp == ifnetaddr) break; ++} ++#ifdef netbsd1 ++ ia=(struct in_ifaddr *)in_ifaddr.ia_ifa.ifa_list.tqe_next; ++#else + ia = in_ifaddr.ia_next; ++#endif + } + + #if !defined(netbsd1) && !defined(freebsd2) && !defined(openbsd2) && !defined(STRUCT_IFNET_HAS_IF_ADDRLIST) diff -urN ucd-snmp.old/patches/patch-ad ucd-snmp/patches/patch-ad --- ucd-snmp.old/patches/patch-ad Thu Jan 1 01:00:00 1970 +++ ucd-snmp/patches/patch-ad Thu Jun 17 16:13:18 1999 @@ -0,0 +1,27 @@ +diff -ru agent/mibgroup/mibII/ip.c.orig agent/mibgroup/mibII/ip.c +--- agent/mibgroup/mibII/ip.c.orig Fri Mar 12 18:15:05 1999 ++++ agent/mibgroup/mibII/ip.c Thu Jun 17 10:08:11 1999 +@@ -728,7 +728,11 @@ + #ifdef linux + return (u_char *)&((struct sockaddr_in *)&lowin_ifnet.ia_subnetmask)->sin_addr.s_addr; + #else ++#ifdef netbsd1 ++ long_return = lowin_ifaddr.ia_subnetmask; ++#else + long_return = ntohl(lowin_ifaddr.ia_subnetmask); ++#endif + return(u_char *) &long_return; + #endif + #endif +@@ -737,7 +741,11 @@ + #if defined(linux) || defined(sunV3) + long_return = ntohl(((struct sockaddr_in *) &lowin_ifnet.ifu_broadaddr)->sin_addr.s_addr) & 1; + #else ++#ifdef netbsd1 ++ long_return = (((struct sockaddr_in *) &lowin_ifaddr.ia_broadaddr)->sin_addr.s_addr) & 1; ++#else + long_return = ntohl(((struct sockaddr_in *) &lowin_ifaddr.ia_broadaddr)->sin_addr.s_addr) & 1; ++#endif + #endif + return(u_char *) &long_return; + case IPADREASMMAX: