IRC channel logs
2024-01-23.log
back to list of logs
<Googulator>it would be much better to just ship that one file <stikonas>well, right now just GTS Root R1 certificate is sufficient to download rest of ca-certificates <stikonas>but that's depending on them keeping to the same cert <fossy>mm, ca certificates are one of those things that will inheriently break at some point in the future :\ <stikonas>but by shipping just one we risk breaking a bit more frequently <stikonas>as server admins in general are free to change certificate providers <fossy>"An unfortunate blemish is that we number build scripts from 1, but repo tarballs from 0 - it would be nice to standardize on a single indexing convention." <fossy>Googulator: you make a good point, actually <fossy>not one i had ever thought of, to be honest! <fossy>i had in my brain, pass1.sh is "1st pass", pass2.sh is "2nd pass", ... <fossy>and revision is a counter, so it should start from 0 <fossy>but you're right, it's not very logical <fossy>yeah perhaps revision should start at 1 <oriansj>wouldn't the let's encrypt certificate work too? as we could host an updated set of root certs which then we update on a yearly basis, should limit the breakage. <oriansj>as they tend to give lots of warning to root cert changes. <stikonas>yeah, we could host ca-certificates there... <nimaje>hm, there is an incomplete public domain libc, maybe some of it can be integrated into meslibc <nimaje>I didn't look how they compare, I expected that it at least has some stuff that meslibc has not, but it also has a tabel of libc comparisions at the bottom of the readme <matrix_bridge><Andrius Štikonas> Well there might be some things. But then you can just steal them from any other libc <Googulator>Mikaku: are virtual consoles (i.e. Ctrl+Alt+F2) supported in Fiwix? <Mikaku>Googulator: yes, up to 12 virtual consoles <Googulator>Is there a way to activate them before we can build kbd? <Mikaku>they are already enabled, you just need to run *getty on them <Googulator>I was thinking the equivalent of "openvt -- bash -i" <Mikaku>kernel won't give you such a service, this belongs to user land <Googulator>I mean, what is the "magic" (some system call or IOCTL I presume) that getty does to enable Ctrl+Alt+F[n]-ing to that console? I presume simply opening the relevant TTY and trying to talk over it isn't enough. <Googulator>i.e. one can't just redirect I/O to /dev/tty2 and expect Ctrl+Alt+F2 to work <Mikaku>well, yes, you need to open(/dev/tty2", ...) to be able to read/write on it <Googulator>But is that enough to enable the key combination? <Mikaku>oh yes, you can redirect anything you want there, it will work <Googulator>you have to issue a "magic" IOCTL, otherwise Linux will ignore Ctrl+Alt+F2 <Mikaku>Linux doesn't permit you to switch to an unopened virtual console, but as soon as you redirects something to them then you can switch to it <Mikaku>Fiwix permits you switch to any virtual console, don't need to previously redirect something to it <Mikaku>I tested on the old Linux version 2.0, don't know if this changed on newer Linux kernels <Googulator>strange, I seem to remember testing (on a newer kernel), simply doing "echo test > /dev/tty2" doesn't enable Ctrl+Alt+F2 <Googulator>Ctrl+Alt+F2 remains ignored after that simple test <Mikaku>you mean that you cannot switch to tty12? <Mikaku>with older kernels it worked as it <Googulator>If I then use openvt or getty on it, I can then switch, and see that "test" did in fact get printed - but some poorly documented "magic" is clearly needed <Googulator>oriansj: do you know why bash-2.05b was picked for the early shell, from all versions? <Googulator>2.05b is unfortunately the last version not to support "set -E" <matrix_bridge><Andrius Štikonas> We picked it because guix used that in bootstrap <Googulator>-i mode is kind of broken right now because of this - it doesn't crash, but has a nasty side effect of checksum failures not trapping until the 2nd bash is built <Googulator>so "-i" will spuriously succeed if one of the early packages has a bad checksum without --update-checksums <matrix_bridge><Andrius Štikonas> We should try to rebuild bash earlier.... <matrix_bridge><Andrius Štikonas> Once musl and I guess autotools are avaable <Googulator>Strangely there is a pass2 script included with bash-2.05b, but it's unused <Googulator>and I haven't seen any point in the history where it was used <Googulator>looks like redirecting bash to /dev/tty2 does work in Linux <rickmasters>Doing an earlier bash 5 was reverted because I couldn't get it to build on Fiwix. That was holding up kernel bootstrap integration. <Googulator>Mikaku: testing multiconsole now in Fiwix 1.5.0-lb1 - looks like there's a weird bug <Googulator>Bash did start on the 2nd console, but the build output gets printed on whatever console I switch to <Mikaku>Googulator: did you set the console to /dev/tty0? <Mikaku>if the output is redirected to /dev/console then it will appear on the current tty <rickmasters>It turns out that I removed the rebuild of bash 2.05b in the commit for kernel-bootstrap: <rickmasters>Unfortunately, I cannot remember why I did that. It may have been a mixup with how we reverted bash 5 in that location. <stikonas>in any case, might be worth attempting to readd it <rickmasters>It may be that I somehow discovered we didn't really need to rebuild it and thought it was simpler without it. <rickmasters>stikonas: Do you remember why we rebuilt it? It involved transitioning to run2.sh to it wasn't without complication so I'm assuming there was a reason in the first place for it. <stikonas>oh it was just to have interactive bash earlier <stikonas>rather than just error out with subprocess error <rickmasters>ok, so there was something in a dependency that enabled that? <matrix_bridge><Andrius Štikonas> And first version is built with custom makefile and minimal features <lrvick>Is there any particular reason for the whole coreutils/curl stack in live-bootstap and friends? I have been building kernel, binutils, gcc, musl, and even all the way up to rust 1.74 with just busybox as a base. <lrvick>given I hashlock everything even busybox wget has been fine <rickmasters>lrvick: not sure I understand. live-bootstrap can build from "scratch" so it won't presume having busybox to start with. <rickmasters>The idea is to strictly limit the seed binaries to start with. Currently that's down to a single binary boot sector and everything else must be source code. <rickmasters>Of course there is a ton of python code to prepare the boot disk image but in theory that could be done "manually". <rickmasters>stikonas: So bash-2.05b does not rebuild on Fiwix. There are faults in configure, related to signals. <stikonas>so ./configure exists with non-zero code? <rickmasters>It's general protection faults. Its funny because I was complaining about the upgrade to bash 5 but bash 2 didn't work either. <rickmasters>Its making me think that I dropped the rebuild on accident and somehow thought it was working... <rickmasters>I'm not sure. But I can give it another shot. I've got more time now. <stikonas>I would look myself, but quite busy with all other bootstrapping stuff... <rickmasters>Actually it's faults in configure and then later it faults on bison -y -d ./parse.y <Googulator>Mikaku: I believe the main build is running with no redirection at all <Googulator>When Fiwix is booted via kexec-fiwix, it executes /init (explicitly set via custom_kernel.h), which is actually a binary of kaem <stikonas>we want it to run on simple kernels too (i.e. builder-hex0) <Googulator>kaem.run calls /steps/1.sh (actually a kaem script, not a bash one), which builds bash, then calls the next stage as "bash /steps/2.sh" <Googulator>2.sh then sources /steps/improve/open_console.sh, which hooks up a "fake-interactive" bash shell directly to tty2 <Googulator>the exact command is bash -c 'while true; do printf "[early Bash - use Ctrl+D] $(pwd) # "; $(cat /dev/tty2); done' &> /dev/tty2 & <Googulator>in fact, the file /dev/console doesn't even exist until right before open_console.sh is sourced <Googulator>so it appears Fiwix is wrongly defaulting to /dev/console instead of /dev/tty1 for init output <Googulator>hmm, it could actually be kexec-fiwix instead that messes up <Googulator>in kexec-fiwix, we pass "console=/dev/ttyS0" in qemu mode <Googulator>but in bare metal mode (where virtual terminals are actually relevant), we pass no "console=" at all <Googulator>which is apparently a shorthand for the current console, just like /dev/console (?)