Re: Problems with recent versions of s6-rc

2017-06-04 Thread Laurent Bercot
Hello, is there any progress on this issue? We have confirmed that it is an Alpine problem. We're not sure exactly where the problem occurs (the usual suspect, grsec, has been innocented), but we know it's related to the Alpine package build and to virtualization. In any case, the s6-rc code

[announce] s6-2.6.0.0

2017-06-15 Thread Laurent Bercot
Hello, s6-2.6.0.0 is out. It fixes a race condition that could lead s6-svwait/s6-svlisten/s6-svlisten1 to miss back-to-back state changes. (Sorry about that.) Unfortunately, the fix required change to some externally visible ABI, so it enforces a major version bump. External binaries

Re: Issues with cross compilation

2017-05-03 Thread Laurent Bercot
I finally managed to get execline to compile - turns out there was an error in the options I had passed to configure: I'm relieved. If it had been a bug, it would have been quite nasty to solve. ;) Thanks for the info. -- Laurent

Re: [PATCH] Fix openreadnclose failing if errno was nonzero before

2017-05-24 Thread Laurent Bercot
Just to be sure, I released skalibs-2.5.1.1, so there's a stable version with that bug fixed. Update: the 2.5.1.0 bug breaks s6-rc-update pretty badly, so upgrading to skalibs-2.5.1.1 is highly recommended. -- Laurent

Re: s6-envdir bug/behavior change

2017-05-21 Thread Laurent Bercot
This change is intended. Laurent had never meant for s6-envdir to ignore directories, the previous behaviour was just a coincidence. When I made him asked him about this last week, he immediately made the parsing code in skalibs stricter. To be more precise: the fact that directories were

[announce] skarnet.org migrating

2017-09-16 Thread Laurent Bercot
Hello, Due to a datacenter closing in the future, the alyss.skarnet.org server is migrating. Expect some perturbations while I fix the inevitable problems that will occur, and while the DNS caches are updating. Sorry for the inconvenience - I'm doing my best to minimize it. -- Laurent

Re: optional -fstack-protector

2017-10-05 Thread Laurent Bercot
Any chance you'd be willing to accept a patch like this to let the user choose an -fstack-protector variant instead of hardcoding no? The default behaviour is of course unchanged. If you add a -fstack-protector option to CFLAGS, it will override the default of no. Isn't that enough? --

Re: optional -fstack-protector

2017-10-06 Thread Laurent Bercot
Yes, I obviously don't want to replace CFLAGS or CPPFLAGS whole-sale, as there might actually be necessary options in there, and I certainly don't want to pick those out and have to provide them manually. I'm currently making changes to the configure script and Makefile that should have the

Re: [PATCH] s6-rc-update: avoid getrandom(2)

2017-10-04 Thread Laurent Bercot
s6-rc: 0.0.2.1 s6: 2.2.4.3 skalibs: 2.3.9.0 Yeah, all bets are off with those versions - in particular the old skalibs, a lot of bugs have been fixed since then. I'll release a new s6-rc before next week; and if the s6-rc-init crash happens again then I'll look into it. -- Laurent

[announce] Bugfix releases; s6-rc-0.3.0.0

2017-10-09 Thread Laurent Bercot
Hello, skalibs, execline and s6 just received bugfix releases. Nothing serious; the most important thing is probably that it's now easier to append or override build-time flags via CPPFLAGS, CFLAGS and LDFLAGS. Also, mkstemp() is used when appropriate, which allows more functions to be used

Re: optional -fstack-protector

2017-10-05 Thread Laurent Bercot
Well, for skalibs in particular, that happens to work, since you (for some reason) add -fno-stack-protector to CPPFLAGS, and CFLAGS happens to come after in the compile rule. But for e.g. s6 and s6-rc, you append fno-stack-protector to CFLAGS, so it doesn't matter what CFLAGS contained at

Re: Occasional crash in s6-rc-init / s6rc_servicedir_manage()

2017-09-26 Thread Laurent Bercot
I've at least twice have s6-rc-init crash due to an assert fail in glibc. On the first occasion, I got Thanks for the report. Will investigate as soon as I can. -- Laurent

Re: [PATCH] s6-rc-update: avoid getrandom(2)

