From owner-freebsd-hackers@FreeBSD.ORG Thu May 2 12:46:50 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 6C9A7DBA for ; Thu, 2 May 2013 12:46:50 +0000 (UTC) (envelope-from dimitry@andric.com) Received: from tensor.andric.com (tensor.andric.com [87.251.56.140]) by mx1.freebsd.org (Postfix) with ESMTP id 307FF18A9 for ; Thu, 2 May 2013 12:46:50 +0000 (UTC) Received: from spaceball.andric.com (spaceball.andric.com [IPv6:2001:7b8:3a7:0:204:4bff:fe01:de8a]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by tensor.andric.com (Postfix) with ESMTPSA id 53A675C45; Thu, 2 May 2013 14:46:47 +0200 (CEST) Message-ID: <51826039.1000108@andric.com> Date: Thu, 02 May 2013 14:46:49 +0200 From: Dimitry Andric User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20100101 Thunderbird/21.0 MIME-Version: 1.0 To: Steven Hartland , Alfred Perlstein Subject: Re: potential future proofing fix for aicasm build. References: <51814686.2060805@ixsystems.com> <518235B9.6090104@andric.com> <9C51B77A3AC948B68BAAFB9FB86DE52F@multiplay.co.uk> <51823CBC.2060803@andric.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit 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 12:46:50 -0000 On 2013-05-02 13:55, Steven Hartland wrote: > From: "Dimitry Andric" >> On 2013-05-02 11:54, Steven Hartland wrote: >>> From: "Dimitry Andric" ... >>> I think what I did was the following:- >>> 1. make buildkernel KERNCONF=MYCONF -j10 # failed due to aicasm >> >> And this is what I cannot reproduce. Works just fine, either with or without -j. > > Have just confirmed this reproduces the issue with a recent head source on 8.3-RELEASE > machine. Note this is the other way around; the original poster was talking about building "an older 9.0 src on a machine running HEAD". > 1. rm -rf /usr/obj > 2. make buildkernel KERNCONF=MYCONF -j10 # Fails with:- > cc1: warnings being treated as errors > aicasm_gram.c:1539: warning: no previous prototype for 'yyparse' Yes, this is because r243906 removed the prototype, since newer versions of yacc generate the prototype for yyparse themselves. Here, lex and yacc should really be (also) built as part of the kernel's bootstrap tools. Currently, they are only part of the bootstrap tools for buildworld, which explains the events below. > 3. make buildworld So here the correct versions of lex and yacc are built... > 4. make buildkernel KERNCONF=MYCONF -j10 # Still fails with:- > cc1: warnings being treated as errors > aicasm_gram.c:1539: warning: no previous prototype for 'yyparse' However, since the .c file is newer than the .y file, it does not get regenerated... > Fix is: > 1. rm -rf /usr/obj/usr/src/sys/MYCONF > 2. make buildkernel KERNCONF=MYCONF -j10 # Now works And with this, you have forced regeneration of the aicasm_gram.c file, so now it builds correctly. E.g., I think you might get away with just rm'ing all the generated aicasm*.c files.