-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Open
Labels
backend-llvmThe LLVM backend outputs an LLVM IR Module.The LLVM backend outputs an LLVM IR Module.bugObserved behavior contradicts documented or intended behaviorObserved behavior contradicts documented or intended behaviorupstreamAn issue with a third party project that Zig uses.An issue with a third party project that Zig uses.
Milestone
Description
A linker script with a section containing a KEEP directive and with a symbol exported into that section is not present in the binary if LTO is enabled.
in linker script:
.stivale2hdr ALIGN(4K) : {
KEEP(*(.stivale2hdr))
} :rodata
in root zig file:
pub export const header linksection(".stivale2hdr") = // struct initalization hereIf want_lto is set to false or null then the binary will contain the stivale2hdr section
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
backend-llvmThe LLVM backend outputs an LLVM IR Module.The LLVM backend outputs an LLVM IR Module.bugObserved behavior contradicts documented or intended behaviorObserved behavior contradicts documented or intended behaviorupstreamAn issue with a third party project that Zig uses.An issue with a third party project that Zig uses.