Date: Sun, 1 Sep 1996 22:12:55 -0400 From: dj (DJ Delorie) Message-Id: <199609020212.WAA01945@delorie.com> To: djgpp-workers Subject: make problems I've been having problems building gcc-2.7.2.1 - make is acting up on me. I'm building stage 2, so I'm invoking make like this: make CFLAGS="-O2 -Bstage1/" CC="stage1/xgcc" LDFLAGS="-d" After it runs one command (doesn't matter which) (or just before it starts the next), it segfaults - in _exit() ! It's at 0x12f4, which is one of the places where it reads a stubinfo field, but edx (the register in question) is valid, as are the selectors. Note: esp is corrupt; it's set to 0x127c. A modified mcount.c shows that make's last libc call was to xmalloc() from target_environment(). I've run make in gdb, and it gives the same results - a seemingly valid operation is segfaulting. I tried cwsdpmi and linux dosemu; both fail the same way. If I use make to build itself, it works. Can anyone think of any recent changes that might cause this type of corruption? stack trace (new and (maybe) improved): >> ..\make-3.73\make CFLAGS="-O2 -Bstage1/" CC="stage1/xgcc" LDFLAGS="-s" stage1/xgcc -DIN_GCC -O2 -Bstage1/ -I. -I. -I./config \ -DGCC_INCLUDE_DIR=\"/usr/local/lib/gcc-lib/go32/2.7.2.1/include\" \ -DGPLUSPLUS_INCLUDE_DIR=\"/usr/local/lib/g++-include\" \ -DLOCAL_INCLUDE_DIR=\"/usr/local/include\" \ -DCROSS_INCLUDE_DIR=\"/usr/local/lib/gcc-lib/go32/2.7.2.1/sys-include\" \ -DTOOL_INCLUDE_DIR=\"/usr/local/go32/include\" \ -c cccp.c Exiting due to signal SIGSEGV Page fault at eip=000012f4, error=0004 eax=00000502 ebx=0001f788 ecx=00000000 edx=00020000 esi=00001016 edi=10160000 ebp=00000000 esp=0000127c program=D:\V2\GNU\GCC-2721\..\make-3.73\MAKE.EXE cs: sel=0127 base=10140000 limit=0006ffff ds: sel=012f base=10140000 limit=0006ffff es: sel=012f base=10140000 limit=0006ffff fs: sel=0000 gs: sel=0000 ss: sel=012f base=10140000 limit=0006ffff Call frame traceback EIPs: 0x000012f4 General Protection Fault at eip=3e32; flags=3016 eax=00000300 ebx=00000021 ecx=00000000 edx=0003199d esi=0000000c edi=00073c2c ebp=00073ac0 esp=00003584 cs=18 ds=33 es=f7 fs=cf gs=ff ss=20 error=00ec