mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-16 18:59:11 +02:00
* an attempt to fix WebAssembly debug info section relocations
This commit is contained in:
parent
2da28054d4
commit
5604bd951e
@ -645,10 +645,13 @@ implementation
|
|||||||
if not assigned(p) then
|
if not assigned(p) then
|
||||||
internalerror(2021092608);
|
internalerror(2021092608);
|
||||||
if (p.objsection<>nil) and TWasmObjSection(p.objsection).IsDebug and
|
if (p.objsection<>nil) and TWasmObjSection(p.objsection).IsDebug and
|
||||||
(p.bind<>AB_COMMON) then
|
(p.bind<>AB_COMMON) and (p.bind<>AB_EXTERNAL) then
|
||||||
begin
|
begin
|
||||||
CurrObjSec.addsectionreloc(CurrObjSec.mempos+CurrObjSec.Size,CurrObjSec,RELOC_ABSOLUTE);
|
objreloc:=TWasmObjRelocation.CreateSection(CurrObjSec.Size,p.objsection,RELOC_ABSOLUTE);
|
||||||
inc(data,p.address);
|
objreloc.Addend:=Data+p.Address;
|
||||||
|
CurrObjSec.ObjRelocations.Add(objreloc);
|
||||||
|
{inc(data,p.address);}
|
||||||
|
data:=0;
|
||||||
Data:=NtoLE(Data);
|
Data:=NtoLE(Data);
|
||||||
writebytes(Data,4);
|
writebytes(Data,4);
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user