October 29, 2025
No libc, big vibes
Detour: Dynamic linking on Linux without Libc
Static apps doing dynamic stunts — devs are divided
TLDR: Detour lets Linux apps be fully static yet still load plugins and drivers at runtime, sidestepping the usual system C library. Early chatter nods to the long-standing $ORIGIN wish and hints at a brewing fight between tinkerers hyped for freedom and skeptics worried about safety and support.
Detour just crashed the Linux party with a wild promise: build a single, self-contained app that still loads plugins and drivers on the fly — no standard C library required. For non-nerds: it’s like packing your own snacks but still sneaking into the buffet. People are stunned this “static app that does dynamic tricks” can still talk to things like graphics drivers and audio systems, which normally expect the usual system plumbing. The twist? It only works on x86_64 right now, and anything beyond that needs hand-written assembly — cue raised eyebrows.
In the comments, the vibe tilts instantly into deep-cut drama. Ericson2314 drops the nerdiest mic: “wish the program loader supported $ORIGIN,” a long-running dream to let programs say “load the interpreter from where I live.” Translation: this hack pokes ancient sore spots in how Linux launches apps. Some tinkerers are calling it a jailbreak for static binaries; others are already side-eyeing the “mixing multiple C runtimes in one process” bit like it’s a recipe for spooky bugs.
Expect fireworks: performance chasers cheering “no libc, no problem,” security folks muttering about undefined behavior, and distro maintainers imagining the bug reports. The memes practically write themselves: “I bypassed libc and all I got was this segfault,” and “choose your fighter: glibc, musl — or both
Key Points
- •Detour enables statically linked Linux executables to perform dynamic linking (dlopen/dlsym) without linking against libc.
- •It addresses static linking limitations that break components relying on dynamic linking, such as GPU drivers, window systems, audio, PAM, NSS, and plugins.
- •Detour works by loading a stub ELF, reading PT_INTERP, and invoking the system dynamic linker (e.g., ld-linux-x86-64.so.2) like the kernel would.
- •The dynamic linker initializes the stub ELF and transfers control to its main, enabling runtime dynamic loading within a static executable.
- •Current support is limited to x86_64 Linux; other architectures require assembly for syscalls, setjmp/longjmp, and indirect jumps (see loader.c).