From unknown Sat Jun 21 10:38:40 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#63789 <63789@debbugs.gnu.org> To: bug#63789 <63789@debbugs.gnu.org> Subject: Status: Native compilation broken on the Hurd (with patch) Reply-To: bug#63789 <63789@debbugs.gnu.org> Date: Sat, 21 Jun 2025 17:38:40 +0000 retitle 63789 Native compilation broken on the Hurd (with patch) reassign 63789 guix submitter 63789 Janneke Nieuwenhuizen severity 63789 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Mon May 29 12:46:46 2023 Received: (at submit) by debbugs.gnu.org; 29 May 2023 16:46:47 +0000 Received: from localhost ([127.0.0.1]:59004 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q3g17-0001EJ-Jf for submit@debbugs.gnu.org; Mon, 29 May 2023 12:46:46 -0400 Received: from lists.gnu.org ([209.51.188.17]:47598) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q3g15-0001E9-33 for submit@debbugs.gnu.org; Mon, 29 May 2023 12:46:44 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q3g0z-00075A-Pu for bug-guix@gnu.org; Mon, 29 May 2023 12:46:39 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q3g0z-0002Br-3K; Mon, 29 May 2023 12:46:37 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:Date:Subject:To:From:in-reply-to: references; bh=XRfZ6XQrHLNPI9AjEQQxmdFvX0+TaCdPuVx5FrCz5GE=; b=iNd8c2A+PSIJnr /HIzxSp9yKCKw9AhqBNeEsBkMOEXjs2yRvJjyHkWB3kcb+VUjBxhss8/U/01dhA9eAGFImVBRcw0d gbJgpBbdnwQlJUfMZiRfdF3ZISrLQStV9s/hcbLO0wAHx6HX8JPuwpbNZ1KZI0s7dTwLujMT+a4Bp KKIrKntwvK1BMLY5MGlnqLz8MaxFBDu1zZBXL26zl5QpTk2ZouGqAA1pK6cA0UwSWsN69I16fpkLy 2f0ITZ/iFc0R8w6B3rleDGYAkjVOjfmJoA1R0BViDxzPy4jIlAOSWjtauznOlPlJDMjSxS7Ef82UZ R74VQVIJameGqRZFWb4Q==; Received: from 2a02-a462-da03-1-2701-7f81-a736-4607.fixed6.kpn.net ([2a02:a462:da03:1:2701:7f81:a736:4607] helo=drakenpad.janneke.lilypond.org) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q3g0y-0007z1-K6; Mon, 29 May 2023 12:46:36 -0400 From: Janneke Nieuwenhuizen To: bug-guix@gnu.org Subject: Native compilation broken on the Hurd (with patch) Organization: AvatarAcademy.nl User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) X-Url: http://AvatarAcademy.nl Date: Mon, 29 May 2023 18:46:31 +0200 Message-ID: <87edmzozko.fsf@gnu.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) --=-=-= Content-Type: text/plain Hi! The commit 56759d30d9a817a9c9221c9468a4c4a59c9a4713 gnu: Switch to GCC 11. introduced a gratuitous dependency on coreutils-boot0 to gcc-boot0 by adding this atypical snippet --8<---------------cut here---------------start------------->8--- (snippet #~(begin ;; XXX: The GCC test suite contains files with non-ASCII file ;; names, which cannot be repacked by BOOTSTRAP-ORIGIN. Nor ;; can it be deleted from Guile, so resort to this evil hack. #$(origin-snippet (package-source gcc)) (system* #$(file-append coreutils-boot0 "/bin/rm") "-rf" "gcc/testsuite/go.test/test/fixedbugs/issue27836.dir")))))) --8<---------------cut here---------------end--------------->8--- This is problematic, because coreutils-boot0 doesn't build for the Hurd: coreutils needs hurd headers, and our hurd-headers-boot0 depends on...coreutils-boot0. Why was coreutils-boot0 used instead of the canonical delete-file-recursively? Anyway, as a first attempt, I tried adding --8<---------------cut here---------------start------------->8--- (define gcc-boot0/hurd ;; gcc-boot0 adds a dependency on coreutils-boot0, which does not build on ;; the Hurd. Move this origin definition to gcc-boot0 and remove ;; gcc-boot0/hurd in the next rebuild cycle. (package (inherit gcc-boot0) (source (bootstrap-origin (origin (inherit (package-source gcc)) (snippet #~(begin ;; XXX: The GCC test suite contains files with non-ASCII file ;; names, which cannot be repacked by BOOTSTRAP-ORIGIN. Nor ;; can it be deleted from Guile, so resort to this evil hack. #$(origin-snippet (package-source gcc)) (delete-file-recursively "gcc/testsuite/go.test/test/fixedbugs/issue27836.dir")))))))) --8<---------------cut here---------------end--------------->8--- and use that in %boot1-inputs...but as gcc-boot0 is used in more places that doesn't really work. So, until we can correct the gcc-boot0 snippet problem in the next rebuild cycle (how does that work now that we don't have core-updates anymore?, I made coreutils-boot0 build on the Hurd. See the patch below. Using this patch, I've just succeeded to build gcc-boot0: --8<---------------cut here---------------start------------->8--- root@guixydevel ~/src/guix/wip-hurd# ./pre-inst-env guix build -e '(@@ (gnu packages commencement) gcc-boot0)' --verbosity=1 The following derivation will be built: /gnu/store/669gwbfc96k5r8rv06d4cd10q7kpnkqn-gcc-cross-boot0-11.3.0.drv building /gnu/store/669gwbfc96k5r8rv06d4cd10q7kpnkqn-gcc-cross-boot0-11.3.0.drv... /gnu/store/3hl61ndnzqjrr07rywh2mfw58k81jchy-gcc-cross-boot0-11.3.0-lib /gnu/store/wbdza27aq1mab8blvswvd0g28n5pk982-gcc-cross-boot0-11.3.0 --8<---------------cut here---------------end--------------->8--- but now `guix build hello' seems to hang, so it a circular dependency might have been introduced somewhere. What a mess... WDYT? Greetings, Janneke --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-gnu-commencement-coreutils-boot0-Fix-native-build-fo.patch >From 37f38eb35fff505da9bfad8cb1f5f250378f7648 Mon Sep 17 00:00:00 2001 Message-Id: <37f38eb35fff505da9bfad8cb1f5f250378f7648.1685370023.git.janneke@gnu.org> From: Janneke Nieuwenhuizen Date: Mon, 29 May 2023 10:34:42 +0200 Subject: [PATCH] gnu: commencement: coreutils-boot0: Fix native build for the Hurd. * gnu/packages/patches/coreutils-boot0-hurd_types.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/commencement.scm (coreutils-boot0)[arguments]: When building for the hurd, add new phase 'add-hurd_types.h' and use it. Add "ac_cv_member_struct_stat_st_author=no" and -Wl,-rpath for %bootstrap-libc to configure flags when building for the Hurd. Add make-flags with "IGNORE_UNUSED_LIBRARIES_CFLAGS=" to avoid -Wl,--as-needed, which undoes previous rpath option. --- gnu/local.mk | 1 + gnu/packages/commencement.scm | 56 +++++++++---- .../patches/coreutils-boot0-hurd_types.patch | 82 +++++++++++++++++++ 3 files changed, 122 insertions(+), 17 deletions(-) create mode 100644 gnu/packages/patches/coreutils-boot0-hurd_types.patch diff --git a/gnu/local.mk b/gnu/local.mk index 44aa0ba69b..d86a6763b2 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1018,6 +1018,7 @@ dist_patch_DATA = \ %D%/packages/patches/converseen-hide-updates-checks.patch \ %D%/packages/patches/converseen-hide-non-free-pointers.patch \ %D%/packages/patches/cool-retro-term-wctype.patch \ + %D%/packages/patches/coreutils-boot0-hurd_types.patch \ %D%/packages/patches/coreutils-gnulib-tests.patch \ %D%/packages/patches/coq-fix-envvars.patch \ %D%/packages/patches/cppcheck-disable-char-signedness-test.patch \ diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm index a24c60ebf8..eb1377c01c 100644 --- a/gnu/packages/commencement.scm +++ b/gnu/packages/commencement.scm @@ -1997,24 +1997,46 @@ (define coreutils-boot0 `(("make" ,gnu-make-boot0) ,@(%bootstrap-inputs+toolchain))) (arguments - `(#:tests? #f - #:implicit-inputs? #f - #:guile ,%bootstrap-guile - ,@(package-arguments coreutils) - ;; The %bootstrap-glibc for aarch64 and armhf doesn't have - ;; $output/include/linux/prctl.h which causes some binaries - ;; to fail to build with coreutils-9.0+. - ,@(if (target-arm?) + (cons* + #:tests? #f + #:implicit-inputs? #f + #:guile %bootstrap-guile + (append + (if (target-hurd?) + (substitute-keyword-arguments (package-arguments coreutils) + ((#:configure-flags flags) + `(cons* "ac_cv_member_struct_stat_st_author=no" + (string-append + "LDFLAGS=-Wl,-rpath -Wl," + (assoc-ref %build-inputs "libc") + "/lib") + ,flags)) + ((#:make-flags flags) + ''("IGNORE_UNUSED_LIBRARIES_CFLAGS=")) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'add-hurd_types.h + (lambda _ + (let ((patch-file + #$(local-file + (search-patch + "coreutils-boot0-hurd_types.patch")))) + (invoke "patch" "--force" "-p1" "-i" patch-file))))))) + (package-arguments coreutils)) + ;; The %bootstrap-glibc for aarch64 and armhf doesn't have + ;; $output/include/linux/prctl.h which causes some binaries + ;; to fail to build with coreutils-9.0+. + (if (target-arm?) `(#:configure-flags '(,(string-append - "--enable-no-install-program=" - ;; the defaults to not install. - "arch,coreutils,hostname" - ;; fails due to missing headers. - ",timeout,sort") - ,@(if (target-arm32?) - `("--disable-year2038") - `()))) - '()))))) + "--enable-no-install-program=" + ;; the defaults to not install. + "arch,coreutils,hostname" + ;; fails due to missing headers. + ",timeout,sort") + ,@(if (target-arm32?) + '("--disable-year2038") + '()))) + '())))))) (define diffutils-boot0 (package diff --git a/gnu/packages/patches/coreutils-boot0-hurd_types.patch b/gnu/packages/patches/coreutils-boot0-hurd_types.patch new file mode 100644 index 0000000000..ec694b9e77 --- /dev/null +++ b/gnu/packages/patches/coreutils-boot0-hurd_types.patch @@ -0,0 +1,82 @@ +This adds a minimal excerpt from hurd/hurd_types.h as src/hurd/hurd_types.h to +break a potential bootstrap cycle. We cannot add hurd-headers-boot0 as an +input, because hurd-headers-boot0 depends on coreutils-boot0. + +The proper fix would be to remove the coreutils-boot0 dependency from the +gcc-boot0 origin snippet and use `delete-file-recursively' instead. + +From f5b58dc60422d3e3ce65fc3e073c1d6f8ba46cc2 Mon Sep 17 00:00:00 2001 +From: Janneke Nieuwenhuizen +Date: Mon, 29 May 2023 14:47:33 +0200 +Subject: [PATCH] src: Add src/hurd/hurd_types.h to break bootstrap cycle. + +* src/hurd/hurd_types.h: New file. +--- + src/hurd/hurd_types.h | 55 +++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 55 insertions(+) + create mode 100644 src/hurd/hurd_types.h + +diff --git a/src/hurd/hurd_types.h b/src/hurd/hurd_types.h +new file mode 100644 +index 000000000..2b3e2fcbc +--- /dev/null ++++ b/src/hurd/hurd_types.h +@@ -0,0 +1,55 @@ ++/* C declarations for Hurd server interfaces ++ ++ Copyright (C) 1993-1996, 1998, 1999, 2001, 2002, 2010, 2014-2019 ++ Free Software Foundation, Inc. ++ ++ This file is part of the GNU Hurd. ++ ++ The GNU Hurd is free software; you can redistribute it and/or modify ++ it under the terms of the GNU General Public License as published by ++ the Free Software Foundation; either version 2, or (at your option) ++ any later version. ++ ++ The GNU Hurd is distributed in the hope that it will be useful, ++ but WITHOUT ANY WARRANTY; without even the implied warranty of ++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ++ GNU General Public License for more details. ++ ++ You should have received a copy of the GNU General Public License ++ along with the GNU Hurd. If not, see . */ ++ ++#ifndef _HURD_TYPES_H ++#define _HURD_TYPES_H ++ ++/* st_fstype in struct stat and fsys_stb_type in fsys_statfsbuf is one of: */ ++#define FSTYPE_UFS 0x00000000 /* 4.x BSD Fast File System */ ++#define FSTYPE_NFS 0x00000001 /* Network File System ala Sun */ ++#define FSTYPE_GFS 0x00000002 /* GNU file system */ ++#define FSTYPE_LFS 0x00000003 /* Logging File System ala Sprite */ ++#define FSTYPE_SYSV 0x00000004 /* Old U*x filesystem ala System V */ ++#define FSTYPE_FTP 0x00000005 /* Transparent FTP */ ++#define FSTYPE_TAR 0x00000006 /* Transparent TAR */ ++#define FSTYPE_AR 0x00000007 /* Transparent AR */ ++#define FSTYPE_CPIO 0x00000008 /* Transparent CPIO */ ++#define FSTYPE_MSLOSS 0x00000009 /* MS-DOS */ ++#define FSTYPE_CPM 0x0000000a /* CP/M */ ++#define FSTYPE_HFS 0x0000000b /* Don't ask */ ++#define FSTYPE_DTFS 0x0000000c /* used by desktop to provide more info */ ++#define FSTYPE_GRFS 0x0000000d /* GNU Remote File System */ ++#define FSTYPE_TERM 0x0000000e /* GNU Terminal driver */ ++#define FSTYPE_DEV 0x0000000f /* GNU Special file server */ ++#define FSTYPE_PROC 0x00000010 /* /proc filesystem ala Version 9 */ ++#define FSTYPE_IFSOCK 0x00000011 /* PF_LOCAL socket naming point */ ++#define FSTYPE_AFS 0x00000012 /* Andrew File System 3.xx */ ++#define FSTYPE_DFS 0x00000013 /* Distributed File Sys (OSF) == AFS 4.xx */ ++#define FSTYPE_PROC9 0x00000014 /* /proc filesystem ala Plan 9 */ ++#define FSTYPE_SOCKET 0x00000015 /* io_t that isn't a file but a socket */ ++#define FSTYPE_MISC 0x00000016 /* generic trivfs server */ ++#define FSTYPE_EXT2FS 0x00000017 /* Linux filesystem by Remy Card */ ++#define FSTYPE_HTTP 0x00000018 /* Transparent HTTP */ ++#define FSTYPE_MEMFS 0x00000019 /* In-core filesystem */ ++#define FSTYPE_ISO9660 0x0000001a /* ISO9660 */ ++#define FSTYPE_PCI 0x0000001b /* PCI filesystem */ ++#define FSTYPE_ACPI 0x0000001c /* ACPI filesystem */ ++ ++#endif +-- +2.40.1 + base-commit: 7b00b155d8f474d493a22ff7cccbeec311b9bbc8 prerequisite-patch-id: b96b7fc07560b67bb954891c08b07874050bd815 prerequisite-patch-id: 661334c882030b404c16aa87af52696275d57f66 prerequisite-patch-id: 48af5fd9f6821f907331afb9657df63c8b14ec4b prerequisite-patch-id: 27ee469438c657694caf0908fffb2dd04004b338 prerequisite-patch-id: faf77d8c8f5b334c592be0de177500c5ed48253d prerequisite-patch-id: 4cf543b05e46babd5744f11a034b06a69a8f586d prerequisite-patch-id: 3203da98fdcebf54be372d646376ac0c1ed3561d prerequisite-patch-id: b302b87c50035242fa5842449a8502aa26650e46 prerequisite-patch-id: 8b731aee2f3632e6a6c154991a049ceba6471191 prerequisite-patch-id: a1ab14d78cd7ebeb490c31f627b9ae1fa61c2c80 prerequisite-patch-id: 49e32295a422d95c22a8ca4c8b5a3888a1f1c3d1 prerequisite-patch-id: fa0634162bbb2a3c681573cfa54ed14da3040140 prerequisite-patch-id: eff2e90da0ddb61cdc94d6eb083d79623a8f3b06 prerequisite-patch-id: 2501018d2afba9cc91e8f1f9725940e8f1c4ee83 prerequisite-patch-id: 280fe3f9c895825f4b0762ac60a52b358b605cf6 prerequisite-patch-id: eea541992403b758a104b5af27c8badae3baf2f4 prerequisite-patch-id: a6c0a342e46e36b906eee63d257fc0af6427b15a prerequisite-patch-id: 1a2fe0f10be9134fb07bb38554117e0f19fe1707 prerequisite-patch-id: 7d5103573db8f4d608bd95b892a18fc6b24b4757 prerequisite-patch-id: 2c9b8e3516c69d9930890a365274be74d7dec6c3 prerequisite-patch-id: d8861b9abda988879d67b2541870a453dc7be77e prerequisite-patch-id: ae35edf508ae2e7469ff949ebc8854df4e1ffbc1 prerequisite-patch-id: a1be1fe7e65cf971934ad3c67701c3b14ca519d7 prerequisite-patch-id: c50b89c0c9e5cd5bbcc0105923d9bd5526f472ca prerequisite-patch-id: dcf223c4462a67f98274e2b378afbdb640299d40 prerequisite-patch-id: 7193aab88f198d8cbc6760702bdd4faaa0b5a106 prerequisite-patch-id: b2bbb543bfa2ad8ca8b75cb988b78ef15788aaab prerequisite-patch-id: 47715253b05bbeb2296d837565d789d4f4cece1f prerequisite-patch-id: fe888c22279f21ed573d97cb3c32fd750e64bc7f prerequisite-patch-id: c083d6e7b08eec3f0954d5596505128a782109d6 prerequisite-patch-id: a77cce5da6fe87ee3e61d45bfe3195315ac1a3bc prerequisite-patch-id: 3b252fe9479e356c6cfb871eea9ad460a915416b prerequisite-patch-id: 7464ce27b2f36ce538f2dfd1560a0c4e6f073601 prerequisite-patch-id: 90b006b2c5ea686a9ce9a8a4121428e0305899a7 prerequisite-patch-id: 55705deea1dbe21c08590341520d791e0a834f3a prerequisite-patch-id: 2ec7651ffafe201aee13039f1ee897aeef38620a prerequisite-patch-id: 8cd269bb138d5dc79f41612cc18a2a4228e496d0 prerequisite-patch-id: 2e6bc6077534d8954f2ab9068749dc4108a85ff7 prerequisite-patch-id: be84acc08610f5733e484a725a208b89c7466602 prerequisite-patch-id: d1e78442c660bb1450164105310c2473c52e7c52 prerequisite-patch-id: 96a39877f8e21fd8a85dbd59f82f2e5697147bc0 prerequisite-patch-id: 068a494d14fe8f7a32c9572a94cf31459e3fb037 prerequisite-patch-id: 85b1f68a51008deca677e811fde9b29b6c15032e prerequisite-patch-id: 9c4357ee94237511a6abeafaa7b9775e042b8de5 prerequisite-patch-id: 88118d60e5c823f06d66dd2f0533f1164b27acbf prerequisite-patch-id: 384bc8886bffe4ccbbec8a0d1ab28d6b6084b21c prerequisite-patch-id: cece1d586bbe314abab4bbe3f15b8299d9bcc0cd prerequisite-patch-id: af099a015eb8ac396ea8d937f178c3bbf25083da prerequisite-patch-id: 3aacc3d6b5c739573b2f9dd78c10f939f439167f prerequisite-patch-id: d2fb05b6b2d56db8336f139b6306db6bb76ded2f prerequisite-patch-id: 31695aaf8968f8204007acf156763e1b2ecf917a prerequisite-patch-id: 49d979efa4b1a41929484f14d4b5c0dd8f21f5ba prerequisite-patch-id: c6c977b826e398a9ebd1348d96acf560a450612f prerequisite-patch-id: 491d9ffbeb3f43882128465c37ff5488e4c632e7 prerequisite-patch-id: 23a9f3aa13e30e8a6721f596b16bd85ee70ec2c3 prerequisite-patch-id: d3241549d78da53af38729a85b7929808845d6c7 prerequisite-patch-id: 78c1a029ca7c53a1fcb416d122493f84af07b304 prerequisite-patch-id: 02d981d60649b804752f7b80919d58edb741e262 prerequisite-patch-id: e6131a0105e714b43a362a715b621e9020614308 prerequisite-patch-id: 0faf15c9db3aabfc6a621cd1f69d83037a295f88 prerequisite-patch-id: 0ea4eec5324d23be536909870972a0adc0568762 prerequisite-patch-id: afa4f727e5f1d95e4bcbe7cda323038b0a20adf1 prerequisite-patch-id: eb15c6fe043ba091ff09421b800a5c64c6fadbc4 prerequisite-patch-id: 3e926d814690c5d141dfdd4b4e73610ab40bc705 prerequisite-patch-id: f40fbc063f8b0dcfe7ab163a2f88024e0c227c18 prerequisite-patch-id: a6331e2375e48f7b33e5188d45bc36aafccc91fa prerequisite-patch-id: a66e65fb61a233ef27d193aa431de94562b8cd57 prerequisite-patch-id: a45b7540996ac9a1e12de02e1d5278b193acd8aa prerequisite-patch-id: 336252fc9dfc52aa24e8505fc502928d10ce3181 prerequisite-patch-id: 27200425d13134cd13d50909ae8c0051464e8f54 prerequisite-patch-id: 255d49a4185a7b66db8c69b8b18e133e7b659d67 prerequisite-patch-id: a2e0e8c621eda0421bf4149982a2b3e08bac7033 prerequisite-patch-id: dbb134d66fc76750199688ba1bd32b24ccc4b2b1 prerequisite-patch-id: 19bcb1efc1e67fbdafc3ecee0298721a096816d3 prerequisite-patch-id: 630518c61c5de8a41481a6f617b8167999b7501c prerequisite-patch-id: 3b1362b01bb2bb4893600ce0d6f5ae27456f13fe prerequisite-patch-id: 1f163827836c5cf29da978c91bf574670a67adb8 prerequisite-patch-id: c1bbe29954e1655e045e7eae1e6548a0a918173c prerequisite-patch-id: c333d68199f3d244b2b4b6db0a818564bf6093a5 prerequisite-patch-id: bdd15e0c8560fd1746cd2438010da548b348b0a9 prerequisite-patch-id: 5758218e08bfc71a81b208ea9b66081ee5d82de0 prerequisite-patch-id: b1ad8b53894b531291240c763a584ef75946c6bc prerequisite-patch-id: ff64b29fbf19c172e651dd60b19977e94b687571 prerequisite-patch-id: 63f2bb2fee730b2d2877c3d9425b7dd3154dbadb prerequisite-patch-id: d73808aeccb4802cd2d742e9b905a1060be435e1 prerequisite-patch-id: 3bb2c68f61077b84496c0a8809a48ac769e0fe7f prerequisite-patch-id: 36cfcb34718d61b4193e24a4edb838b37907f0cb prerequisite-patch-id: d30f224ccc74c419df33c960987c8951113a1670 prerequisite-patch-id: affa3cbfb5d6879ff11f4a7d030dc8796abcdd87 prerequisite-patch-id: 8e99169701284be360d303b8b24fa7d9a5754292 prerequisite-patch-id: 7a66fe96b5a30efabd331ccc038451ca2516a427 prerequisite-patch-id: 441c7a24e456631522572991244c49b48738d118 prerequisite-patch-id: 2ed5a5b07853d30d9575a144eecba2f4a86d0907 prerequisite-patch-id: b047430c30ba9ea274aea33a467cdb49d769884e prerequisite-patch-id: 8a03c5e8bcd4c526b93c558d550725887f932e41 prerequisite-patch-id: 89400c29b4c30dfbe8492aff1751ca583397b4f0 prerequisite-patch-id: c068d5c98389992badbc1ab7714de4ee0921c09e prerequisite-patch-id: 6de41cdca3442bf7ed5ec9b9b637cd708544b7d7 prerequisite-patch-id: 7eeadb75f4d144f35d7efcdc8378b27fe3c5e081 prerequisite-patch-id: 80aca78175e59e6de1a312a79337e9e841f41261 prerequisite-patch-id: 0e46f6ae7eb7a87dbe704fd2d7934bf9811b615d prerequisite-patch-id: 611636fc38fe413039a494c4b900f60cf5dffa03 prerequisite-patch-id: 81152a28167c5753792b6ac435f46dd43dadcb13 prerequisite-patch-id: 99a98f6d0a97f74d541080a789602715964e162e prerequisite-patch-id: 17991be339a2f7fdd69b8674cd193a592cbf3dc4 prerequisite-patch-id: 0513586ef61aef7195532855404afe1d3466242c prerequisite-patch-id: c6070b7f04fe8616d12d62da921c9894b5c71a76 prerequisite-patch-id: f8c455a58ca730f66c0b589591fe9ee8e6733ec9 prerequisite-patch-id: 693421f009c957365346d143184d4a6d2b6cc727 prerequisite-patch-id: 1cdf7c68bd7c74ad9ec5bc9f4c129bfea1c11be3 prerequisite-patch-id: 099217b842eb48e79a59d2f2fa5c490602a056b8 prerequisite-patch-id: f23965b234cadbcc690f54e92180a0ac52d5db7e prerequisite-patch-id: e5857f0a4bd5112443f90bb70188f62d23cb4183 prerequisite-patch-id: aaa2d82b279cebf88098a96f5d3271ec690dceb4 prerequisite-patch-id: 63e912653dfdadee75143008ce1c9f2a639b44c6 prerequisite-patch-id: 095f03f24e4dfe3692bca7feceedc05310f1bc97 prerequisite-patch-id: e14aa692ef4e2e069be249a88aaee7db4afeb8aa prerequisite-patch-id: c3e6caa73c9acab3a688c0f9772f3e41c3fee683 prerequisite-patch-id: fbcf6a8e3550e9b8a7c18f67f02e1b82bae8e9e1 prerequisite-patch-id: 9d5499d6bc33d541bb0b4519b2cb9f404fee27cb prerequisite-patch-id: 91e3ceed5e0502e3d92e343c191b52561f983bfa prerequisite-patch-id: 41d1a36f721b9947542a6786f07ccf70968e9a2f prerequisite-patch-id: 86f2d1a38f0e37569f7f8137ba1e613198c91c43 prerequisite-patch-id: 95f948376d7e747d7dd3e4ba23cddb587b17dada prerequisite-patch-id: 8f871fea11a893f46200c5ce913f186f644676ba prerequisite-patch-id: 4e9276dd27f5a0fbea1f87b3f8e2c5b1b413b468 prerequisite-patch-id: 5383b123921e5e09014c20e8c24172723ae93c03 prerequisite-patch-id: 71e04113564cf21297df3db17f79903eeeb8c3d1 prerequisite-patch-id: a8c48526e20f77ce6099b40e5cc78c420623090e prerequisite-patch-id: 0d6d9d90956133e15e88e0841207cdd9f2da4260 prerequisite-patch-id: 1f6e628dc3861c33ffbe17f8581e1178b729b954 prerequisite-patch-id: 24c7014f95af29b20d61e41699442100f9f9cdda prerequisite-patch-id: db308b1c39fb9b7ea77a2595a32fd8ec2f09df85 prerequisite-patch-id: d100c00aebbd8471a9886ae813ff3cea244b5139 prerequisite-patch-id: 87648b45656f8555cc6a633c88355d4fc24251cd prerequisite-patch-id: 34fdbf06c49e0e12643cee018592bcde448b03fb prerequisite-patch-id: 71492d07a460d2127f0ca3e79074b96ec0600dae prerequisite-patch-id: 365c01108dbc214e0da77f7e86b28cadcde47c2c prerequisite-patch-id: e864903614cd799d4efa78b2bf5949d969cc8b83 prerequisite-patch-id: 6b900621f04d1f16ab06c0bb69a7ddea70b3c1e0 prerequisite-patch-id: e8cc85ba90f929d1667f4b332b334a7a1d85ead6 prerequisite-patch-id: b92f1221d04fa5e8b0c67e9b2ebde85671673a19 prerequisite-patch-id: 8036b97f29f4e181c836a277bcf8f9d0a6b69d90 prerequisite-patch-id: 0d31991f2aeaab68c609fc8ca4286055cd86988c prerequisite-patch-id: 804da8732d2c9b07f0b35f683226b731ee55e25f prerequisite-patch-id: fe51d6314b54cfaa32cfaa9bf95b3f943c759465 prerequisite-patch-id: 5e3f9795cba8d97ab37b55fcb63a350c39f8c730 prerequisite-patch-id: e3c21cb3fd26347a317a8696625a9e74bc4a1fa2 prerequisite-patch-id: 8d3044ba8b424e3bd68a1c7e1e197cf882b50be5 prerequisite-patch-id: 5807b64f53658b123f3aad1d921e41822d833922 prerequisite-patch-id: b30fcb0acf847d05dc50fa0d9c172831137f0fd3 prerequisite-patch-id: 8e67e3ed93ee982f83f9f0c3a9d0ae2aa8b107dd prerequisite-patch-id: 39ef6cc42688d806514087bb51fa4f3ad2346c0b prerequisite-patch-id: 350ada556e8bf5c3f353de2d706cc65b2aad6ec3 prerequisite-patch-id: 0b8976feabc9ae7553e6806c79dc048b20f5afa3 prerequisite-patch-id: 1d892c6b36737f4fa6c98a376a5bd240d4f20921 prerequisite-patch-id: fcf1e96ff1e4b219d72910ac62e7fa7c15aa4edc prerequisite-patch-id: 12c01806b669b53f92f9e5048d0678796b972e0c prerequisite-patch-id: 686779fa483606cf0cc369a6bce56c067ac6492e prerequisite-patch-id: 457030a85cb1ebff3a133cb822673803411528e3 prerequisite-patch-id: ac3cf405eac2afe984a5c4bc6c31f46734b0d16e prerequisite-patch-id: 4b967cb66bf08b0a64a78d25237297b41aa76f03 prerequisite-patch-id: 3543b86b56555c8c9982506e5bbd77ba57579653 prerequisite-patch-id: 79e28d84f2b98c4147b14668d971b4dc9e1b3c5e prerequisite-patch-id: 2056b44efb40f2f85b0320570a4e709257dd103a prerequisite-patch-id: 93e43e1a1a4b5fb3e2af4432c292803ed7ce30a7 prerequisite-patch-id: bf9f6c2efa2216af0f1787dc1582e2cec821f19e prerequisite-patch-id: 69acf79d4013ebdc3e7dfb4882bbe19498c820a5 prerequisite-patch-id: 900de3149fa074c39e463d859ccdf208ce120a76 prerequisite-patch-id: 196fd00997b26669da59cf6495fa390f42be05f4 prerequisite-patch-id: 8abd87da6210c054402d24e15d1b97d586f40815 prerequisite-patch-id: 5c561982f22f68875142001ea5ff12e4d205297e prerequisite-patch-id: d8b8d605ae1bdff6a21466d03630142b976ba66b prerequisite-patch-id: 8e48f249db6a690de197dc8374579b3794de3c88 prerequisite-patch-id: f642d0473e901d52cc03cf4865b99adc992d45bd prerequisite-patch-id: 1122b34d719074190f7b33d0d67ff5d1d3e7f5db prerequisite-patch-id: 1ce897362b190842dcd9a7877c705171fdd8ade4 prerequisite-patch-id: 20f0d87857211e3951ddbc86eea58150c0d8dcaf prerequisite-patch-id: 22baa06d890ddd086562432ce444abd789eec2d0 prerequisite-patch-id: effedb461bf07207195201682fb9813fc17d6a85 prerequisite-patch-id: ab70003679195a1dd4a64c5c1213c6739d1acdea prerequisite-patch-id: ec7d2e38795d4c81640b33dff7b3c26ac3042735 prerequisite-patch-id: d57c87225c6807cd6b5a49440d966ff82be2153d prerequisite-patch-id: 22b233d97093f5e14419893ed434a9b12bec252c prerequisite-patch-id: adc1a53f933b395000482937c3aea200e17868e4 prerequisite-patch-id: 2cd88e3482ee0b561700b9b665bc39a43b8d7ad1 prerequisite-patch-id: 25a2ac89a85ef047f409348d57ebe7abeb9fe9fd prerequisite-patch-id: db75dca32b49336a1eecf6e23f88d300cecb4921 prerequisite-patch-id: c9a72ac043afbc123fd8f88d48882cfc23113fe1 prerequisite-patch-id: e51c974df61f6e45a0b6e378935a1e9d96e78b70 prerequisite-patch-id: 75fea1aad424875aa83d08decd7157d906089d17 prerequisite-patch-id: 68859ab1cc6f9c0fce73a6ab033290b20e7682ab prerequisite-patch-id: 4c811409b89a2cd254d0e623d010f4a3c862b9c9 prerequisite-patch-id: 31692afc70ca5914e13be0641312ebeff74135fc prerequisite-patch-id: 9174bbe91735dc9c6a808b029ed16a494753ff79 prerequisite-patch-id: 949fec4f42bcbdbd953996ca3d003cc42ae72e42 prerequisite-patch-id: 6f4b9e2b4f63f534ecc5af5867bad1eee3a90432 prerequisite-patch-id: e30fdd3cd7e9f42fb8773bcb6885dc9d200cb4f3 prerequisite-patch-id: 1252d1a4a294d4f70014348e16ce9f777cfa8f7c prerequisite-patch-id: 1ca5f38c3c48de62b29a29611d0b4c70426aa392 prerequisite-patch-id: 8bf104d25fd46844d61b492af108b6ba8e14b5d4 prerequisite-patch-id: 338c112c7fd7d029a7aa2ee9a71983fd99aeafa1 prerequisite-patch-id: d29c78f4497bdd66c1c83566a1e9d63beebcc7d8 -- 2.40.1 --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable --=20 Janneke Nieuwenhuizen | GNU LilyPond https://LilyPond.org Freelance IT https://www.JoyOfSource.com | Avatar=C2=AE https://AvatarAcade= my.com --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Thu Jun 01 17:50:38 2023 Received: (at 63789) by debbugs.gnu.org; 1 Jun 2023 21:50:38 +0000 Received: from localhost ([127.0.0.1]:38641 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q4qBp-0004yf-Qt for submit@debbugs.gnu.org; Thu, 01 Jun 2023 17:50:38 -0400 Received: from eggs.gnu.org ([209.51.188.92]:40428) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q4qBl-0004y9-7r for 63789@debbugs.gnu.org; Thu, 01 Jun 2023 17:50:36 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q4qBe-00087G-31; Thu, 01 Jun 2023 17:50:26 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:In-Reply-To:Date:References:Subject:To: From; bh=ObJ68l/LiAZdGH4PoQugd22YRH+pQDHOe8xNZfbmysA=; b=J4GYENJ0RdlZxR+A0/Tj 41zCGMDBCpY+JVXwsVE03DB+sfw1VF/Uu49sblBy22LsDbUVELSSJDPiz5wc1QitAQUnxkkJZw7qm 67aqIsgYwuu1Lvf3OZ+rmFKUP8NeIY5d+dWlZ3Git3IGTFcJ1A94tmJsoglyqI+rLnJmpN3KZ++3E 8hB+naiXEF4/cbBpR2eQUzdTZWZAsjy23IQIFKJPU9FeoPkWJ/zhnwqCbmWINH6jFjN3G8U+029bT bzlJUHONwxkPVMqIjw+d0aZhCya0AE9UECutePrdaHGhTBuaMCeXpo/5pzZn9v0yfEP68m7w62znB iul4WEqAoU7kKA==; Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q4qBT-0005wx-Ij; Thu, 01 Jun 2023 17:50:25 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Janneke Nieuwenhuizen Subject: Re: bug#63789: Native compilation broken on the Hurd (with patch) References: <87edmzozko.fsf@gnu.org> Date: Thu, 01 Jun 2023 23:50:13 +0200 In-Reply-To: <87edmzozko.fsf@gnu.org> (Janneke Nieuwenhuizen's message of "Mon, 29 May 2023 18:46:31 +0200") Message-ID: <87edmu97je.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 63789 Cc: 63789@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hello! Janneke Nieuwenhuizen skribis: > The commit > > 56759d30d9a817a9c9221c9468a4c4a59c9a4713 > gnu: Switch to GCC 11. > > introduced a gratuitous dependency on coreutils-boot0 to gcc-boot0 by > adding this atypical snippet > > (snippet > #~(begin > ;; XXX: The GCC test suite contains files with non-ASCII file > ;; names, which cannot be repacked by BOOTSTRAP-ORIGIN. Nor > ;; can it be deleted from Guile, so resort to this evil hack. > #$(origin-snippet (package-source gcc)) > (system* #$(file-append coreutils-boot0 "/bin/rm") "-rf" > "gcc/testsuite/go.test/test/fixedbugs/issue27836.di= r")))))) > > > This is problematic, because coreutils-boot0 doesn't build for the Hurd: > coreutils needs hurd headers, and our hurd-headers-boot0 depends > on...coreutils-boot0. > > Why was coreutils-boot0 used instead of the canonical > delete-file-recursively? That was my first reaction too :-), but it=E2=80=99s explained in the comme= nt: there are non-ASCII file names that Guile fails to decode (throwing a decoding error at that point.) Seeing is believing so I had to try: --8<---------------cut here---------------start------------->8--- applying '/gnu/store/5705r4ajxl8lav1hz9xm19w75zdcz1n2-gcc-5.0-libvtv-runpat= h.patch'... applying '/gnu/store/c2f49hzb4scsqaccfr8vf74f06z0yvp1-gcc-10-tree-sra-union= -handling.patch'... find-files: gcc-11.3.0/gcc/testsuite/go.test/test/fixedbugs/issue27836.dir/= =C3=84foo.go: No such file or directory Backtrace: In srfi/srfi-1.scm: 465: 19 [fold # ...] In ice-9/ftw.scm: 452: 18 [# # #] 450: 17 [loop "gcc" "gcc-11.3.0" ...] In srfi/srfi-1.scm: 465: 16 [fold # ...] In ice-9/ftw.scm: 452: 15 [# # #] 450: 14 [loop "testsuite" "gcc-11.3.0/gcc" ...] In srfi/srfi-1.scm: 465: 13 [fold # ...] In ice-9/ftw.scm: 452: 12 [# # #] 450: 11 [loop "go.test" "gcc-11.3.0/gcc/testsuite" ...] In srfi/srfi-1.scm: 465: 10 [fold # ...] In ice-9/ftw.scm: 452: 9 [# # #] 450: 8 [loop "test" "gcc-11.3.0/gcc/testsuite/go.test" ...] In srfi/srfi-1.scm: 465: 7 [fold # ...] In ice-9/ftw.scm: 452: 6 [# # #] 450: 5 [loop "fixedbugs" "gcc-11.3.0/gcc/testsuite/go.test/test" ...] In srfi/srfi-1.scm: 465: 4 [fold # ...] In ice-9/ftw.scm: 452: 3 [# # #] 474: 2 [loop "issue27836.dir" ...] In guix/build/utils.scm: 559: 1 [# "gcc-11.3.0/gcc/testsuite/go.test/test/fixedbugs/issue27836.dir/= =C3=84foo.go" ...] In unknown file: ?: 0 [scm-error misc-error #f "~A" ("find-files failed") #f] ERROR: In procedure scm-error: ERROR: find-files failed builder for `/gnu/store/p2wypjic1f26w2gk6dihn3inzfv426i4-gcc-11.3.0.tar.xz.= drv' failed with exit code 1 --8<---------------cut here---------------end--------------->8--- When decoded as UTF-8, those file names look like this: --8<---------------cut here---------------start------------->8--- $ export LC_ALL=3Den_US.UTF-8 $ tar tvf $(guix build "/gnu/store/pfc1094f3vdc74a6pls7b54m949y5gff-gcc-11.= 3.0.tar.xz.drv") |grep issue27836 -rw-r--r-- rguenther/users 191 2022-04-21 07:58 gcc-11.3.0/gcc/testsuit= e/go.test/test/fixedbugs/issue27836.go drwxr-xr-x rguenther/users 0 2022-04-21 07:58 gcc-11.3.0/gcc/testsuit= e/go.test/test/fixedbugs/issue27836.dir/ -rw-r--r-- rguenther/users 192 2022-04-21 07:58 gcc-11.3.0/gcc/testsuit= e/go.test/test/fixedbugs/issue27836.dir/=C3=84foo.go -rw-r--r-- rguenther/users 203 2022-04-21 07:58 gcc-11.3.0/gcc/testsuit= e/go.test/test/fixedbugs/issue27836.dir/=C3=84main.go --8<---------------cut here---------------end--------------->8--- > So, until we can correct the gcc-boot0 snippet problem in the next > rebuild cycle (how does that work now that we don't have core-updates > anymore?, I made coreutils-boot0 build on the Hurd. See the patch > below. Re =E2=80=9Chow does that work?=E2=80=9D, good question! :-) We should get rid of that hack though. >>>From 37f38eb35fff505da9bfad8cb1f5f250378f7648 Mon Sep 17 00:00:00 2001 > Message-Id: <37f38eb35fff505da9bfad8cb1f5f250378f7648.1685370023.git.jann= eke@gnu.org> > From: Janneke Nieuwenhuizen > Date: Mon, 29 May 2023 10:34:42 +0200 > Subject: [PATCH] gnu: commencement: coreutils-boot0: Fix native build for= the > Hurd. > > * gnu/packages/patches/coreutils-boot0-hurd_types.patch: New file. > * gnu/local.mk (dist_patch_DATA): Add it. > * gnu/packages/commencement.scm (coreutils-boot0)[arguments]: When buildi= ng > for the hurd, add new phase 'add-hurd_types.h' and use it. Add > "ac_cv_member_struct_stat_st_author=3Dno" and -Wl,-rpath for %bootstrap-l= ibc to > configure flags when building for the Hurd. Add make-flags with > "IGNORE_UNUSED_LIBRARIES_CFLAGS=3D" to avoid -Wl,--as-needed, which undoes > previous rpath option. > --- > gnu/local.mk | 1 + > gnu/packages/commencement.scm | 56 +++++++++---- > .../patches/coreutils-boot0-hurd_types.patch | 82 +++++++++++++++++++ > 3 files changed, 122 insertions(+), 17 deletions(-) > create mode 100644 gnu/packages/patches/coreutils-boot0-hurd_types.patch Neat! This is probably okay but I wonder if we can either shrink this patch or use a different strategy. I tried a few things; I thought we could get =E2=80=98coreutils-boot0=E2=80= =99 to build nothing but =E2=80=98rm=E2=80=99 (since the build failure the patch above w= orks around is in =E2=80=98src/copy.c=E2=80=99), but my attempt below doesn=E2=80=99t w= ork: it insists on building other things, including =E2=80=98src/copy.c=E2=80=99. I ran out o= f time but I think it should be possible to make it work. Even better would have been =E2=80=98--enable-no-install-program=3Dcp=E2=80= =99 but =E2=80=98src/copy.c=E2=80=99 is still getting built. (Time passes=E2=80=A6) Just as I was about to give up, I looked at: guix graph -e '(@@ (gnu packages commencement) guile-final)' -s i586-gnu = -M3 |xdot - and found the solution: --=-=-= Content-Type: text/x-patch Content-Disposition: inline diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm index 78cfa4acd0..de3728ae26 100644 --- a/gnu/packages/commencement.scm +++ b/gnu/packages/commencement.scm @@ -2333,7 +2333,13 @@ (define gcc-boot0 ;; names, which cannot be repacked by BOOTSTRAP-ORIGIN. Nor ;; can it be deleted from Guile, so resort to this evil hack. #$(origin-snippet (package-source gcc)) - (system* #$(file-append coreutils-boot0 "/bin/rm") "-rf" + (system* #$(file-append (let-system system + ;; Work around + ;; . + (if (target-hurd? system) + %bootstrap-coreutils&co + coreutils-boot0)) + "/bin/rm") "-rf" "gcc/testsuite/go.test/test/fixedbugs/issue27836.dir")))))) (arguments (cons* --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable How does that sound? :-) Ludo=E2=80=99. --=-=-= Content-Type: text/x-patch Content-Disposition: inline diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm index 78cfa4acd0..17745705f7 100644 --- a/gnu/packages/commencement.scm +++ b/gnu/packages/commencement.scm @@ -1997,24 +1997,41 @@ (define coreutils-boot0 `(("make" ,gnu-make-boot0) ,@(%bootstrap-inputs+toolchain))) (arguments - `(#:tests? #f - #:implicit-inputs? #f - #:guile ,%bootstrap-guile - ,@(package-arguments coreutils) - ;; The %bootstrap-glibc for aarch64 and armhf doesn't have - ;; $output/include/linux/prctl.h which causes some binaries - ;; to fail to build with coreutils-9.0+. - ,@(if (target-arm?) - `(#:configure-flags '(,(string-append - "--enable-no-install-program=" - ;; the defaults to not install. - "arch,coreutils,hostname" - ;; fails due to missing headers. - ",timeout,sort") - ,@(if (target-arm32?) - `("--disable-year2038") - `()))) - '()))))) + (substitute-keyword-arguments (package-arguments coreutils) + ((#:tests? _ #t) + #f) + ((#:implicit-inputs? _ #t) + #f) + ((#:guile _ #f) + %bootstrap-guile) + ((#:configure-flags flags ''()) + ;; The %bootstrap-glibc for aarch64 and armhf doesn't have + ;; $output/include/linux/prctl.h which causes some binaries + ;; to fail to build with coreutils-9.0+. + (if (target-arm?) + `'(,(string-append "--enable-no-install-program=" + ;; the defaults to not install. + "arch,coreutils,hostname" + ;; fails due to missing headers. + ",timeout,sort") + ,@(if (target-arm32?) + `("--disable-year2038") + `())) + ''())) + ((#:phases phases '%standard-phases) + (if (target-hurd?) + `(modify-phases ,phases + (add-after 'unpack 'build-nothing-but-rm + ;; XXX: Normally we wouldn't depend on coreutils-boot0 for + ;; GNU/Hurd; unfortunately, it is used for the gcc-boot0 + ;; snippet below. Since the snippet needs nothing but 'rm', + ;; build just that (thus avoiding build errors in other + ;; programs). + (lambda _ + (substitute* "Makefile.in" + (("^bin_PROGRAMS = .*") + "bin_PROGRAMS = src/rm\n"))))) + phases)))))) (define diffutils-boot0 (package diff --git a/guix/packages.scm b/guix/packages.scm index e26602d589..0802d863b1 100644 --- a/guix/packages.scm +++ b/guix/packages.scm @@ -944,6 +944,13 @@ (define* (patch-and-repack source patches (locales (lookup-input "locales")) (comp (and=> (compressor source-file-name) lookup-input)) (patches (map instantiate-patch patches))) + (define fail-on-error? + #t + #;(let-system (system target) + (pk 'fail? system (->bool (or locales + target + (not (string-prefix? "-gnu" system))))))) + (define build (with-imported-modules '((guix build utils)) #~(begin @@ -986,7 +993,7 @@ (define* (patch-and-repack source patches (format port "~a~%" name)) (find-files directory #:directories? #t - #:fail-on-error? #t))))) + #:fail-on-error? #$fail-on-error?))))) (apply invoke #+(file-append tar "/bin/tar") "cvfa" output --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 02 01:27:28 2023 Received: (at 63789) by debbugs.gnu.org; 2 Jun 2023 05:27:28 +0000 Received: from localhost ([127.0.0.1]:38827 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q4xJs-0005JV-J5 for submit@debbugs.gnu.org; Fri, 02 Jun 2023 01:27:28 -0400 Received: from eggs.gnu.org ([209.51.188.92]:39182) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q4xJm-0005JD-AU for 63789@debbugs.gnu.org; Fri, 02 Jun 2023 01:27:22 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q4xJg-0002Z0-6n; Fri, 02 Jun 2023 01:27:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:In-Reply-To:Date:References:Subject:To: From; bh=6Oeta/faMFYUDSwSBJ5OIAKClMi3zZCB7FQkrmdJGN4=; b=RW5a4eYbkv9KpELzAaTM U/ZDAU0U/uEiTlyinaYVNus0j63YBRav7U0QdbeDt7EVTCq6UEnYK0iCb1qAFDOSlW0wYZwRBFDH/ cxwBjH9NSXUm7J7hvdhkxD2nEAaGKPqILlNQoQLXVachmzcsA5DSJ7u6BRGfrlAt9p9aciYaGO5nH gOH9qwLTQA/hJnI5ZDss8m35UtI7JOxVArQIZp9cNOJFIwNx9Ci08/bI7gPSh8YN1X5U5xMGAlYQM BqqN+T6pVYoYgo6+y1WFD4VR4JfDPPw2aLhEwSiSzNZ29Y2mD6N5RVSiYjLbBIy50gWGRSi+na6jL FdX2oSsoh38bhQ==; Received: from 2a02-a462-da03-1-2701-7f81-a736-4607.fixed6.kpn.net ([2a02:a462:da03:1:2701:7f81:a736:4607] helo=drakenpad.janneke.lilypond.org) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q4xJf-00054I-Ny; Fri, 02 Jun 2023 01:27:11 -0400 From: Janneke Nieuwenhuizen To: Ludovic =?utf-8?Q?Court=C3=A8s?= Subject: Re: bug#63789: Native compilation broken on the Hurd (with patch) Organization: AvatarAcademy.nl References: <87edmzozko.fsf@gnu.org> <87edmu97je.fsf@gnu.org> X-Url: http://AvatarAcademy.nl Date: Fri, 02 Jun 2023 07:27:07 +0200 In-Reply-To: <87edmu97je.fsf@gnu.org> ("Ludovic =?utf-8?Q?Court=C3=A8s=22'?= =?utf-8?Q?s?= message of "Thu, 01 Jun 2023 23:50:13 +0200") Message-ID: <87ttvqmo2c.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 63789 Cc: 63789@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Ludovic Court=C3=A8s writes: Hello, > Janneke Nieuwenhuizen skribis: > [..] >> >> (snippet >> #~(begin >> ;; XXX: The GCC test suite contains files with non-ASCII fi= le >> ;; names, which cannot be repacked by BOOTSTRAP-ORIGIN. Nor >> ;; can it be deleted from Guile, so resort to this evil hac= k. >> #$(origin-snippet (package-source gcc)) >> (system* #$(file-append coreutils-boot0 "/bin/rm") "-rf" >> "gcc/testsuite/go.test/test/fixedbugs/issue27836.d= ir")))))) >> >> >> This is problematic, because coreutils-boot0 doesn't build for the Hurd: >> coreutils needs hurd headers, and our hurd-headers-boot0 depends >> on...coreutils-boot0. >> >> Why was coreutils-boot0 used instead of the canonical >> delete-file-recursively? > > That was my first reaction too :-), but it=E2=80=99s explained in the com= ment: > there are non-ASCII file names that Guile fails to decode (throwing a > decoding error at that point.) Ah, I missed that. Makes sense. > Seeing is believing so I had to try: > > applying '/gnu/store/5705r4ajxl8lav1hz9xm19w75zdcz1n2-gcc-5.0-libvtv-runp= ath.patch'... > applying '/gnu/store/c2f49hzb4scsqaccfr8vf74f06z0yvp1-gcc-10-tree-sra-uni= on-handling.patch'... > find-files: gcc-11.3.0/gcc/testsuite/go.test/test/fixedbugs/issue27836.di= r/=C3=84foo.go: No such file or directory > Backtrace: Ooh... > When decoded as UTF-8, those file names look like this: > > $ export LC_ALL=3Den_US.UTF-8 > -rw-r--r-- rguenther/users 192 2022-04-21 07:58 gcc-11.3.0/gcc/testsu= ite/go.test/test/fixedbugs/issue27836.dir/=C3=84foo.go > -rw-r--r-- rguenther/users 203 2022-04-21 07:58 gcc-11.3.0/gcc/testsu= ite/go.test/test/fixedbugs/issue27836.dir/=C3=84main.go ...interesting! >> So, until we can correct the gcc-boot0 snippet problem in the next >> rebuild cycle (how does that work now that we don't have core-updates >> anymore?, I made coreutils-boot0 build on the Hurd. See the patch >> below. > > Re =E2=80=9Chow does that work?=E2=80=9D, good question! :-) :-) > We should get rid of that hack though. [..] >> * gnu/packages/commencement.scm (coreutils-boot0)[arguments]: When build= ing >> for the hurd, add new phase 'add-hurd_types.h' and use it. Add >> "ac_cv_member_struct_stat_st_author=3Dno" and -Wl,-rpath for %bootstrap-= libc to >> configure flags when building for the Hurd. Add make-flags with >> "IGNORE_UNUSED_LIBRARIES_CFLAGS=3D" to avoid -Wl,--as-needed, which undo= es >> previous rpath option. [..] > Neat! This is probably okay but I wonder if we can either shrink this > patch or use a different strategy. > > I tried a few things; I thought we could get =E2=80=98coreutils-boot0=E2= =80=99 to build > nothing but =E2=80=98rm=E2=80=99 (since the build failure the patch above= works around > is in =E2=80=98src/copy.c=E2=80=99), but my attempt below doesn=E2=80=99t= work: it insists on > building other things, including =E2=80=98src/copy.c=E2=80=99. I ran out= of time but I > think it should be possible to make it work. Nice idea! > Even better would have been =E2=80=98--enable-no-install-program=3Dcp=E2= =80=99 but > =E2=80=98src/copy.c=E2=80=99 is still getting built. > > (Time passes=E2=80=A6) Hm... > Just as I was about to give up, I looked at: > > guix graph -e '(@@ (gnu packages commencement) guile-final)' -s i586-gn= u -M3 |xdot - > > and found the solution: > > diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm > index 78cfa4acd0..de3728ae26 100644 > --- a/gnu/packages/commencement.scm > +++ b/gnu/packages/commencement.scm > @@ -2333,7 +2333,13 @@ (define gcc-boot0 > ;; names, which cannot be repacked by BOOTSTRAP-ORIGIN. Nor > ;; can it be deleted from Guile, so resort to this evil hac= k. > #$(origin-snippet (package-source gcc)) > - (system* #$(file-append coreutils-boot0 "/bin/rm") "-rf" > + (system* #$(file-append (let-system system > + ;; Work around > + ;; . > + (if (target-hurd? system) > + %bootstrap-coreutils&co > + coreutils-boot0)) > + "/bin/rm") "-rf" > "gcc/testsuite/go.test/test/fixedbugs/issue27836.d= ir")))))) > (arguments > (cons* > How does that sound? :-) That's great, thanks! Using this now on my current wip-hurd and it's working for me! Greetings, Janneke > diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm > index 78cfa4acd0..17745705f7 100644 Some nice tricks here, thanks for sharing! --=20 Janneke Nieuwenhuizen | GNU LilyPond https://LilyPond.org Freelance IT https://www.JoyOfSource.com | Avatar=C2=AE https://AvatarAcade= my.com From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 02 11:26:13 2023 Received: (at 63789-done) by debbugs.gnu.org; 2 Jun 2023 15:26:13 +0000 Received: from localhost ([127.0.0.1]:40678 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q56fM-0001ak-Mh for submit@debbugs.gnu.org; Fri, 02 Jun 2023 11:26:12 -0400 Received: from eggs.gnu.org ([209.51.188.92]:51960) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1q56fK-0001aW-8m for 63789-done@debbugs.gnu.org; Fri, 02 Jun 2023 11:26:10 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q56fF-0007os-1H; Fri, 02 Jun 2023 11:26:05 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:In-Reply-To:Date:References:Subject:To: From; bh=iztDmzrmY5o6TnJbzlKob2jz4YCNBieVfMBo6OXoses=; b=Pwtf0h5WhxsEP/uVbs8A 2jrQr+DccvV1+QPWkTZ99Rjpz58koLXn0rSpyD8X6gSuNwYD90+pScb29D67gvHHAv5gsC/CMQfbS RuXeiDy+K/elKTddTXEA2CPSYdx61y1M+cZyVWqLIAce710aBfXCg9SqPpOGEACPG+Llz6O4SqO8/ mvdPvZXSDkuPF8nzYzIurWPvqOtBuG31cSsURxGNEt/iXPcgywPb4pDgLKCMPHctiybzFG4dsWn3O kkV+Q8Vd8I5pal+GKdMtphXzxzchyYtM4s42RkFJRR7tsleMWxKpfxNdHuLh6GFqZn8/4bacOSptr tNmwfhr0FbbSXA==; Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q56fE-0004I9-Kd; Fri, 02 Jun 2023 11:26:04 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Janneke Nieuwenhuizen Subject: Re: bug#63789: Native compilation broken on the Hurd (with patch) References: <87edmzozko.fsf@gnu.org> <87edmu97je.fsf@gnu.org> <87ttvqmo2c.fsf@gnu.org> Date: Fri, 02 Jun 2023 17:26:03 +0200 In-Reply-To: <87ttvqmo2c.fsf@gnu.org> (Janneke Nieuwenhuizen's message of "Fri, 02 Jun 2023 07:27:07 +0200") Message-ID: <87edmt51is.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 63789-done Cc: 63789-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Hello! Janneke Nieuwenhuizen skribis: > That's great, thanks! Using this now on my current wip-hurd and it's > working for me! Awesome, pushed as 48c7e71cd7c3690203d4a8961a651cae090af83f! Ludo=E2=80=99. From unknown Sat Jun 21 10:38:40 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sat, 01 Jul 2023 11:24:12 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator