From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: [PATCH] gnu: commencement: Add support for a native GNU/Hurd system. Date: Wed, 02 Sep 2015 14:56:32 +0200 Message-ID: <87r3mh9dz3.fsf@gnu.org> References: Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:38339) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZX7ae-00020M-Su for Guix-devel@gnu.org; Wed, 02 Sep 2015 08:56:38 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZX7ad-00007N-SB for Guix-devel@gnu.org; Wed, 02 Sep 2015 08:56:36 -0400 In-Reply-To: (Manolis Ragkousis's message of "Thu, 27 Aug 2015 22:53:04 +0300") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: Manolis Ragkousis Cc: Guix-devel Manolis Ragkousis skribis: > From 3a2f644bfdb39349c585233ef6670081adf57eca Mon Sep 17 00:00:00 2001 > From: Manolis Ragkousis > Date: Fri, 21 Aug 2015 15:01:05 +0300 > Subject: [PATCH] gnu: commencement: Add support for a native GNU/Hurd sys= tem. > > * gnu/packages/commencement.scm (kernel-headers-boot0): New procedure. > (flex-boot0, bison-boot0, gnumach-headers-boot0, mig-boot0, > hurd-headers-boot0, hurd-minimal-boot0, hurd-kernel-headers-boot0, ld-w= rapper-boot0): New variables. > (%boot1-inputs): Add ld-wrapper-boot0. > (glibc-final-with-bootstrap-bash)[propagated-inputs]: Replace with kern= el-headers-boot0. > [inputs]: Add "mig". Please align this last line to the left. > (glibc-final)[arguments]: Replace with kernel-headers-boot0. [...] > +(define flex-boot0 > + ;; This Flex is needed to build Mig. s/Mig/MiG/ in the whole file. In the future, we should patch MiG upstream so that the Flex and Bison byproducts are included in the tarball. That would simplify our life. > + (let* ((m4 (package-with-bootstrap-guile > + (package-with-explicit-inputs m4 %boot0-inputs > + (current-source-location) > + #:guile %bootstrap-guile)= )) > + (indent (package-with-bootstrap-guile > + (package-with-explicit-inputs indent %boot0-inputs > + (current-source-locat= ion) > + #:guile %bootstrap-gu= ile))) > + (flex (package (inherit flex) > + (native-inputs '()) > + (propagated-inputs `(("m4" ,m4))) > + (inputs `(("indent" ,indent))) > + (arguments '(#:tests? #f))))) I think the redefinitions of m4 and indent can be omitted since =E2=80=98package-with-explicit-inputs=E2=80=99 works recursively. > +(define bison-boot0 > + ;; This Bison is needed to build Mig so we need it early in the proces= s.=20 > + (let* ((m4 (package-with-bootstrap-guile > + (package-with-explicit-inputs m4 %boot0-inputs > + (current-source-location) > + #:guile %bootstrap-guile)= )) > + (bison (package (inherit bison) > + (native-inputs `(("perl" ,perl-boot0))) > + (propagated-inputs `(("m4" ,m4))) > + (inputs '()) ;remove Flex... > + (arguments '(#:tests? #f))))) ;... and thus disable = tests Same here for m4. > +(define (hurd-kernel-headers-boot0) > + "Return Hurd header and minimal-lib files for the bootstrap environmen= t.". ^^ ^^ ^^^^^^^^^^ =E2=80=9CReturn the Hurd and Mach headers as well as initial Hurd libraries= for the bootstrap environment.=E2=80=9D It=E2=80=99s slightly confusing that a =E2=80=9Ckernel-headers=E2=80=9D pac= kage provides .a files, but OK. > + (define* (kernel-headers-boot0 #:optional (system (%current-system))) ^ Extra space. > +(define ld-wrapper-boot0 > + ;; We need this so binaries on Hurd will have libmachuser and libhurdu= ser > + ;; in their RUNPATH, otherwise validate-runpath? will fail. =E2=80=98validate-runpath=E2=80=99 (no question mark.) > (define bison-boot1 > ;; XXX: This Bison is needed to rebuild Bash's parser, which is modifi= ed by > ;; its CVE patches. Remove it when it's no longer needed. What about s/bison-boot1/bison-boot0/ in the whole file? These are essentially the same package. > @@ -443,6 +551,7 @@ exec ~a/bin/~a-~a -B~a/lib -Wl,-dynamic-linker -Wl,~a= /~a \"$@\"~%" > (package (inherit gnu-gettext) > (name "gettext-boot0") > (inputs '()) ;zero dependencies > + ;; Hmm, yes? :-) Could you send an updated patch? Thanks for all the work! Ludo=E2=80=99.