Mail Archives: djgpp/1994/10/19/10:23:48
ANTHONY APPLEYARD writes:
>
> (0) I have go32 1.12, binutils 2.4, bison 1.22, diffutils 2.6, gas 2.3, gcc
> 2.6.0, gdb 4.12, gzip 1.2.4, libg++-2.6.0, and its first two `maint' updates,
> which I ftp'ed from oak.oakland.edu
>
> (1) I was informed "You can use djgpp in a Windows DOS box [with this
> varsion of djgpp], but you can't write Windows applications with it yet.". I
> have found by experiment that I can indeed now run this small trivial Gnu C++
> program successfully under Windows 3.1:-
>
> #include<stdio.h>
> main(){char name[256]; printf("name of cat?"); gets(name); printf("miaow\n");}
>
> but a big Gnu C++ program that I frequently use from DOS, when run from
> Windows 3.1 fails "general protection error". Once that big program did start:
> it printed its first 2 lines of output, then locked tight, and I had to press
> ctrl-alt-del to get out of it.
GO32 programs run from inside a Windows DOS box behave somewhat
different than run from plain DOS, mostly due to the DPMI (0.9) requirements.
There are several reasons for your program not to work inside a DOS box:
(1) making use of graphics (this is still a no-no)
(2) direct DOS memory access (using the 0xE0000000 selector)
(3) other indirect variations from (2)
If you want to run your program from inside a DOS box you should therefore
refrain from using graphics, and use the 'dosmemget()' and 'dosmemput()'
functions for accessing DOS memory.
.^^^^^^^^ _____________________________________
| | / Pieter Kunst (P.J.) \
| _ _| / Philips Research Laboratories, \
.--(o)(o) / Building WY3, Prof. Holstlaan 4, \
|@ _) / 5656 AA Eindhoven, The Netherlands. |
| ,___| / e-mail: kunst AT prl DOT philips DOT nl /
| / \_______________________________________________/
/____\
- Raw text -