2017-09-26 Thread Laurent Bercot
On a modern linux system, s6-rc-update ends up calling getrandom(2) via the random_sauniquename() library function. But on embedded systems, and especially during early initialization, that is likely to block, which means that the entire boot process hangs. Yes. That's a feature. You

Re: [PATCH] s6-rc-update: avoid getrandom(2)

2017-09-30 Thread Laurent Bercot
In the latest s6-rc git, s6-rc-update now creates its new livedir with mkdtemp() and does not use any cryptographically strong random number generation. Please test it and tell me if it works for you. -- Laurent

Re: PEBKAC prevention with s6-rc

2017-09-30 Thread Laurent Bercot
I think the update makes it clear enough to me, but I did not find any update on the recompilation issue. https://skarnet.org/software/s6-rc/upgrade.html ? -- Laurent

Re: PEBKAC prevention with s6-rc

2017-09-30 Thread Laurent Bercot
This is certainly an inexcusable PEBKAC; however, the cause was not really obvious from the error output of the s6-rc programs. So perhaps we can make the error messages more indicative; or if that requires too much additional complexiy, emphasise in the s6-rc documentation that the service db

Re: PEBKAC prevention with s6-rc

2017-09-30 Thread Laurent Bercot
I see; I think this version is OK, but the update seems to be absent from the git repository? Whoops! Sorry, fixed. :) -- Laurent

Re: [PATCH] s6-rc-update: avoid getrandom(2)

2017-10-03 Thread Laurent Bercot
Do you plan to do a bugfix release soon'ish? I can do one some time later this week if you need it. However, if it's not urgent, I'd like some time to investigate the s6-rc-init crash you reported, if it's still happening for you. I cannot reproduce it so far. -- Laurent

[announce] skarnet.org August 2017 release

2017-08-28 Thread Laurent Bercot
Hello, New releases of most skarnet.org packages are available; these are mostly bugfix releases, but there are a few new features. skalibs had to change an interface to fix a bug, which explains the major version bump. * skalibs-2.6.0.0 --- - Bugfixes, including a

Re: [PATCH] s6-rc-update: avoid getrandom(2)

2017-09-27 Thread Laurent Bercot
src/librandom/random_makeseed.c says that that's precisely the point; I was quoting verbatim. Ah, indeed. My mistake. Full disclosure: at first I wanted to speed up the /dev/urandom initialization. Then, after careful re-reading of the Linux man pages, I realized it wouldn't work; but I found

[announce] mdevd-0.0.1.0 - a mdev-compatible uevent manager

2017-10-23 Thread Laurent Bercot
Hello, About two years ago, there was some talk on the Busybox mailing-list about the need for a version of "mdev" that would not use a separate process for every uevent (as a hotplug manager does) but that would act as a daemon, able to handle a series of uevents - typically read from the

Re: .env file handling

2017-10-24 Thread Laurent Bercot
I tried rewriting the whole thing in execline and while I'm pretty sure it's doable it's not easy. A direct translation of Casper's script to execline could be: #!/command/execlineb -P backtick LIST { cat /path/to/xyz.env } importas -nsd"\n" LIST LIST env -i ${LIST} /path/to/xyz It's not as

Re: [announce] mdevd-0.0.1.0 - a mdev-compatible uevent manager

2017-11-15 Thread Laurent Bercot
"Applications should not access sysfs" doesn't mean there should be only one version of the intermediate library. There's already Systemd-Udev and Eudev versions, at least. For the case of Xorg, it just means sysfs access should not be hard-coded in the source of Xorg, but there should be

[announce] Some November releases

2017-11-27 Thread Laurent Bercot
Hello, New releases of some skarnet.org packages are available. Those are preparation features for future releases, bugfixes, or compatibility improvements (for MacOS, for default-PIC toolchains). * skalibs-2.6.2.0 * execline-2.3.0.4 * s6-2.6.2.0 * s6-rc-0.3.0.1 There's only one point

Mailing-lists, failing probes, unsubscriptions

2017-11-30 Thread Laurent Bercot
Hello, The skarnet.org mailing-lists use a probing system to automatically unsubscribe addresses that don't work anymore. When an address fails 3 consecutive times, it gets removed. In the past year, or sometimes at an older time than that, a lot of addresses have apparently failed enough

Re: Mailing-lists, failing probes, unsubscriptions

