unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Jan Nieuwenhuizen <janneke@gnu.org>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: Timothy Sample <samplet@ngyro.com>, 38390@debbugs.gnu.org
Subject: [bug#38390] [core-updates] Scheme-only bootstrap: merge wip-bootstrap
Date: Wed, 18 Dec 2019 23:55:13 +0100	[thread overview]
Message-ID: <87o8w5gs6m.fsf@gnu.org> (raw)
In-Reply-To: <878sncm5od.fsf@gnu.org> (Jan Nieuwenhuizen's message of "Mon, 16 Dec 2019 20:28:02 +0100")

Jan Nieuwenhuizen writes:

Hi,

A new step forward.

>>>>   * look into awkward combined bash+gash dependency of glibc-mesboot0
>>>
>>> Haven't addressed this.  I quickly looked with Ludo at this, not really
>>> into it though.  WYDT?
>>
>> Hmm, dunno.  I can take a look later.
>
> Okay, great.  This issue still remains.  I will try to create a bug
> report for Gash, I think Gash hangs while running configure, while
> bash-mesboot* have trouble running make-syscalls.sh correctly.

Good news.  bash-mesboot0 now compiles with either gash+gash-core-utils,
or with bash-mesboot0.

Gash' "test -L FILE" used to crash on non-existing files, not sure why
that made configure hang; but that's how I found and fixed it.

The problem with bash-mesboot0 turned out to be a Mes C Library problem,
related to buffered reads.  Buffered reads were introduced when working
on the Hurd.

Not clearing the read buffer on lseek, when lseek is not allowed (bash
uses the same: lseek (FD, 0, SEEK_CUR) to find out if it may seek),
fixes the problem.  That took me a couple of days to find, but very
happy 

--8<---------------cut here---------------start------------->8---
diff --git a/lib/linux/lseek.c b/lib/linux/lseek.c
index 94f2f9f7a..f71af59f5 100644
--- a/lib/linux/lseek.c
+++ b/lib/linux/lseek.c
@@ -24,9 +24,21 @@
 #include <stdio.h>
 #include <sys/types.h>
 
+#if !__MESC__ /* FIXME: We want bin/mes-mescc's x86-linux sha256sum to stay the same. */
+off_t
+_lseek (int filedes, off_t offset, int whence)
+{
+  return _sys_call3 (SYS_lseek, (int) filedes, (long) offset, (int) whence);
+}
+#endif
+
 off_t
 lseek (int filedes, off_t offset, int whence)
 {
+#if !__MESC__ /* FIXME: We want bin/mes-mescc's x86-linux sha256sum to stay the same. */
+  if (_lseek (filedes, 0, SEEK_CUR) == -1)
+    return -1;
+#endif
   size_t skip = __buffered_read_clear (filedes);
   if (whence == SEEK_CUR)
     offset -= skip;
--8<---------------cut here---------------end--------------->8---

Greetings,
janneke

-- 
Jan Nieuwenhuizen <janneke@gnu.org> | GNU LilyPond http://lilypond.org
Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.com

  reply	other threads:[~2019-12-18 22:56 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-26 16:38 [bug#38390] [core-updates] Scheme-only bootstrap: merge wip-bootstrap Jan Nieuwenhuizen
2019-12-01 14:01 ` Ludovic Courtès
2019-12-01 16:25   ` Timothy Sample
2019-12-01 16:55     ` Jan Nieuwenhuizen
2019-12-01 17:14     ` Ludovic Courtès
2019-12-01 17:21   ` Jan Nieuwenhuizen
2019-12-06  6:53     ` Jan Nieuwenhuizen
2019-12-07 22:31       ` Ludovic Courtès
2019-12-11 18:25       ` Jan Nieuwenhuizen
2019-12-15 21:33         ` Ludovic Courtès
2019-12-15 22:39           ` Timothy Sample
2019-12-15 22:45             ` Brett Gilio
2019-12-16  6:34             ` Jan Nieuwenhuizen
2019-12-16 19:28           ` Jan Nieuwenhuizen
2019-12-18 22:55             ` Jan Nieuwenhuizen [this message]
2019-12-19 11:08               ` Ludovic Courtès
2020-02-03 17:37 ` [bug#38390] [bug #38390] Building bootstrap Gash and Gash-Utils Timothy Sample
2020-02-05  8:58   ` Ludovic Courtès
2020-02-05 14:32     ` Timothy Sample
2020-02-05 21:33       ` Ludovic Courtès
2020-02-06 22:58         ` Jan Nieuwenhuizen
2020-02-07 11:00           ` Ludovic Courtès
2020-02-08 17:33             ` Timothy Sample
2020-02-08 22:32               ` Jan Nieuwenhuizen
2020-02-10  2:23                 ` Timothy Sample
2020-02-11 13:56               ` Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87o8w5gs6m.fsf@gnu.org \
    --to=janneke@gnu.org \
    --cc=38390@debbugs.gnu.org \
    --cc=ludo@gnu.org \
    --cc=samplet@ngyro.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).