From owner-freebsd-current@FreeBSD.ORG Sun Nov 1 17:51:44 2009 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8812F1065676 for ; Sun, 1 Nov 2009 17:51:44 +0000 (UTC) (envelope-from ben@wanderview.com) Received: from mail.wanderview.com (mail.wanderview.com [66.92.166.102]) by mx1.freebsd.org (Postfix) with ESMTP id 122448FC26 for ; Sun, 1 Nov 2009 17:51:43 +0000 (UTC) Received: from xykon.in.wanderview.com (xykon.in.wanderview.com [10.76.10.152]) (authenticated bits=0) by mail.wanderview.com (8.14.3/8.14.3) with ESMTP id nA1HeP98008704 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO) for ; Sun, 1 Nov 2009 17:40:25 GMT (envelope-from ben@wanderview.com) From: Ben Kelly Content-Type: multipart/mixed; boundary=Apple-Mail-152--382848992 Date: Sun, 1 Nov 2009 12:40:25 -0500 Message-Id: <92BA99AC-E038-44F4-A443-91FF5AA2968F@wanderview.com> To: current@freebsd.org Mime-Version: 1.0 (Apple Message framework v1076) X-Mailer: Apple Mail (2.1076) X-Spam-Score: -1.44 () ALL_TRUSTED X-Scanned-By: MIMEDefang 2.64 on 10.76.20.1 Cc: Subject: ifmcstat fails to build without KVM and with INET6 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Nov 2009 17:51:44 -0000 --Apple-Mail-152--382848992 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii; format=flowed; delsp=yes Hello all, I'm having difficulty compiling a freshly updated checkout of head using WITHOUT_KVM src.conf. The error is in src/usr.sbin/ifmcstat/ ifmcstat.c. It appears the problem is due to the in6_ifinfo() function definition being incorrectly under an #ifdef WITH_KVM section. I was able to fix the problem with the attached patch. Just FYI in case anyone else hits this problem. - Ben --Apple-Mail-152--382848992 Content-Disposition: attachment; filename=ifmcstat.patch Content-Type: application/octet-stream; name="ifmcstat.patch" Content-Transfer-Encoding: 7bit Index: usr.sbin/ifmcstat/ifmcstat.c =================================================================== --- usr.sbin/ifmcstat/ifmcstat.c (revision 242) +++ usr.sbin/ifmcstat/ifmcstat.c (working copy) @@ -442,32 +442,6 @@ #ifdef INET6 static void -in6_ifinfo(struct mld_ifinfo *mli) -{ - - printf("\t"); - switch (mli->mli_version) { - case MLD_VERSION_1: - case MLD_VERSION_2: - printf("mldv%d", mli->mli_version); - break; - default: - printf("mldv?(%d)", mli->mli_version); - break; - } - printb(" flags", mli->mli_flags, "\020\1SILENT"); - if (mli->mli_version == MLD_VERSION_2) { - printf(" rv %u qi %u qri %u uri %u", - mli->mli_rv, mli->mli_qi, mli->mli_qri, mli->mli_uri); - } - if (vflag >= 2) { - printf(" v1timer %u v2timer %u", mli->mli_v1_timer, - mli->mli_v2_timer); - } - printf("\n"); -} - -static void if6_addrlist(struct ifaddr *ifap) { struct ifnet ifnet; @@ -764,6 +738,33 @@ #endif /* WITH_KVM */ #ifdef INET6 + +static void +in6_ifinfo(struct mld_ifinfo *mli) +{ + + printf("\t"); + switch (mli->mli_version) { + case MLD_VERSION_1: + case MLD_VERSION_2: + printf("mldv%d", mli->mli_version); + break; + default: + printf("mldv?(%d)", mli->mli_version); + break; + } + printb(" flags", mli->mli_flags, "\020\1SILENT"); + if (mli->mli_version == MLD_VERSION_2) { + printf(" rv %u qi %u qri %u uri %u", + mli->mli_rv, mli->mli_qi, mli->mli_qri, mli->mli_uri); + } + if (vflag >= 2) { + printf(" v1timer %u v2timer %u", mli->mli_v1_timer, + mli->mli_v2_timer); + } + printf("\n"); +} + static const char * inet6_n2a(struct in6_addr *p) { --Apple-Mail-152--382848992--