2017-11-30 Thread Laurent Bercot
This kind of mass unsubscription is often due to DMARC. Ah, thanks. Time for me to understand how DMARC works, then, and make ezmlm work with it. Sigh. E-mail gets more and more broken every year; soon it will just become impossible to run a list. -- Laurent

Re: SIGFPE in s6-rc-init 3.0.0 etc,...

2017-12-15 Thread Laurent Bercot
I noticed in the kernel log that the module was in fact correctly loaded, but s6 was stuck waiting for something (I noticed this process when doing a "ps"): 1213 root s6-ipcserverd -1 -- s6-ipcserver-access -v0 -E -l0 -i data/rules -- s6-sudod -t 2000 -- /usr/libexec/s6-rc-oneshot-run -l

Re: [announce] mdevd-0.0.1.0 - a mdev-compatible uevent manager

2017-11-16 Thread Laurent Bercot
I fully understand that this list is focused on good programming practice and libudev is considered something disgusting in that respect. My question was triggered by the frustration, probably shared by many, of not being able to replace Udev by Mdev or Mdevd, only because Xorg autoconfig

Re: [announce] mdevd-0.0.1.0 - a mdev-compatible uevent manager

2017-11-12 Thread Laurent Bercot
Will there be a plan to add something roughly isomorphic to libudev? Not in the short or medium term. The problem of libudev, and this is shared by everything from freedesktop.org as well as systemd, is that its design and structure cannot be achieved without a monolithic implementation, and

Re: http://skarnet.org/toolchains/cross/ not found

2017-11-02 Thread Laurent Bercot
I came across this http://skarnet.org/software/lh-bootstrap/. As I am interested, I have looked for a x86_64-to-ramips toolchain I don't have MIPS toolchains :/ If you know the exact gcc building flags needed to make one, I can easily build one. And if you know the correct set of sysdeps to

Re: salted

2017-11-07 Thread Laurent Bercot
I was thinking of other applications of NaCl, like encrypting files to keep in a computer, rather than network stuff. You can still use NaCl for this. But salted was all about networking. -- Laurent

Re: Where does /dev get mounted?

2017-10-30 Thread Laurent Bercot
But I do have a question: as documented, I find that when stage1's child process execs into stage2, there is a devtmpfs mounted at /dev. I don't understand where this happens! I see where the stage 1 script mounts a tmpfs at /run, but I don't see anything there, or in the initial s6 scandir,

Re: execline-in-execline

2018-06-06 Thread Laurent Bercot
``` #!execline define url example.com s6-tcpclient $url 80 execlineb " foreground { fdmove 1 7 echo -en \"…\" fdmove 0 6 cat } " ``` I have trouble understanding what you want to do in the general case, because in this example, s6-tcpclient takes a whole command line, so you do not have to

Re: SIGFPE in s6-rc-init 3.0.0 etc,...

