Howto: Building for Linux with musl libc

Justin Cormack edited this page Mar 24, 2014 · 4 revisions

The musl libc is an alternative libc for Linux. Some Linux distros, such as Sabotage, use it as a full-out replacement for glibc. On systems which use glibc by default, it is possible to "pseudo-crosscompile" binaries to use musl by using the musl-gcc wrapper.

buildrump.sh requires at least musl after 0.9.12. With a sufficiently new musl, native musl distros are expected to just work. The rest of this page documents using musl-gcc.

Set the following environment variables:

CC=musl-gcc
AR=ar
NM=nm
OBJCOPY=objcopy

Then run buildrump.sh. That's it. Note that virtif will not be built unless your musl environment offers the Linux kernel headers.

Clone this wiki locally
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.