4 ms·
> > OpenBSD allows making syscalls from static binaries as well. > Do you have a source for this? One article from 2019 about this can be found at https://lwn
by cesarb 2y ago
> > OpenBSD allows making syscalls from static binaries as well.
> Do you have a source for this?
One article from 2019 about this can be found at https://lwn.net/Articles/806776/ https://lwn.net/Articles/806776/ (later updates https://lwn.net/Articles/949078/ https://lwn.net/Articles/949078/ and https://lwn.net/Articles/959562/ https://lwn.net/Articles/959562/). Yes, it does not have a stable system call ABI, but as long as your program was statically compiled with the libc from the same OpenBSD release, AFAIK it should work.
- oguz-ismail 2y agoYeah. Do you have any information as to how/when the OpenBSD system call ABI has changed recently? I wouldn't expect that to happen very often.
- WhyNotHugo 2y agoFrom 2019: https://lwn.net/Articles/806776/ https://lwn.net/Articles/806776/
- kbolino 2y agoIn particular, from Theo de Raadt himself: > we here at OpenBSD are the kings of ABI-instability > Program to the API rather than the ABI. When we see benefits, we change the ABI more often than the API. > I have altered the ABI. Pray I do not alter it further. The term ABI here though is a little imprecise. I believe it just refers to the syscall ABI. So, it should be possible to make an "almost static" binary by statically linking everything except libc, and that binary should continue to work in future versions of OpenBSD.
- kbolino 2y agoI upvoted for the great links, but I still don't think a static binary that will break in the future is meeting the expectations many have when static linking.