From owner-freebsd-hackers@FreeBSD.ORG Thu May 2 07:47:18 2013 Return-Path: Delivered-To: hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 86ACC660 for ; Thu, 2 May 2013 07:47:18 +0000 (UTC) (envelope-from prvs=1834ac79c3=killing@multiplay.co.uk) Received: from mail1.multiplay.co.uk (mail1.multiplay.co.uk [85.236.96.23]) by mx1.freebsd.org (Postfix) with ESMTP id 06FEF1CDF for ; Thu, 2 May 2013 07:47:17 +0000 (UTC) Received: from r2d2 ([46.65.172.4]) by mail1.multiplay.co.uk (mail1.multiplay.co.uk [85.236.96.23]) (MDaemon PRO v10.0.4) with ESMTP id md50003601463.msg for ; Thu, 02 May 2013 08:47:13 +0100 X-Spam-Processed: mail1.multiplay.co.uk, Thu, 02 May 2013 08:47:13 +0100 (not processed: message from valid local sender) X-MDDKIM-Result: neutral (mail1.multiplay.co.uk) X-MDRemoteIP: 46.65.172.4 X-Return-Path: prvs=1834ac79c3=killing@multiplay.co.uk X-Envelope-From: killing@multiplay.co.uk X-MDaemon-Deliver-To: hackers@freebsd.org Message-ID: From: "Steven Hartland" To: "Dimitry Andric" , "Alfred Perlstein" References: <51814686.2060805@ixsystems.com> Subject: Re: potential future proofing fix for aicasm build. Date: Thu, 2 May 2013 08:47:52 +0100 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.5931 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 Cc: hackers@freebsd.org X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 May 2013 07:47:18 -0000 I just remembered I had an issue with aicasm when compiling our kernel that didn't have ahc or ahd on an 8.3 box. The fix was to manually delete the kernel obj directory before compiling after doing a full make buildworld. For some reason there was some cruft left in there that running make buildkernel wasn't cleaning out, could you be suffering from a similar issue? ----- Original Message ----- From: "Dimitry Andric" To: "Alfred Perlstein" Cc: Sent: Thursday, May 02, 2013 8:19 AM Subject: Re: potential future proofing fix for aicasm build. > On May 1, 2013, at 18:44, Alfred Perlstein wrote: >> I took a shot at fixing this issue with building aicasm as part of "buildkernel" of an older 9.0 src on a machine running HEAD. >> >> aicasm.o: In function `__getCurrentRuneLocale': > /usr/include/runetype.h:96: undefined reference to `_ThreadRuneLocale' > > I don't understand this error message... It seems like a linker error, but it also seems to refer to an incorrect include file? > Is this during linking or compiling? > > >> The issue seems to be two-fold: >> >> 1) Paths are not fully set to pick up the bootstrap tools needed to build. > > What do you mean, exactly? In r230622 I explicitly set the PATH to ${BPATH}:${PATH}, which should be enough to pick up the > bootstrap tools. This is exactly the same path used to build the bootstrap-tools stage itself. The kernel bootstrap tools > (only aicasm, really) should be built by the host compiler, not the cross-tools compiler. > > >> 2) include files use the host's instead of the build trees. >> >> The first problem is fixed by changing setting of PATH from "${BPATH}:${PATH}" to ${TMPPATH}. >> >> The second is fixed by using -nostdinc and setting strict include paths using -I directives to the compiler: >> >> CFLAGS="-nostdinc -I${WORLDTMP}/usr/include -I. -I${KERNSRCDIR}/dev/aic7xxx/aicasm" > > I don't think this is correct, as aicasm should be compiled by the host compiler, and linked with the host libc. So if you > start including headers from the source directory, there will be a mismatch between what those headers declare, and what is > available in the host libc. > > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" > ================================================ This e.mail is private and confidential between Multiplay (UK) Ltd. and the person or entity to whom it is addressed. In the event of misdirection, the recipient is prohibited from using, copying, printing or otherwise disseminating it or any information contained in it. In the event of misdirection, illegible or incomplete transmission please telephone +44 845 868 1337 or return the E.mail to postmaster@multiplay.co.uk.