Commit 2bed4583 authored by wolfgang.thaller@gmx.net's avatar wolfgang.thaller@gmx.net
Browse files

Darwin Linker: Do not add local symbols to lochash

... so that GHCi doesn't complain about duplicate symbols when two C modules define the same static variable.

MERGE TO STABLE.
parent fa8bedce
......@@ -4191,15 +4191,6 @@ static int ocGetNames_MachO(ObjectCode* oc)
oc->symbols[curSymbol++] = nm;
}
}
else
{
char *nm = image + symLC->stroff + nlist[i].n_un.n_strx;
ghciInsertStrHashTable(oc->fileName, oc->lochash, nm,
image
+ sections[nlist[i].n_sect-1].offset
- sections[nlist[i].n_sect-1].addr
+ nlist[i].n_value);
}
}
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment