Add -z pack-relative-relocs to RUSTFLAGS

rustc/cargo ignores LDFLAGS and requires the linker flags to be passed
via `-Clink-arg=` in RUSTFLAGS.
This commit is contained in:
2023-06-05 17:10:06 +02:00
parent db8cb28fc5
commit 7d16607a31

View File

@@ -20,7 +20,7 @@ common:
packager: "ALHP $march$ <alhp@harting.dev>"
makeflags: "-j$buildproc$"
# https://somegit.dev/ALHP/ALHP.GO/issues/110
rustflags: "-Copt-level=3 -Ctarget-cpu=$march$"
rustflags: "-Copt-level=3 -Ctarget-cpu=$march$ -Clink-arg=-Wl,-z,pack-relative-relocs"
ltoflags:
- "-falign-functions=32" # https://github.com/InBetweenNames/gentooLTO/issues/164
kcflags: " -march=$march$ -O3"