From: Paul Garceau <pgarceau@te...> - 2000-09-18 02:22:29
On 18 Sep 2000, at 9:58, the Illustrious bie.jiuling@... wrote:
> I have built a mingw32msvc cross compiler from my linux box with
> gcc-2.95.2(with Mumit's patch) and binutils-2.10. Program
> building is ok, but runs into page fault in Win9x. I tried gdb to
> figure it out, but no progress is made.
Hmmm...this might be a problem with Win9x, I've had it happen
to me and ended up increasing the initial memory allocations for
the ms-dos shell (as opposed to the environment settings).
Be sure you have more than an ample amount of memory allocated
for your shell (ms-dos). By ample, I mean at least 1024k(1M),
to as much as 8064(?)k(8M) memory pages.
Nothing real can be threatened.
Nothing unreal exists.
The problem is a little different. My victim is patch-2.5.4. I was doing a test
after the building. Small programs like hello world is all ok.
>corrupt mingw/win32 libs when building it yourself. I had no problems when
>using precompiled binarys from Mumit's site.
The runtime is prebuilt binarys.
Finally I figure out something:
the fault is at quotearg.c:181, the parameter 'arg' is NULL
Problem is here:
#161 TMPPATNAME = make_temp ('p');
0x404ea6 <main+418>: push $0x70
0x404ea8 <main+420>: call 0x4086a4 <make_temp>
* 0x404ead <main+425>: mov %eax,0x412760
GDB says: |
(gdb) p &TMPPATNAME |
p &TMPPATNAME |
$6 = (char **) 0x412780--------------???
I downloaded Mumit's prebuilt suit. The build and executing is all ok. So I just
copied patch.o from my cross-compiler using Mumit' suit to generate patch.exe.
Fault still occured. It seems that my gcc generate bad object, the ld is
FYI, my host is Debian linux 2.2r0, PII 266, 96M ram.
Maybe I should rebuild the compiler stuff.