Mail Archives: djgpp/1996/07/30/03:18:25
When trying to compile povray 3.0 with djgpp 2.0, djgpp dies while
linking pmode.a saying : "memory exhausted".
This can be cured, by splitting the pmode.a library into 3 parts :
it is made of 6 object files, the fourth, _pmlite.o, causes problems. So
1/ using ar, you build a first archive (pmode1.a) containing the three
first objs,
2/ extract _pmlite.o, and
3/ build a second archive with the last three files
here are the DOS commands for this
copy pmode.a pmode1.a
ar -d pmode1.a _vflat.o _pmpro.o _pmlite.o
ar -x pmode.a _pmlite.o
copy pmode.a pmode2.a
ar -d pmode2.a vflat.o pmpro.o pmlite.o _pmlite.o
and then replace in MSDOSGCC.LNK "pmode.a" by
pmode1.a _pmlite.o pmode2.a
As regards the infamous "gnu-ld" bug (which kills gcc when linking either
large libraries or libraries which include large static arrays), this
error occurs on a rather small module (around 1800 bytes long), and
cannot be cured by splitting the library into several smaller ones : if
instead of linking _pmlite.o, you build a library pmlite.a containing
ONLY _pmlite.o, ld still chokes...
Hope it may shed some light on the bug in ld...
- Raw text -