From unknown Fri Sep 05 11:02:24 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#43668 <43668@debbugs.gnu.org> To: bug#43668 <43668@debbugs.gnu.org> Subject: Status: Daemon tries to build GNU/Hurd derivations on GNU/Linux Reply-To: bug#43668 <43668@debbugs.gnu.org> Date: Fri, 05 Sep 2025 18:02:24 +0000 retitle 43668 Daemon tries to build GNU/Hurd derivations on GNU/Linux reassign 43668 guix submitter 43668 Ludovic Court=C3=A8s severity 43668 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Mon Sep 28 04:43:13 2020 Received: (at submit) by debbugs.gnu.org; 28 Sep 2020 08:43:13 +0000 Received: from localhost ([127.0.0.1]:51358 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kMoka-0004ek-SQ for submit@debbugs.gnu.org; Mon, 28 Sep 2020 04:43:13 -0400 Received: from lists.gnu.org ([209.51.188.17]:37716) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kMokY-0004ec-VQ for submit@debbugs.gnu.org; Mon, 28 Sep 2020 04:43:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:39120) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kMokY-0001i6-Ny for bug-guix@gnu.org; Mon, 28 Sep 2020 04:43:10 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:39051) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kMokY-0006ia-Ev for bug-guix@gnu.org; Mon, 28 Sep 2020 04:43:10 -0400 Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=37064 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kMokX-00037G-VO for bug-guix@gnu.org; Mon, 28 Sep 2020 04:43:10 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Subject: Daemon tries to build GNU/Hurd derivations on GNU/Linux X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 7 =?utf-8?Q?Vend=C3=A9miaire?= an 229 de la =?utf-8?Q?R=C3=A9volution?= X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Mon, 28 Sep 2020 10:43:06 +0200 Message-ID: <87a6xacmw5.fsf@inria.fr> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (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: 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 (---) Here=E2=80=99s the problem: --8<---------------cut here---------------start------------->8--- $ guix build guile-bootstrap -s i586-gnu La jena derivo estos konstruata: /gnu/store/xi7r3bryibnyvjrs6avv8qp676mja4w2-guile-bootstrap-2.0.drv building /gnu/store/xi7r3bryibnyvjrs6avv8qp676mja4w2-guile-bootstrap-2.0.dr= v... builder for `/gnu/store/xi7r3bryibnyvjrs6avv8qp676mja4w2-guile-bootstrap-2.= 0.drv' failed due to signal 11 (Segmentation fault) build of /gnu/store/xi7r3bryibnyvjrs6avv8qp676mja4w2-guile-bootstrap-2.0.dr= v failed View build log at '/var/log/guix/drvs/xi/7r3bryibnyvjrs6avv8qp676mja4w2-gui= le-bootstrap-2.0.drv.bz2'. guix build: error: build of `/gnu/store/xi7r3bryibnyvjrs6avv8qp676mja4w2-gu= ile-bootstrap-2.0.drv' failed $ uname -o GNU/Linux $ guix describe=20 Generacio 160 Sep 25 2020 23:40:20 (nuna) guix a0d4aa2 repository URL: https://git.savannah.gnu.org/git/guix.git branch: master commit: a0d4aa2457d7e36012143ffe3fbc9dd4bc20ca4f --8<---------------cut here---------------end--------------->8--- It=E2=80=99s no wonder that the GNU/Hurd executable fails to run on GNU/Lin= ux. The reason the daemon tries to run it anyway is because of the hack introduced in 7bf2a70a4ffd976d50638d3b9f2ec409763157df, in support of transparent emulation via binfmt_misc. Ludo=E2=80=99. From debbugs-submit-bounces@debbugs.gnu.org Mon Sep 28 06:31:38 2020 Received: (at 43668) by debbugs.gnu.org; 28 Sep 2020 10:31:38 +0000 Received: from localhost ([127.0.0.1]:51544 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kMqRV-0007SY-II for submit@debbugs.gnu.org; Mon, 28 Sep 2020 06:31:37 -0400 Received: from eggs.gnu.org ([209.51.188.92]:34348) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kMqRS-0007SK-Gs for 43668@debbugs.gnu.org; Mon, 28 Sep 2020 06:31:35 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:40885) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kMqRN-0004wy-7V for 43668@debbugs.gnu.org; Mon, 28 Sep 2020 06:31:29 -0400 Received: from [2001:660:6102:320:e120:2c8f:8909:cdfe] (port=37300 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kMqRJ-0000ip-QY for 43668@debbugs.gnu.org; Mon, 28 Sep 2020 06:31:27 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: 43668@debbugs.gnu.org Subject: Re: bug#43668: Daemon tries to build GNU/Hurd derivations on GNU/Linux References: <87a6xacmw5.fsf@inria.fr> Date: Mon, 28 Sep 2020 12:31:22 +0200 In-Reply-To: <87a6xacmw5.fsf@inria.fr> ("Ludovic =?utf-8?Q?Court=C3=A8s=22?= =?utf-8?Q?'s?= message of "Mon, 28 Sep 2020 10:43:06 +0200") Message-ID: <875z7ychvp.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 43668 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 Ludovic Court=C3=A8s skribis: > It=E2=80=99s no wonder that the GNU/Hurd executable fails to run on GNU/L= inux. > The reason the daemon tries to run it anyway is because of the hack > introduced in 7bf2a70a4ffd976d50638d3b9f2ec409763157df, in support of > transparent emulation via binfmt_misc. The thing is that x86 GNU/Hurd and GNU/Linux ELF binaries are indistinguishable AFAICS since they both use ELFOSABI_NONE: --8<---------------cut here---------------start------------->8--- scheme@(guile-user)> ,use(guix elf) scheme@(guile-user)> ,use(rnrs io ports) scheme@(guile-user)> (define e (parse-elf (call-with-input-file "/gnu/store= /vq7zyb4hmlrafflmrcjbqccxp4dsx0s3-bash" get-bytevector-all))) scheme@(guile-user)> (elf-abi e) $6 =3D 0 scheme@(guile-user)> ELFOSABI_GNU $7 =3D 3 scheme@(guile-user)> (define e2 (parse-elf (call-with-input-file "/bin/sh" = get-bytevector-all))) scheme@(guile-user)> (elf-abi e2) $8 =3D 0 --8<---------------cut here---------------end--------------->8--- (The =E2=80=98file=E2=80=99 command does manage to recognize GNU/Hurd binar= ies, but I don=E2=80=99t know how it does it.) So I think we can=E2=80=99t count on an =E2=80=98execve=E2=80=99 error and = thus have to treat this case (same architecture but different OS kernel) specially, as shown below. Thoughts? Ludo=E2=80=99. --=-=-= Content-Type: text/x-patch Content-Disposition: inline diff --git a/nix/libstore/build.cc b/nix/libstore/build.cc index 88f8d11103..ccec513d8d 100644 --- a/nix/libstore/build.cc +++ b/nix/libstore/build.cc @@ -1946,6 +1946,15 @@ void DerivationGoal::startBuilder() } +/* Return true if the operating system kernel part of SYSTEM1 and SYSTEM2 (the + bit that comes after the hyphen in system types such as "i686-linux") is + the same. */ +static bool sameOperatingSystemKernel(const std::string& system1, const std::string& system2) +{ + auto os1 = system1.substr(system1.find("-")); + auto os2 = system2.substr(system2.find("-")); + return os1 == os2; +} void DerivationGoal::runChild() { @@ -2208,9 +2217,20 @@ void DerivationGoal::runChild() foreach (Strings::iterator, i, drv.args) args.push_back(rewriteHashes(*i, rewritesToTmp)); - execve(drv.builder.c_str(), stringsToCharPtrs(args).data(), stringsToCharPtrs(envStrs).data()); - - int error = errno; + /* If DRV targets the same operating system kernel, try to execute it: + there might be binfmt_misc set up for user-land emulation of other + architectures. However, if it targets a different operating + system--e.g., "i586-gnu" vs. "x86_64-linux"--do not try executing + it: the ELF file for that OS is likely indistinguishable from a + native ELF binary and it would just crash at run time. */ + int error; + if (sameOperatingSystemKernel(drv.platform, settings.thisSystem)) { + execve(drv.builder.c_str(), stringsToCharPtrs(args).data(), + stringsToCharPtrs(envStrs).data()); + error = errno; + } else { + error = ENOEXEC; + } /* Right platform? Check this after we've tried 'execve' to allow for transparent emulation of different platforms with binfmt_misc --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Mon Sep 28 07:12:26 2020 Received: (at 43668) by debbugs.gnu.org; 28 Sep 2020 11:12:26 +0000 Received: from localhost ([127.0.0.1]:51623 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kMr4z-000068-Qc for submit@debbugs.gnu.org; Mon, 28 Sep 2020 07:12:26 -0400 Received: from eggs.gnu.org ([209.51.188.92]:44340) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kMr4x-00005w-E4 for 43668@debbugs.gnu.org; Mon, 28 Sep 2020 07:12:24 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:41235) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kMr4q-0001oT-0X; Mon, 28 Sep 2020 07:12:17 -0400 Received: from [2001:980:1b4f:1:42d2:832d:bb59:862] (port=58444 helo=dundal.janneke.lilypond.org) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kMr4f-0006YD-RW; Mon, 28 Sep 2020 07:12:11 -0400 From: Jan Nieuwenhuizen To: Ludovic =?utf-8?Q?Court=C3=A8s?= Subject: Re: bug#43668: Daemon tries to build GNU/Hurd derivations on GNU/Linux Organization: AvatarAcademy.nl References: <87a6xacmw5.fsf@inria.fr> <875z7ychvp.fsf@gnu.org> X-Url: http://AvatarAcademy.nl Date: Mon, 28 Sep 2020 13:11:09 +0200 In-Reply-To: <875z7ychvp.fsf@gnu.org> ("Ludovic =?utf-8?Q?Court=C3=A8s=22'?= =?utf-8?Q?s?= message of "Mon, 28 Sep 2020 12:31:22 +0200") Message-ID: <87lfgurwaa.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (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: 43668 Cc: 43668@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: Hi! > Ludovic Court=C3=A8s skribis: > >> It=E2=80=99s no wonder that the GNU/Hurd executable fails to run on GNU/= Linux. >> The reason the daemon tries to run it anyway is because of the hack >> introduced in 7bf2a70a4ffd976d50638d3b9f2ec409763157df, in support of >> transparent emulation via binfmt_misc. > > The thing is that x86 GNU/Hurd and GNU/Linux ELF binaries are > indistinguishable AFAICS since they both use ELFOSABI_NONE: > > scheme@(guile-user)> ,use(guix elf) > scheme@(guile-user)> ,use(rnrs io ports) > scheme@(guile-user)> (define e (parse-elf (call-with-input-file "/gnu/sto= re/vq7zyb4hmlrafflmrcjbqccxp4dsx0s3-bash" get-bytevector-all))) > scheme@(guile-user)> (elf-abi e) > $6 =3D 0 > scheme@(guile-user)> ELFOSABI_GNU > $7 =3D 3 > scheme@(guile-user)> (define e2 (parse-elf (call-with-input-file "/bin/sh= " get-bytevector-all))) > scheme@(guile-user)> (elf-abi e2) > $8 =3D 0 > > (The =E2=80=98file=E2=80=99 command does manage to recognize GNU/Hurd bin= aries, but I > don=E2=80=99t know how it does it.) Looking at the file sources, it uses do_os_note, look: --8<---------------cut here---------------start------------->8--- $ readelf -a $(guix build --target=3Di586-pc-gnu hello)bin/hello Displaying notes found in: .note.ABI-tag Owner Data size Description GNU 0x00000010 NT_GNU_ABI_TAG (ABI version tag) OS: Hurd, ABI: 0.0.0 --8<---------------cut here---------------end--------------->8--- > So I think we can=E2=80=99t count on an =E2=80=98execve=E2=80=99 error an= d thus have to treat > this case (same architecture but different OS kernel) specially, as > shown below. > > Thoughts? If that really doesn't work...then yeah (yuck ;-) Greetigs, Janneke --=20 Jan Nieuwenhuizen | GNU LilyPond http://lilypond.org Freelance IT http://JoyofSource.com | Avatar=C2=AE http://AvatarAcademy.com From debbugs-submit-bounces@debbugs.gnu.org Mon Sep 28 16:45:30 2020 Received: (at 43668) by debbugs.gnu.org; 28 Sep 2020 20:45:30 +0000 Received: from localhost ([127.0.0.1]:54161 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kN01a-00049u-67 for submit@debbugs.gnu.org; Mon, 28 Sep 2020 16:45:30 -0400 Received: from eggs.gnu.org ([209.51.188.92]:38072) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kN01X-00049h-IB for 43668@debbugs.gnu.org; Mon, 28 Sep 2020 16:45:28 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:52409) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kN01Q-0003tk-CR; Mon, 28 Sep 2020 16:45:21 -0400 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=43864 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kN01P-0004ty-5o; Mon, 28 Sep 2020 16:45:20 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Jan Nieuwenhuizen Subject: Re: bug#43668: Daemon tries to build GNU/Hurd derivations on GNU/Linux References: <87a6xacmw5.fsf@inria.fr> <875z7ychvp.fsf@gnu.org> <87lfgurwaa.fsf@gnu.org> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 7 =?utf-8?Q?Vend=C3=A9miaire?= an 229 de la =?utf-8?Q?R=C3=A9volution?= X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Mon, 28 Sep 2020 22:45:17 +0200 In-Reply-To: <87lfgurwaa.fsf@gnu.org> (Jan Nieuwenhuizen's message of "Mon, 28 Sep 2020 13:11:09 +0200") Message-ID: <87r1qlk4v6.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (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: 43668 Cc: 43668@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 (---) Hi!< Jan Nieuwenhuizen skribis: >> Ludovic Court=C3=A8s skribis: >> >>> It=E2=80=99s no wonder that the GNU/Hurd executable fails to run on GNU= /Linux. >>> The reason the daemon tries to run it anyway is because of the hack >>> introduced in 7bf2a70a4ffd976d50638d3b9f2ec409763157df, in support of >>> transparent emulation via binfmt_misc. >> >> The thing is that x86 GNU/Hurd and GNU/Linux ELF binaries are >> indistinguishable AFAICS since they both use ELFOSABI_NONE: [...] > Looking at the file sources, it uses do_os_note, look: > > $ readelf -a $(guix build --target=3Di586-pc-gnu hello)bin/hello > > Displaying notes found in: .note.ABI-tag > Owner Data size Description > GNU 0x00000010 NT_GNU_ABI_TAG (ABI version tag) > OS: Hurd, ABI: 0.0.0 Oh, well done, I browsed =E2=80=98file=E2=80=99 but didn=E2=80=99t find it. >> So I think we can=E2=80=99t count on an =E2=80=98execve=E2=80=99 error a= nd thus have to treat >> this case (same architecture but different OS kernel) specially, as >> shown below. >> >> Thoughts? > > If that really doesn't work...then yeah (yuck ;-) Yeah, I think we=E2=80=99ll have to do this hack (we=E2=80=99re not going t= o parse ELF files and all to determine whether to call =E2=80=98execve=E2=80=99.) (Besides, it would be interesting to understand how the libc/Hurd startup code ends up segfaulting on GNU/Linux.) Ludo=E2=80=99. From debbugs-submit-bounces@debbugs.gnu.org Tue Sep 29 07:56:02 2020 Received: (at 43668) by debbugs.gnu.org; 29 Sep 2020 11:56:02 +0000 Received: from localhost ([127.0.0.1]:55084 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kNEEk-0005Io-5n for submit@debbugs.gnu.org; Tue, 29 Sep 2020 07:56:02 -0400 Received: from eggs.gnu.org ([209.51.188.92]:34064) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kNEEh-0005IJ-I7 for 43668@debbugs.gnu.org; Tue, 29 Sep 2020 07:56:00 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:35970) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kNEEb-00022S-NV; Tue, 29 Sep 2020 07:55:53 -0400 Received: from [2001:980:1b4f:1:42d2:832d:bb59:862] (port=47624 helo=dundal.janneke.lilypond.org) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kNEEb-0002Ki-7F; Tue, 29 Sep 2020 07:55:53 -0400 From: Jan Nieuwenhuizen To: Ludovic =?utf-8?Q?Court=C3=A8s?= Subject: Re: bug#43668: Daemon tries to build GNU/Hurd derivations on GNU/Linux Organization: AvatarAcademy.nl References: <87a6xacmw5.fsf@inria.fr> <875z7ychvp.fsf@gnu.org> <87lfgurwaa.fsf@gnu.org> <87r1qlk4v6.fsf@gnu.org> X-Url: http://AvatarAcademy.nl Date: Tue, 29 Sep 2020 13:55:50 +0200 In-Reply-To: <87r1qlk4v6.fsf@gnu.org> ("Ludovic =?utf-8?Q?Court=C3=A8s=22'?= =?utf-8?Q?s?= message of "Mon, 28 Sep 2020 22:45:17 +0200") Message-ID: <877dsc3igp.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (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: 43668 Cc: 43668@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: Hi! > Jan Nieuwenhuizen skribis: > >>> Ludovic Court=C3=A8s skribis: >>> >> Displaying notes found in: .note.ABI-tag >> Owner Data size Description >> GNU 0x00000010 NT_GNU_ABI_TAG (ABI version tag) >> OS: Hurd, ABI: 0.0.0 > > Oh, well done, I browsed =E2=80=98file=E2=80=99 but didn=E2=80=99t find i= t. :-) >>> So I think we can=E2=80=99t count on an =E2=80=98execve=E2=80=99 error = and thus have to treat >>> this case (same architecture but different OS kernel) specially, as >>> shown below. >>> >>> Thoughts? >> >> If that really doesn't work...then yeah (yuck ;-) > > Yeah, I think we=E2=80=99ll have to do this hack (we=E2=80=99re not going= to parse ELF > files and all to determine whether to call =E2=80=98execve=E2=80=99.) Ah, we're C++; I was thinking Guile and "we surely have" an ELF library. That's allright then. Let's have this workaround. > (Besides, it would be interesting to understand how the libc/Hurd > startup code ends up segfaulting on GNU/Linux.) Hmm...are you saying something like "it could run until it wants to RCP Mach or Hurd?" Might it "just load" shared libraries... Greetings, Janneke --=20 Jan Nieuwenhuizen | GNU LilyPond http://lilypond.org Freelance IT http://JoyofSource.com | Avatar=C2=AE http://AvatarAcademy.com From debbugs-submit-bounces@debbugs.gnu.org Thu Oct 01 06:51:29 2020 Received: (at 43668-done) by debbugs.gnu.org; 1 Oct 2020 10:51:29 +0000 Received: from localhost ([127.0.0.1]:34242 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kNwBN-00037k-8D for submit@debbugs.gnu.org; Thu, 01 Oct 2020 06:51:29 -0400 Received: from eggs.gnu.org ([209.51.188.92]:59564) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kNwBL-00037V-9h for 43668-done@debbugs.gnu.org; Thu, 01 Oct 2020 06:51:27 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:52399) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kNwBF-00047W-Sm; Thu, 01 Oct 2020 06:51:21 -0400 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=37488 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1kNwBF-0006nA-8H; Thu, 01 Oct 2020 06:51:21 -0400 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Jan Nieuwenhuizen Subject: Re: bug#43668: Daemon tries to build GNU/Hurd derivations on GNU/Linux References: <87a6xacmw5.fsf@inria.fr> <875z7ychvp.fsf@gnu.org> <87lfgurwaa.fsf@gnu.org> <87r1qlk4v6.fsf@gnu.org> <877dsc3igp.fsf@gnu.org> X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 10 =?utf-8?Q?Vend=C3=A9miaire?= an 229 de la =?utf-8?Q?R=C3=A9volution?= X-PGP-Key-ID: 0x090B11993D9AEBB5 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 3CE4 6455 8A84 FDC6 9DB4 0CFB 090B 1199 3D9A EBB5 X-OS: x86_64-pc-linux-gnu Date: Thu, 01 Oct 2020 12:51:19 +0200 In-Reply-To: <877dsc3igp.fsf@gnu.org> (Jan Nieuwenhuizen's message of "Tue, 29 Sep 2020 13:55:50 +0200") Message-ID: <87sgayte1k.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (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: 43668-done Cc: 43668-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 (---) Hi, Jan Nieuwenhuizen skribis: >> Yeah, I think we=E2=80=99ll have to do this hack (we=E2=80=99re not goin= g to parse ELF >> files and all to determine whether to call =E2=80=98execve=E2=80=99.) > > Ah, we're C++; I was thinking Guile and "we surely have" an ELF library. > That's allright then. Let's have this workaround. Yeah. Even with a library, it doesn=E2=80=99t sound right to parse files beforehand. I think it=E2=80=99s up to the kernel to make the relevant che= ck, but perhaps there are good reasons why this isn=E2=80=99t happening here. Anyway, pushed as 9556ac498fd648147ad7d3b52ec86202d0a8e171! >> (Besides, it would be interesting to understand how the libc/Hurd >> startup code ends up segfaulting on GNU/Linux.) > > Hmm...are you saying something like "it could run until it wants to RCP > Mach or Hurd?" Might it "just load" shared libraries... Yeah I would expect it to run code up to the first Mach syscall but here it segfaults so maybe it crashes earlier. Ludo=E2=80=99. From unknown Fri Sep 05 11:02:24 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 29 Oct 2020 11:24:07 +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