X-Loop: help-debbugs@HIDDEN Subject: bug#63738: [PATCH glibc] Stop checking if MiG supports retcode. Resent-From: Joshua Branson <jbranso@HIDDEN> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> Resent-CC: bug-guix@HIDDEN Resent-Date: Fri, 26 May 2023 14:22:02 +0000 Resent-Message-ID: <handler.63738.B.1685110891592 <at> debbugs.gnu.org> Resent-Sender: help-debbugs@HIDDEN X-GNU-PR-Message: report 63738 X-GNU-PR-Package: guix X-GNU-PR-Keywords: patch To: janneke@HIDDEN Cc: guix-devel@HIDDEN, 63738 <at> debbugs.gnu.org X-Debbugs-Original-Cc: guix-devel@HIDDEN, bug-guix@HIDDEN Received: via spool by submit <at> debbugs.gnu.org id=B.1685110891592 (code B ref -1); Fri, 26 May 2023 14:22:02 +0000 Received: (at submit) by debbugs.gnu.org; 26 May 2023 14:21:31 +0000 Received: from localhost ([127.0.0.1]:50501 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1q2YJu-00009T-8F for submit <at> debbugs.gnu.org; Fri, 26 May 2023 10:21:31 -0400 Received: from lists.gnu.org ([209.51.188.17]:36016) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <jbranso@HIDDEN>) id 1q2YJr-00009J-T5 for submit <at> debbugs.gnu.org; Fri, 26 May 2023 10:21:28 -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 <jbranso@HIDDEN>) id 1q2YJq-0005zc-4K; Fri, 26 May 2023 10:21:26 -0400 Received: from mx1.dismail.de ([78.46.223.134]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <jbranso@HIDDEN>) id 1q2YJh-0007Ia-QB; Fri, 26 May 2023 10:21:25 -0400 Received: from mx1.dismail.de (localhost [127.0.0.1]) by mx1.dismail.de (OpenSMTPD) with ESMTP id faea2b21; Fri, 26 May 2023 16:21:12 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=dismail.de; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type:content-transfer-encoding; s=20190914; bh=cwEKkd4P rIVktczQoH5gl796j7lwKbQSEjSQHkN21DQ=; b=hfQkqEbx1FmIncKIr3WOMPb2 wZVIwrH3ax4tzlCuyZOtL58qcx5kh7YheOiqJ/Bf4Wam75ewwNL87XkLDUXnUBZt JT+9KQ7kv2h3FWZdDsAev1c4eFN13Qaq8nN+jqxnB/yw9EsAAVfOxxlDsqmQGtny 3Tr5l7ja7KT3ROSIqpRCoueujybB/3OmWRi4zBNjdzbutQ/Xyr1CzJh2KavHNjos tXXgVi809xKIJjE7inYlG1+WILmUXSnJPiPNZDUeCS/+Wl6xd2i1oD2sAUxVaFBM GuqwQtDljLYq/nKFTGksAuPX+I0QUxSMQpAhcM+WFwqT8UaD75W4RXZUx5NdMA== Received: from smtp2.dismail.de (<unknown> [10.240.26.12]) by mx1.dismail.de (OpenSMTPD) with ESMTP id 9c689108; Fri, 26 May 2023 16:21:11 +0200 (CEST) Received: from smtp2.dismail.de (localhost [127.0.0.1]) by smtp2.dismail.de (OpenSMTPD) with ESMTP id ce8b35f2; Fri, 26 May 2023 16:21:11 +0200 (CEST) Received: by dismail.de (OpenSMTPD) with ESMTPSA id 484d9236 (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Fri, 26 May 2023 16:21:10 +0200 (CEST) From: Joshua Branson <jbranso@HIDDEN> References: <ZFspor91aoMwbh9T@HIDDEN> <CAN9u=HfUw2-6b2Ac4sCG8OhLKBdHVD9b3OsVOQHmVKkRJdquCw@HIDDEN> <CAKwpGPwkdur-cwohF9=Ww_kbs3A8-iK+=E8y3V-Gr3JnmgpF8Q@HIDDEN> <CAN9u=HcwiHAZYsXDZq1qV3-GcJujZPc996CvCZLmkTtKNwazHA@HIDDEN> <CAKwpGPw8ciD3kztwQ=5zgSspxbdwhwafHdsGa1Pyoj9zsQg-jw@HIDDEN> <CAN9u=Hf+BmVMf+PrQp9moognbarvjcf0K6Ss2uba5UeFSBi7Og@HIDDEN> <CAKwpGPyRazwJEjXwQgQj+j8gdn3WS-TuLmrBv8vAZQu5qWpPaA@HIDDEN> <CAN9u=HcXtT3j+hwrhzFT-VfH8grZ50WHgDpTNahVaYuYC_OhuQ@HIDDEN> <CAKwpGPyXf0LaUH3Mgwqq1duG0O6xUcEuzYRAfQiJmsqgicS+oQ@HIDDEN> X-Gnus-Sucks: I know man Date: Fri, 26 May 2023 10:21:04 -0400 In-Reply-To: <CAKwpGPyXf0LaUH3Mgwqq1duG0O6xUcEuzYRAfQiJmsqgicS+oQ@HIDDEN> ("=?UTF-8?Q?Fl=C3=A1vio?= Cruz"'s message of "Fri, 26 May 2023 08:00:00 -0400") Message-ID: <87353jb2cv.fsf@HIDDEN> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=78.46.223.134; envelope-from=jbranso@HIDDEN; helo=mx1.dismail.de X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.4 (-) X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -2.4 (--) Hey guix people! The Hurd developers having a 64 bit Hurd that can run /bin/sh. The below are some tips for how to set up such a thing if you were so inclined. The Debian people are providing 64-bit hurd applications here for now: https://people.debian.org/~sthibault/tmp/hurd-amd64 Fl=C3=A1vio Cruz <flaviocruz@HIDDEN> writes: > Hi Sergey > > On Fri, May 19, 2023 at 4:02=E2=80=AFAM Sergey Bugaev <bugaevc@HIDDEN>= wrote: > > Hi, > > On Fri, May 19, 2023 at 9:43=E2=80=AFAM Fl=C3=A1vio Cruz <flaviocruz@gma= il.com> > wrote: > > I have made changes so that it does daily builds and I'm able to boot > small programs. However, I haven't had the time to boot programs built > against Glibc. How do you package and boot the static binaries using a > ramdisk? I've been reading the other threads about the Guix/rumpkernel > so I might be able to piece something together and try it this weekend. > > You just put the entirety of the root filesystem (containing /usr, > /bin, /lib, /hurd, and so on) as an ext2 image into a *file* that you > place onto the actual drive (a CD disk in my case), and then you ask > GRUB to load the file from the drive into memory, tell gnumach to make > a ramdisk device out of it (you'll need to apply [0]), and tell ext2fs > to use that device. Here's the relevant piece of my grub config > script: > > [0]: > https://salsa.debian.org/hurd-team/gnumach/-/blob/master/debian/patches/= 50_initrd.patch >=20=20 > > multiboot /boot/gnumach console=3Dcom0 > module /boot/initrd.ext2 initrd.ext2 '$(ramdisk-create)' > module /sbin/ext2fs.static ext2fs > --multiboot-command-line=3D'${kernel-command-line}' --readonly > --host-priv-port=3D'${host-port}' --device-master-port=3D'${device-port}' > --exec-server-task=3D'${exec-task}' --kernel-task=3D'${kernel-task}' -T > device rd0 '$(fs-task=3Dtask-create)' '$(prompt-task-resume)' > module /lib/ld.so.1 ld.so.1 /hurd/exec > --device-master-port=3D'${device-port}' '$(exec-task=3Dtask-create)' > boot > > (I should probably change it to not hardcode 'rd0', but whatever). > Note that /boot/gnumach, /boot/initrd.ext2, /sbin/ext2fs.static, and > /lib/ld.so.1 are all paths inside the CD image (those are going to be > loaded by GRUB), and /boot/initrd.ext2 is the ext2 filesystem image > containing the actual Hurd root. /hurd/exec however is already a path > inside the fs image -- this is where ld.so (not grub) is going to load > the exec server from. The only static binary here is ext2fs.static, > the rest are all dynamically linked. > > Then in /libexec/console-run (inside the filesystem image), I have > written the following: > > #! /bin/sh > > settrans -ac /dev/mach-console /hurd/streamio console > exec <>/dev/mach-console >&0 2>&0 > echo Hello from /bin/sh! > exec /bin/sh -i > > (If you're going to do the same, don't forget to create the > /dev/mach-console node beforehand, since the fs is read-only.) I also > had to patch streamio a little to do the \r -> \n conversion like > glibc already does in devstream: > > diff --git a/trans/streamio.c b/trans/streamio.c > index 272a002c..0af1aea3 100644 > --- a/trans/streamio.c > +++ b/trans/streamio.c > @@ -500,6 +500,9 @@ trivfs_S_io_read (struct trivfs_protid *cred, > cred->po->openmodes & O_NONBLOCK); > pthread_mutex_unlock (&global_lock); > *data_len =3D data_size; > + for (size_t i =3D 0; i < data_size; i++) > + if ((*data)[i] =3D=3D '\r') > + (*data)[i] =3D '\n'; > return err; > } > > (maybe I should also add echoing of input characters in the same way, > which is also what glibc's devstream does -- otherwise currently I > don't see what I'm typing on the console). > > Make sure to use the very latest glibc (Samuel has already pushed all > of my patches upstream!) + the BRK_START hack. > > Thanks for the instructions. I was able to make it work and pushed my > changes to Github. > > For people that might want to try out the new port using > https://github.com/flavioc/cross-hurd, > the following will download the packages and build a disk image with the = ram > disk: > > $ export CPU=3Dx86_64 > $ bash download.sh && bash bootstrap.sh && bash compile.sh && bash > create-initrd.sh > > Then, to run qemu: > > $ bash start-qemu-debug.sh > > Sergey > --=20 Joshua Branson Sent from the Hurd
Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) Content-Type: text/plain; charset=utf-8 X-Loop: help-debbugs@HIDDEN From: help-debbugs@HIDDEN (GNU bug Tracking System) To: Joshua Branson <jbranso@HIDDEN> Subject: bug#63738: Acknowledgement ([PATCH glibc] Stop checking if MiG supports retcode.) Message-ID: <handler.63738.B.1685110891592.ack <at> debbugs.gnu.org> References: <87353jb2cv.fsf@HIDDEN> X-Gnu-PR-Message: ack 63738 X-Gnu-PR-Package: guix X-Gnu-PR-Keywords: patch Reply-To: 63738 <at> debbugs.gnu.org Date: Fri, 26 May 2023 14:22:02 +0000 Thank you for filing a new bug report with debbugs.gnu.org. This is an automatically generated reply to let you know your message has been received. Your message is being forwarded to the package maintainers and other interested parties for their attention; they will reply in due course. Your message has been sent to the package maintainer(s): bug-guix@HIDDEN If you wish to submit further information on this problem, please send it to 63738 <at> debbugs.gnu.org. Please do not send mail to help-debbugs@HIDDEN unless you wish to report a problem with the Bug-tracking system. --=20 63738: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D63738 GNU Bug Tracking System Contact help-debbugs@HIDDEN with problems
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.