From owner-freebsd-current Sat Sep 14 12: 8:55 2002 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B070B37B405 for ; Sat, 14 Sep 2002 12:08:50 -0700 (PDT) Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id EBE1743E81 for ; Sat, 14 Sep 2002 12:08:49 -0700 (PDT) (envelope-from imp@bsdimp.com) Received: from localhost (warner@rover2.village.org [10.0.0.1]) by harmony.village.org (8.12.3/8.12.3) with ESMTP id g8EJ8k9R043647; Sat, 14 Sep 2002 13:08:47 -0600 (MDT) (envelope-from imp@bsdimp.com) Date: Sat, 14 Sep 2002 13:08:42 -0600 (MDT) Message-Id: <20020914.130842.66870829.imp@bsdimp.com> To: rodrigc@attbi.com Cc: freebsd-current@FreeBSD.ORG Subject: Re: Problem with machine/cputype.h From: "M. Warner Losh" In-Reply-To: <20020914110206.A5087@attbi.com> References: <20020914110206.A5087@attbi.com> X-Mailer: Mew version 2.1 on Emacs 21.2 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message: <20020914110206.A5087@attbi.com> Craig Rodrigues writes: : Hi, : : While looking into fixing the audio/rio port which : fails to compile on -current, I found the following : problem. The following program compiles successfully : with the C compiler, but will fail to compile : as a C++ program (ie. rename the file to end with .cpp : and compile with g++) : : #include : #include : #include : : : /include/machine/cpufunc.h: In function `int ffs(int)': : /usr/include/machine/cpufunc.h:109: `int ffs(int)' was declared `extern' and : later `static' : /usr/include/strings.h:44: previous declaration of `int ffs(int)' : : : Is this problem the fault of the header file, the compiler, or the : port? Is there a fix for the header file possible? I've fixed this in our local copy of FreeBSD. It is trivial to fix. I'll see about getting it into -current if it isn't there already. I thought I'd done this already and MFC'd it... Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message