2017-12-23 Thread Laurent Bercot
Thanks. It confirms what I had figured out (something's wrong in the way gensetdyn_ready() computes its new size) Well I just noticed you're linking against libskarnet.so.2.5.1.1. As I said before, it is a *known bug* in skalibs-2.5.1.1, which has been fixed in 2.6.0.0. Please try with the

Re: SIGFPE in s6-rc-init 3.0.0 etc,...

2017-12-23 Thread Laurent Bercot
I was able to build the image for my target system and run it in qemu and still reproduce the problem. I first ran it through valgrind which pinpoints a few possible issues: http://steffe.net/s6/valgrind_nodebug.txt Then I ran it through gdb and just did a "bt", let me know if I can help you

Re: [announce] mdevd-0.0.1.0 - a mdev-compatible uevent manager

2018-01-09 Thread Laurent Bercot
Thing is, before writing to that uevent, there was nothing of the sort in /sys/dev. What it looks like is the kernel not assigning a major and a minor to the device before you manually trigger the "add". I suspect it's just that the relevant module is not loaded, but why would that be

Re: [announce] mdevd-0.0.1.0 - a mdev-compatible uevent manager

2018-01-08 Thread Laurent Bercot
However, somewhat recently I believe I heard (read) you say on IRC that the recommended way was actually the other way around, so I switched to start netlinkd first, and then run coldplug. Well, it's really up to you. The thing is, if you coldplug first then listen to the netlink, you have a

Re: tests

2018-01-11 Thread Laurent Bercot
I was thinking about unit test to test your functions, and building your code and installing it into a Docker container. That's the very point: s6 is organized into several small executables interacting together, so unit tests for functions are pretty difficult to write. The units that would

[announce] January 2018 release: happy new year from skarnet.org

2018-01-04 Thread Laurent Bercot
Hello, New releases of some skarnet.org packages are available, including major version releases to s6 and s6-rc. * skalibs-2.6.3.0 --- - Bugfixes. - Lots of new functions, including the textclient library, which is a simpler IPC library than skaclient for processes that

Re: [announce] mdevd-0.0.1.0 - a mdev-compatible uevent manager

2018-01-15 Thread Laurent Bercot
And to answer your question, about what could cause such a burst of events, this time I have an easy answer: mdevd-coldplug ! Yes, I forgot to mention this. The kernel-generated events seem to be significantly heavier than the mdev-style synthetic ones. The DEVPATH is the full path without

Re: skalibs: issue with strnlen() when statically linking with uclibc-ng

2018-01-15 Thread Laurent Bercot
Thanks! skalibs-2.6.3.1 released. -- Laurent

Re: skalibs: issue with strnlen() when statically linking with uclibc-ng

2018-01-13 Thread Laurent Bercot
> Would this difference explains why there is no redefinition linking > error with musl, or am I missing something? I don't know. I will ask people who know. It is strange indeed; I didn't even notice that the strnlen sysdep was "no" with musl, else I would have fixed it... What is the

Re: [announce] mdevd-0.0.1.0 - a mdev-compatible uevent manager

2018-01-12 Thread Laurent Bercot
It might be worth to look at what systemd [1] and eudev [2] do here. When 'udevadm trigger --type=devices --action=add' is performed after the udev daemon starts executing, it looks like what happens is basically this: Thanks a lot for studying this. That's what I was going to do, but I

Re: Little correction on fdmove doc

2018-07-29 Thread Laurent Bercot
I've found the command intuitive but the documentation confused me a little bit. So here's a patch. ISTR you actually submitted the same thing a few months ago and I did not react. Sorry, I should have replied sooner. The documentation is correct and I won't apply the patch. But it's not

Re: execlineb -S does not stop the command from running

2018-07-29 Thread Laurent Bercot
`execline` does indeed exits when not given arguments, and displays the error `execlineb: warning: too few arguments: expecting at least 1 but got 0` but the first command gets run. ``` $ execlineb -S1 -c 'echo wrong' execlineb: warning: too few arguments: expecting at least 1 but got 0 wrong

Re: When running from a script execlineb does not use separated args

2018-07-31 Thread Laurent Bercot
#!/bin/execlineb -W -S 1 You're running into an unfortunate side effect of shebang lines where only the first argument is available. Exactly. Shebang parsing is done by the kernel, which does not have a complete command line parser. (If it had, the execlineb program would be redundant: we

[announce] skarnet.org Summer 2018 release

2018-08-14 Thread Laurent Bercot
Hello, New releases of some skarnet.org packages are available, as well as a new package. * skalibs-2.7.0.0 --- This is a major version release of skalibs, so compatibility with previous versions is not guaranteed. Make sure to also upgrade the rest of the skarnet.org

Re: [announce] skarnet.org Summer 2018 release

2018-08-22 Thread Laurent Bercot
Oh. That's kind of drastic. I re-read the documentation of nsss and utmps, in case I missed it the first time, and still think none of it suggests that this is the intended behaviour. You're right, the documentation should mention that libc header files will be replaced. I'll add something.

Re: execline globbing

2018-07-24 Thread Laurent Bercot
That brings me to another question: is there a collection of more execline utilities somewhere? I suspect the standard GNU coreutils are not quite to your liking in a lot of cases. The execline package has all the execline-specific utilities you need to perform execline scripting (although if

Re: execline: returning something from ifthenelse blocks

2018-07-24 Thread Laurent Bercot
So I’d like to have an ifthenelse and return the same envvar from both branches. https://www.mail-archive.com/skaware@list.skarnet.org/msg00311.html -- Laurent

Re: execline, s6-portable-utils: print a file to stdout

2018-07-24 Thread Laurent Bercot
I haven’t found a way to print a file to stdout with either execline nor s6-portable-utils. The `s6-cat` utility only echoes stuff that is already coming from stdin, and unlike the shell, execline doesn’t have `<`. https://skarnet.org/software/execline/redirfd.html "redirfd -r 0 $file

Re: execline globbing

2018-07-24 Thread Laurent Bercot
elglob -0 fs somedir/* if { test -n $fs } ln -t otherdir $fs the test will fail if there’s more than one file in `somedir`. Is there a way to put a split variable into one variable again? Your next door "echo" command will do just that (or s6-echo if you risk having dashes and want reliable

Re: Question about enable-absolute-paths option

2018-09-01 Thread Laurent Bercot
I intend to package skarnet softwares in Debian. When packaging execline, I find it produces a lot of binaries with common names. Thus I want to put them in path like /usr/lib/execline/. Do not do this. Several programs, including s6 and s6-rc, rely on execline binaries to be in their PATH.

Re: Question about enable-absolute-paths option

2018-09-02 Thread Laurent Bercot
Thanks for this note, I haven't looked at these packages. At first I thought execline binaries will only be called inside execlinep scripts. Could you give some examples that s6 calls these binaries directly except exelinep? In addition to what Casper said: for instance, some of the

Re: Question about enable-absolute-paths option

2018-09-09 Thread Laurent Bercot
> [1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=906250#22 That's an incredibly disingenuous argument. Debian isn't POSIX- compliant by any stretch of the imagination, and they currently don't provide POSIX-compliant cd/umask/wait binaries because they have correctly identified that

Re: Question about enable-absolute-paths option

2018-09-04 Thread Laurent Bercot
However the binaries(cd, umask, wait) that cause problem are not dependency of s6. Those binaries are not causing problems. What *is* causing problems is fellow developers who *think* those binaries are problematic, for reasons that all come from ignorance of how Unix (and the shell) works.

Re: [announce] utmps-0.0.1.0

2018-07-07 Thread Laurent Bercot
So, I noticed the package includes example OpenRC service scripts (wow!) for utmps-utmpd and utmps-wtmpd. Probably not the kind of testing you hoped for, but for the sake of correctness: they won't work :-P On the contrary, that's exactly the kind of testing I appreciate. :) I've managed to do

Re: [PATCH] change localip is6 flag based on destination ip

2018-04-11 Thread Laurent Bercot
Applied, thanks! -- Laurent

Re: avltree / genalloc

2018-04-12 Thread Laurent Bercot
Ok, so let me ask you this: I want to delete my avltree. That is, I'd like to remove all its nodes and be done with it, i.e. I need to free all memory associated with it. I guess avltree_free() is enough, no need to delete each node individually? Yes, avltree_free() is enough, because an

Re: avltree / genalloc

2018-04-12 Thread Laurent Bercot
- When using avltree_iter() we need to pass a avliterfunc_t_ref, which takes 3 arguments. If I understand correctly, first is the uint32_t index, then the tree's "internal" (unsigned int) index, and my pointer. "The uint32_t index" is confusing terminology, so to clarify, I call this number

[announce] execline-2.4.0.0

2018-03-31 Thread Laurent Bercot
Hello, execline-2.4.0.0 is out. As you all know by now, the main obstacle to adoption of skaware by distributions and mainstream Unix folks is the user interface; so, the obvious next improvements to skarnet.org software is to provide interfaces people are comfortable with. This is true for

[announce] skarnet.org Spring 2018 release

2018-03-26 Thread Laurent Bercot
Hello, New releases of some skarnet.org packages are available. * skalibs-2.6.4.0 --- - Bugfixes. - Several new functions, including a small FIFO library for generic object queues (genqdyn.h). https://skarnet.org/software/skalibs/ git://git.skarnet.org/skalibs * A

[announce] execline-2.5.0.0

2018-04-02 Thread Laurent Bercot
Hello, execline-2.5.0.0 is out. It is with a very heavy heart that I must do this release. User reports have come in by the hundreds and they are almost unanimous (sorry, Colin): they don't like the 2.4.0.0 change, pretending it hurts readability (as if), and writability too, of execline

Re: [announce] execline-2.5.0.0

2018-04-02 Thread Laurent Bercot
My reaction: :) :) * "Wait, did he rename the C source files too? Like src/execline/=.c, src/execline/;.c, etc.?" I tried. Really, I tried. The filesystem didn't have any problem with that, nor did shell scripts, provided the appropriate amount of quoting was given; but *make* choked.

Re: [announce] skarnet.org Spring 2018 release

2018-03-26 Thread Laurent Bercot
* s6-2.7.1.0 -- Make that s6-2.7.1.1, since a stupid (non-critical, but annoying if you prefer your warnings to be displayed when something goes wrong rather than when things work normally) made it through. ^^' -- Laurent

Re: Question about enable-absolute-paths option

2018-09-02 Thread Laurent Bercot
But I probably will not install binaries like `if, exec, wait` to default PATH(like /usr/bin). Although I understand this is possible technically(and currently no other programs claim these names). The actual reason is that I can't afford time to argue with other developers. When I ask on

Re: On lh-bootstrap and mkroot

2018-09-03 Thread Laurent Bercot
The existence of my toolchains, and Zach's, is relatively independent from the existence of lh-bootstrap and mkroot. As far as I'm concerned, the creation of these toolchains was an exercise in working with musl-cross-make at start - and then some people found them useful, so I built them

Re: s6-cp and s6-mv

2018-09-21 Thread Laurent Bercot
Probably a dumb question, but is there a reason there is no `cp` and no `mv` in `s6-portable-utils`? Because reimplementing a full POSIX utility suite isn't a goal. There are already a lot of those you can choose from (coreutils, busybox, toybox, sbase+ubase, etc.) That said, if you don't

Re: S6 integration in mainstream linux distributions

2019-03-15 Thread Laurent Bercot
The next question was the long-term strategy with systemd: we have 2 approaches 1) mix systemd (PID 1) to use the boot phase (especially one shots) and later (after system initialization) use s6 to manage all services. 2) just use s6 My question to the list is, what do you use today? Do you

Re: S6 integration in mainstream linux distributions

2019-03-18 Thread Laurent Bercot
Our view is, that using an non-mainstream distribution is a lot of work for our purpose of being an PaaS provider. That would in the end mean packaging a lot of services on our own. Today the mainstream distribution doesn't package anymore all needed services in the needed versions. In practice

Re: [PATCH] fix null-pointer behavior in fmt and fmtlist functions

2019-02-05 Thread Laurent Bercot
This fixes a segfault when a user calls uint320_fmt(NULL,...), and makes the fmtlist functions return the correct number of characters when called with NULL. Applied, thanks! -- Laurent

Re: skalibs: macOS errors

2019-02-05 Thread Laurent Bercot
Hi all - I just wanted to file a quick report. I tried cloning down the skalibs git repo to my macOS box, which uses the default, case-insensitive filesystem. Since there's both mkltemp.c and mkLtemp.c, I immediately ran into problems with git reporting modifications I hand't made, etc. Ah,

Re: s6-envuidgid: Weird errors with GNU libc's getgrent() and endgrent()

2019-06-03 Thread Laurent Bercot
Adelie (musl-posix) must be getting really close to replacing sysv/openrc with full s6. sysv is done: on Adélie, you can now choose between sysvinit and s6-linux-init as your init system. Both are supported. Providing a packaged alternative to OpenRC, however, will be much more difficult

Re: s6-envuidgid: Weird errors with GNU libc's getgrent() and endgrent()

2019-06-02 Thread Laurent Bercot
Short version: For recent libc releases, and at least on Gentoo, getgrent() and endgrent() seem to magically set errno to EINVAL (I think), except when errno's value is actually meaningful. > (...) End of file or error (errno = Success) errno = Invalid argument POSIX says:

Re: s6-envuidgid: Weird errors with GNU libc's getgrent() and endgrent()

2019-06-09 Thread Laurent Bercot
But it turns out that, with this configuration, __nss_endent() *also* wants to call the implementation of endgrent(3) from each of these services. And the one from libnss_db.so, named _nss_db_endgrent(), is just a wrapper around a munmap(2) system call, via an intermediate internal_endent()

[announce] s6-linux-init-1.0.1.0

2019-05-20 Thread Laurent Bercot
Hello, Following some UX reports in the #s6 IRC channel, a new version of the s6-linux-init package is out. * s6-linux-init-1.0.1.0 - - Binaries have less restrictive permissions. Root-only binaries are now readable (though still not executable) by normal users. -

[announce] skalibs-2.8.1.0, s6-2.8.0.1

2019-05-14 Thread Laurent Bercot
Hello, Some minor updates are available. * skalibs-2.8.1.0 --- - Small bugfixes. - A new wrapper, skalibs_regcomp(), has been provided as a portable replacement for regcomp(). Some systems (looking at you again, BSDs) do not accept empty regular expressions and regcomp()

Re: [PATCH skalibs] Make build reproducible

2019-08-19 Thread Laurent Bercot
Applied, thanks. I didn't bother before because a make build is inherently non-deterministic, unless the author manually defines a total order on all the prerequisites of a target. I suspect the implementation of GNU make to implicitly define such an order, but there's nothing of the sort in

Re: s6-log timestamp bug after resuming; Plan 9 $path and /package

2019-09-01 Thread Laurent Bercot
1. After resuming from suspension or hibernation, s6-log no longer shows the correct timestamp. Can this be fixed? Thanks. This is a much more complicated issue than it sounds. Short answer: no, the system needs to readjust the system clock when resuming from suspension/hibernation; it's

Re: s6-log timestamp bug after resuming; Plan 9 $path and /package

2019-09-01 Thread Laurent Bercot
Thanks Guillermo. I should have thought about this. So Linux is doing the right thing (fixing CLOCK_REALTIME on resume), and the problem only appears with CLOCK_MONOTONIC. It is indeed one of the drawbacks of using --enable-monotonic when you need a wall clock. And it is a skalibs problem that

Re: s6-log timestamp bug after resuming; Plan 9 $path and /package

2019-09-01 Thread Laurent Bercot
Doesn't s6-log (indirectly) use clock_gettime() with a CLOCK_MONOTONIC argument if skalibs was built with --enable-monotonic? Yes, it does. But --enable-monotonic is a bad idea for long-lived processes that need timestamping. I need better clock interfaces in skalibs, the current ones don't

Re: cross-compile skalibs

2019-09-17 Thread Laurent Bercot
On 9/14/2019 2:11 PM, Jens Rehsack wrote: I don't have such a database and such a database is imposible to have. That's a real shame, because it's the *only way* cross-compilation can ever work. You praise autotools for supporting ac_cv_$check variables, that can be supported from the

Re: close safe wrapper may be broken

2019-09-17 Thread Laurent Bercot
On 9/17/2019 7:37 PM, eadwar...@disroot.org wrote: Posix says about close(2): "If close() is interrupted by a signal that is to be caught, it shall return -1 with errno set to [EINTR] and the state of fildes is unspecified." Tell me about it... The fact that close() can be

Re: Ctrl + Alt + Del setup in s6-linux-init?

2019-08-01 Thread Laurent Bercot
s6-linux-init-maker creates an .s6-svscan/SIGINT script that reboots the computer, and Adélie Linux' packaging of s6-linux-init-1.0.2.0 appears to contain an /etc/sysctl.d/ctrlaltdel.conf file that says "kernel.ctrl-alt-del = 0". So one might think that having the kernel send a SIGINT signal to

Re: s6-linux-init-shutdownd: copy & paste error?

2019-07-18 Thread Laurent Bercot
if (WIFSIGNALED(wstat)) //... else if (WEXITSTATUS(wstat)) //… else if (WEXITSTATUS(wstat)) //… Good catch, thanks! Fixed in the latest git. Bugfix release coming at some point in the future. (I'm not hurrying because it's only a display bug.) -- Laurent

Re: cross-compile skalibs

2019-09-20 Thread Laurent Bercot
What I *can* do, though, is change the skalibs build system so that on cross-compilation, you only need to provide the few sysdeps that cannot be probed at all. I spent today on this, and managed to bring down the necessary amount of manually provided sysdeps to one (1). The skalibs git head

Re: Fwd: Warning from skaware@list.skarnet.org

2019-09-25 Thread Laurent Bercot
Has anyone else gotten such a warning from the listserv? Can't do much about it, sorry. ezmlm comes from a time when e-mail was simpler and less broken (or, at least, broken in different ways from today). Your server is rejecting some mails for reasons unknown. Likely a misconfiguration. Or it

Re: Compiling execline shared fails without --with-lib configure opt

2019-12-02 Thread Laurent Bercot
Since I'm not using static libraries, I would not expect to need the "--with-lib" configure option. The --disable-static flag only tells the build system not to build the static execline library. By default, executables are still built against the static version of skalibs. If you want to

Re: s6-svscan can't find shared libraries

2019-12-03 Thread Laurent Bercot
/opt/local/bin/s6-svscan: error while loading shared libraries: libs6.so.2.9: cannot open shared object file: No such file or directory Is this because the '-rpath' linker option is not used at compile time to add the library directory to the runtime library search path? You could say that -

Re: [PATCH execline] Fix CC variable in cross compile environment

2019-10-20 Thread Laurent Bercot
Makefile uses CC instead of $(CROSS_COMPILE)$(CC), So CC shouldn't strip cross prefix when configure. That sounds right, but ISTR testing it when I made the change and it worked when cross-compiling. There must have been something else going on; I will test tomorrow and possibly apply.

Re: Porting skalibs to GNU Hurd

2019-10-18 Thread Laurent Bercot
So, whoever calls s6_supervise_lock_mode() should correctly die, as there is an actual error (that should be reported to the Hurd developers); libs6, libskarnet and the libc are just the messengers. Commenting out the errno check just sweeps the error under the carpet. I assumed the OS was

Re: [PATCH execline] Fix CC variable in cross compile environment

2019-10-21 Thread Laurent Bercot
Confirmed; I must have been confused when testing earlier. Fix pushed, thanks Shengjing. Bugfix releases coming soon. -- Laurent

Re: [PATCH execline] Fix CC variable in cross compile environment

2019-10-21 Thread Laurent Bercot
Since a new release is coming soon, is there any chance to apply another cross compile patch[1]? Applied, thanks for the reminder. New versions pushed, release announcement coming soon. -- Laurent

[announce] October 2019 release: spooky bug squashing and ghosts of POSIX

2019-10-21 Thread Laurent Bercot
Hello, New versions of all the skarnet.org packages are available. This is mostly a bugfix release, as shown by the *.1 version numbers. It just squashes a couple build bugs that prevented proper cross-compilation. If you are not cross-compiling skarnet.org packages, you can mostly ignore

Re: False positive in skalibs system feature test

2019-10-24 Thread Laurent Bercot
Excellent analysis, as always. :) Thank you. * If GNU libc is used, a 'choose cl' test is unreliable. * GNU/Hurd and GNU/k*BSD would be 'getrandom: no' OSes, at least until the libc is updated to make a system call on GNU/kFreeBSD [1] * A 'choose clr' test would be reliable. * Any other

Re: False positive in skalibs system feature test

2019-10-23 Thread Laurent Bercot
Overridable for the win ;) Are we giving advice again without checking first, hmmm? ./configure --with-sysdep-getrandom=no <-- Try it. :P My point is that ld *should* be a reliable way to autodetect those things, and I want to make sure it works too. -- Laurent

Re: False positive in skalibs system feature test

2019-10-23 Thread Laurent Bercot
While building skalibs-2.9.1.0, I notice that the getrandom option isn't available on FreeBSD 12.1 Stable. What I have from ./configure --help is: "... Sysdeps autodetection override: --with-sysdep-K=V assume sysdep K has the value V [autodetected] List of mandatory K for

Re: Porting skalibs to GNU Hurd

2019-10-17 Thread Laurent Bercot
If compiler predefined macros like __linux__ or __NetBSD__ are OK for , how about #if defined(__linux__) || defined(__GNU__)? GCC predefines both __GNU__ and __gnu_hurd__ (I think, can be checked with 'cpp -dM - Do you mean __GNUC__ instead of __GNU__ ? Testing defined(__GNUC__) would yield

Re: Porting skalibs to GNU Hurd

2019-10-17 Thread Laurent Bercot
__gnu_hurd__ That's perfect. I replaced __GLIBC__ with this. So skalibs/nonposix.h will define _GNU_SOURCE on Linux and Hurd, i.e. the systems whose function visibility benefits the most from it. Testing kernel ftms is generally ugly, but it's the right thing for nonposix.h whose goal is

Re: Porting skalibs to GNU Hurd

2019-10-17 Thread Laurent Bercot
The errno I got on Hurd is `EIEIO 1073741928 Computer bought the farm`... Seems a Hurd specific errno... That is really non-conformant, and deserves to be reported to the Hurd team. What is happening is that "control" is a named pipe, and the attempted operation is open(control, O_WRONLY |

<    1   2   3   4   5   6   >