delorie.com is funded by banner ads.
  www.delorie.com/djgpp/v2faq/faq031.html   search  

| Previous | Next | Up | Top |

6.1 GCC or some other DJGPP programs hang

Q: When I try to compile anything, GCC just hangs!

Q: Some programs, like Info and Less, hang on my Windows 9X machine after some time, requiring to close the DOS box. Help!!

Q: Bash hangs on Windows 9X after the first DJGPP program I run from it!


A: If you are using GCC 2.8.1, and if only GCC hangs, then chances are that you have set the DJGPP environment variable incorrectly, or didn't set it at all, or messed up your DJGPP.ENV file by editing it. Refer to what to do if GCC hangs, later in this FAQ, for details about possible problems with setting DJGPP. When DJGPP is not set, or points to a non-existent directory, the first release of GCC 2.8.1 would enter an endless loop (the NTDVM process on Windows/NT will go nuts allocating memory, as a result of this).

The latest uploads of the GCC 2.8.1 binary (v2gnu/gcc281b.zip) were modified to prevent them from hanging. This version aborts with an error message instead of hanging. You should upgrade to the latest binaries of GCC, and also set your DJGPP variable correctly.

Some people fail to read the release notes which come with GCC 2.8.1, and install it incorrectly. If you installed GCC 2.8.1 recently and it began to hang, now is the time to read those instructions again (they are installed as gnu/gcc-2.81/problems.txt). In particular, GCC 2.8.1 comes with a modified version of DJGPP.ENV which you should install over the stock version.

If interactive programs like Bash, Less, Info, Emacs, and RHIDE are those which hang, and if it only happens after running another DJGPP program from within those programs, then your Windows 9X installation is afflicted by a subtle bug whereby programs which call function 1680h of the Interrupt 2Fh (to release the rest of their time slice when they are idle) hang after they spawn another DJGPP program. A modified version of the library function __dpmi_yield, which works around that bug in Windows, is available (it will be part of DJGPP v2.02 release), and latest uploads of the binaries for the affected programs should be free from this problem. If you cannot find a pre-compiled binary that works, get the sources and rebuild the program with a fixed version of __dpmi_yield.


  webmaster   donations   bookstore     delorie software   privacy  
  Copyright ⌐ 1998   by Eli Zaretskii     Updated Sep 1998  

Powered by Apache!

You can help support this site by visiting the advertisers that sponsor it! (only once each, though)