Remix.run Logo
▲ craftkiller 5 hours ago

Neat project. One thing I don't see covered: is everything going to be statically linked like it is on Alpine Linux? Is statically linking libc advisable on a NetBSD kernel? I know (unlike Linux) the FreeBSD kernel ABI can change every major release, but I'm not familiar with NetBSD's approach.

▲Intralexical 5 hours ago | parent | next [-]

Alpine Linux is not statically linked. It provides a musl environment which makes it easy to statically link your own builds, but software shipped as part of the distro is usually dynamically linked.

  $ docker run -it --rm alpine

  / # apk add cmd:ldd
  / # ldd $(which ash)
          /lib/ld-musl-x86_64.so.1 (0x7f4cb4d1d000)
          libc.musl-x86_64.so.1 => /lib/ld-musl-x86_64.so.1 (0x7f4cb4d1d000)

  / # apk add cmd:python3
  / # ldd $(which python3)
          /lib/ld-musl-x86_64.so.1 (0x7fd630cab000)
          libpython3.12.so.1.0 => /usr/lib/libpython3.12.so.1.0 (0x7fd63069a000)
          libc.musl-x86_64.so.1 => /lib/ld-musl-x86_64.so.1 (0x7fd630cab000)
▲rjsw 5 hours ago | parent | prev [-]

NetBSD retains the old ABI as well if anything changes to a syscall.