Exporting all symbols from a binary

⚓ Rust    📅 2025-12-11    👤 surdeus    👁️ 3      

surdeus

I am writing a kernel with a kernel module loader. I wish to share a crate between the kernel and kernel modules, and to make sure that bootloader can write bootinfo into the correct global variable, I have to link this crate to the kernel, and I create a symbol table by scanning the kernel file. However, the rust compiler seems to only export symbols that are used in the kernel, so some symbols required by the modules are not found. How should I solve this problem?

1 post - 1 participant

Read full topic

🏷️ Rust_feed