The SoLo project develops a loader for system so-libraries for fully static Linux programs.

The SoLo project has been released, allowing fully static Linux programs compiled with musl to load glibc libraries installed on the system via dlopen(), primarily GPU drivers. Typically, static builds are incompatible with Vulkan and OpenGL drivers, which distributions provide as shared libraries compiled with glibc. SoLo removes this limitation with an embedded ELF loader in the executable and a layer that translates glibc calls to the musl runtime of the process—the glibc itself is not loaded into the process, and no second libc appears in it. The code is written in C++ and is distributed under the MIT license.

The repository includes a visual example: a static executable file that contains neither an interpreter nor a dynamic section, which finds the installed system driver in the standard way for Vulkan, loads it along with dependencies, executes a compute shader, and saves the result as a PNG. As part of continuous integration, the example is tested on Alpine, Fedora, and Ubuntu with Lavapipe packages from the official repositories of these distributions. This approach is already being utilized in practice—it is used to form release builds of the terminal emulator Shitty.

Source: opennet.ru

Buy reliable website hosting with DDoS protection, VPS VDS servers 🔥 Buy reliable website hosting with DDoS protection, VPS VDS servers | ProHoster