From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mark H Weaver Subject: Re: Compiling a linux kernel from git Date: Sat, 06 Jul 2019 23:57:13 -0400 Message-ID: <87h87y8pk6.fsf@netris.org> References: <877e8v5ezu.fsf@dustycloud.org> <87pnmm9535.fsf@netris.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:54921) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hjyJA-0007jX-Ma for help-guix@gnu.org; Sat, 06 Jul 2019 23:57:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hjyJ9-0005Bh-KU for help-guix@gnu.org; Sat, 06 Jul 2019 23:57:48 -0400 Received: from world.peace.net ([64.112.178.59]:51946) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hjyJ9-0005BC-G5 for help-guix@gnu.org; Sat, 06 Jul 2019 23:57:47 -0400 In-Reply-To: <87pnmm9535.fsf@netris.org> (Mark H. Weaver's message of "Sat, 06 Jul 2019 18:21:50 -0400") List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org Sender: "Help-Guix" To: Christopher Lemmer Webber Cc: help-guix Hi Chris, I wrote earlier: > My first guess is that '/gnu/store/=E2=80=A6-linux-next-=E2=80=A6-checkou= t/include' > should not be in the C include path while compiling that file, but that > it's getting added. The difference might be due to the fact that the > 'source' in this case is a directory instead of a tarball. I see now what's happening more precisely. Our gcc-7 package inherits from gcc-6 'native-search-paths' for the CPATH variable. Because of this, the 'set-paths' phase in 'gnu-build-system' sets the CPATH to include /include for all native inputs that are directories with an 'include' subdirectory. The 'source' is itself a native input. When it's a tarball, it will not be included, but when it's a source checkout, it _is_ included, although it shouldn't be. > For now, I would try packing the git checkout as a tarball, and then > using that tarball as your 'source'. I'm now fairly confident that this workaround would work. Another workaround would be to add another phase that removes the CPATH component corresponding to 'source', as Tobias does. Mark