From owner-freebsd-amd64@FreeBSD.ORG Thu Mar 24 21:50:00 2005 Return-Path: Delivered-To: freebsd-amd64@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5F94016A4CE for ; Thu, 24 Mar 2005 21:50:00 +0000 (GMT) Received: from dragon.NUXI.org (trang.nuxi.com [66.93.134.19]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0E59E43D31 for ; Thu, 24 Mar 2005 21:50:00 +0000 (GMT) (envelope-from obrien@NUXI.com) Received: from dragon.NUXI.org (obrien@localhost [127.0.0.1]) by dragon.NUXI.org (8.13.3/8.13.3) with ESMTP id j2OLnvqS099146; Thu, 24 Mar 2005 13:49:57 -0800 (PST) (envelope-from obrien@dragon.NUXI.org) Received: (from obrien@localhost) by dragon.NUXI.org (8.13.3/8.13.1/Submit) id j2OLnuof099145; Thu, 24 Mar 2005 13:49:56 -0800 (PST) (envelope-from obrien) Date: Thu, 24 Mar 2005 13:49:56 -0800 From: "David O'Brien" To: Vinod Kashyap Message-ID: <20050324214956.GA99087@dragon.NUXI.org> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Operating-System: FreeBSD 5.2-CURRENT Organization: The NUXI BSD Group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 User-Agent: Mutt/1.5.9i cc: freebsd-amd64@freebsd.org Subject: Re: undefined reference to `memset' X-BeenThere: freebsd-amd64@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: freebsd-amd64@freebsd.org List-Id: Porting FreeBSD to the AMD64 platform List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Mar 2005 21:50:00 -0000 Please don't top-post -- it destroys context. [Format recovered] On Thu, Mar 24, 2005 at 12:46:41PM -0800, Vinod Kashyap wrote: > > On Thu, Mar 24, 2005 at 06:05:17PM +1100, Peter Jeremy wrote: > > > On Wed, 2005-Mar-23 13:48:04 -0800, Vinod Kashyap wrote: > > > >If any kernel module has the following, or a similar line in it: > > > >----- > > > >char x[100] = {0}; > > > >----- > > > >building of the GENERIC kernel on FreeBSD 5 -STABLE for amd64 > > > >as of 03/19/05, fails with the following message at the > > time of linking: > > > >"undefined reference to `memset'". > > > > > > > >The same problem is not seen on i386. > > > > > > > >The problem goes away if the above line is changed to: > > > >----- > > > >char x[100]; > > > >memset(x, 0, 100); > > > >----- > > > > > > Can you post a complete (compilable) example please. > > > > Vinod can you please post a complete compilable example? > > It is impossible to get anything done about your issue without stand > > alone test code. > Ok, make sure you have 'device twa' in your kernel configuration > file, and apply these patches to /sys/dev/twa/twa.c. > This patch causes the problem: "stand alone" means a single foo.c file that shows the problem you want fixed. I cannot submit a GCC bug report with a tarball of the entire FreeBSD kernel. -- -- David (obrien@FreeBSD.org)