百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
M

min-dl

> 编程语言
开源

针对 ELF 的最小动态链接器实现,支持 x86_64 和 Arm/Aarch64

200 stars0 点赞2 次浏览
访问官网GitHub

工具介绍

针对 ELF 的最小动态链接器实现,支持 x86_64 和 Arm/Aarch64

min-dl: minimal dynamic linker implementation

min-dl is a minimal ELF dynamic linker that loads a shared library, performs relocations, resolves symbols, and runs init/fini constructors -- all without depending on glibc's ld-linux runtime.

How it works

ELF executables and shared libraries that call external functions typically contain a Procedure Linkage Table (PLT), which adds a level of indirection for function calls analogous to that provided by the GOT for data. Deferring symbol resolution can reduce startup cost because unresolved entries are only fixed up when actually called.

min-dl loads a shared object via mmap, processes its dynamic section (symbol tables, hash tables, relocation entries, init/fini arrays), and performs the necessary relocations. Standard relocations (including PLT JUMP_SLOT entries) are resolved eagerly at load time. A callback-based PLT trampoline is also provided for callers that want deferred resolution through the set_plt_resolver API.

Supported architectures

  • x86-64
  • ARM (32-bit)
  • AArch64
  • RISC-V (64-bit)

Adding a new architecture requires an arch/.h header with platform-specific assembly macros, relocation handling in loader.c, and a machine type check.

Build and test

Prerequisites: a C toolchain (GCC), make, and for cross-architecture testing, the corresponding cross-compiler and QEMU user-mode emulator.

make clean && make
make check

Cross-compilation targets (build only):

make arm          # ARM 32-bit
make aarch64      # AArch64
make riscv64      # RISC-V 64-bit

Each architecture has a corresponding check_ target that runs the tests under the appropriate QEMU user-mode emulator:

make check_arm
make check_aarch64
make check_riscv64

Licensing

min-dl is licensed under the BSD 2-Clause License; see LICENSE.

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

C

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月18日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言