zig
zig copied to clipboard
Fix ELF alignment for freestanding targets
The ELF specification (generic ABI) states that ``loadable process segments must have congruent values for p_vaddr and p_offset, modulo the page size''. Linux refuses to load binaries that don't meet this requirement (execve() fails with EINVAL). Ensures that output binaries always satisfy this condition by forcing page-alignment even for freestanding targets. (Related : #19750)