From: jce AT seasip DOT demon DOT co DOT uk (John Elliott) Newsgroups: comp.os.msdos.djgpp Subject: Running multiple DJGPP apps from 16-bit Date: Tue, 13 Oct 1998 21:58:41 GMT Message-ID: <908312348.29044.5.nnrp-04.c2de7091@news.demon.co.uk> NNTP-Posting-Host: seasip.demon.co.uk X-NNTP-Posting-Host: seasip.demon.co.uk:194.222.112.145 X-Trace: news.demon.co.uk 908312348 nnrp-04:29044 NO-IDENT seasip.demon.co.uk:194.222.112.145 X-Complaints-To: abuse AT demon DOT net X-Newsreader: skim 0.8.4 Lines: 29 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Quite recently, I managed to port Digital Research's GEM bindings to DJGPP, so that it can be used to write GEM apps (the apps are 32-bit DJGPP programs, while GEM remains a 16-bit real-mode GUI). When I released the library, it couldn't do Desk Accessories. I have now managed to write a suitable stub for Desk Accessories. However, GEM can only run one protected-mode program at a time. If I have a protected-mode DA loaded, I can't then run a protected-mode app. As far as I can see, this is because GEM does context switches in 16 bits, and tries to load the application while the DA is in the middle of a __dpmi_int() call. - GEM loads a protected-mode DA. - The DA enters its event loop, and calls GEM with __dpmi_int(). - Since the DA's event queue is empty, GEM switches context to its desktop. - The desktop starts a protected-mode application, by loading its real-mode stub (INT 21 AH=4Bh) Using CWSDPMI, I get a crash when the application starts. Using the DRDOS DPMI host (7.03), I get a crash when the application terminates. Am I trying something completely impossible here, or is there any way to get round this? ------------- http://www.seasip.demon.co.uk/index.html -------------------- John Elliott |BLOODNOK: "But why have you got such a long face?" |SEAGOON: "Heavy dentures, Sir!" - The Goon Show :-------------------------------------------------------------------------)