Mail Archives: djgpp/2002/08/24/16:44:45
> 1) I make a program in DOS, Win98(DOS-BOX) and W2K(DOS-BOX) using
> DJGPP(V204)+GCC3.1. Eatch program are same(binary)
Yes - the development tools build a single binary which should run
anywhere in a DOS-like environment on a 386 or newer processor. There
are some run time checks in the binary to recognize the different
operating systems and use those features (such as long file names).
> 2)That program can not run if the PATH not assigned to the directory,
> (Load error: no DPMI)
> but can run after copied "cwsdpmi.exe" program to the directory.
> (this is MS-DOS, Win98_command_prompt_only)
If DPMI 32-bit helper is not hooked into the interrupt chain (it is
available under Windows, OS/2, and even QDPMI provider which comes
with QEMM) - then the stub looks for CWSDPMI.exe . It first looks
in the same directory as the image, then the path, then the current
directory. If it can't find CWSDPMI in any of those locations it
then prints the no DPMI message.
If you move a program to a different DOS only computer, you need to take
CWSDPMI with it - and put it in the path (or the same directory as
the image). If you don't want to put cwsdpmi.exe on the other system,
you can use the commands:
exe2coff djecho.exe (creates djecho - no extension - use your image)
copy /b cwsdstub.exe+djecho djecho2.exe
djecho2.exe (you can use your own names) can now be moved to a different
system without CWSDPMI. The DPMI provider can also be the pmode stub,
if it works better for the program.
> I still have a question about IO_Port Access in Win2k(DOS-BOX).
In general, any ports for devices controlled by the operating system
(such as the parallel port) cannot be directly manipulated under
Win2K, (or Windows NT, or Windows XP).
Some ports (such as the timer) are emulated and almost work, but have
bugs.
- Raw text -