3

I want to create a 16 bit Dos application and want it to run using the NTVDM.exe on my 32bit windows 7 machine. How do I do it? I basically want my application to do the file operations through the NTVDM and for that I think I'll need a 16 bit application first, Is there any other way?

  • I don't need an Emulator, I need to create an 16-bit app
ldav1s
  • 15,885
  • 2
  • 53
  • 56
WIN_SOM_LIV
  • 160
  • 2
  • 9

2 Answers2

5

A couple free C/C++ compilers that claim 16-bit (MS-DOS and Win16) support are the Digital Mars compiler and the Open Watcom Compiler.

The Open Watcom webpage is unresponsive at the moment... There's a SourceForge download page though.

Michael Burr
  • 333,147
  • 50
  • 533
  • 760
  • Help please. I installed the Digital Mars compiler and also the DOS 16 libraries with it. But it still seems to build 32bit applications. How do I go about? – WIN_SOM_LIV Dec 11 '13 at 12:39
  • There's a command line reference page here: http://www.digitalmars.com/ctg/sc.html I think you'll need to use something like the option `-mt` to produce a DOS `.com` file. There are other options for various other DOS memory models that produce a relocatable 16-bit `MZ` format `.exe` file. I haven't done this in years so I'm not sure how well this stuff still works, and you may need to do some trial, error, and research. And there's the chance that it might not be able to do what you need. – Michael Burr Dec 12 '13 at 19:09
  • Thanks It worked. My app is running and Its showing as a NTVDM process on windows 7 x86 as expected. – WIN_SOM_LIV Dec 13 '13 at 09:09
1

The last Microsoft Visual C++ compiler for 16-bit was 1.52c, available on MSDN Subscriber Downloads.

For free ones, see Looking for 16-bit x86 compiler.

Community
  • 1
  • 1
Mark Tolonen
  • 166,664
  • 26
  • 169
  • 251