mirror of
https://github.com/ziglang/zig.git
synced 2026-01-03 20:13:21 +00:00
link.Elf: Define __global_pointer$ for riscv32 too.
See: https://github.com/riscv-non-isa/riscv-elf-psabi-doc/blob/master/riscv-elf.adoc
This commit is contained in:
parent
11badbfe8e
commit
6ec7757914
@ -3150,7 +3150,7 @@ fn addLinkerDefinedSymbols(self: *Elf) !void {
|
||||
}
|
||||
}
|
||||
|
||||
if (self.getTarget().cpu.arch == .riscv64 and self.isEffectivelyDynLib()) {
|
||||
if (self.getTarget().cpu.arch.isRISCV() and self.isEffectivelyDynLib()) {
|
||||
self.global_pointer_index = try linker_defined.addGlobal("__global_pointer$", self);
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user