Back to home page

DOS ain't dead

Forum index page

Log in | Register

Back to the forum
Board view  Mix view

question about including/linking (DOSX)

posted by DOS386(R), 31.05.2008, 02:21

> My starting point is: I`ve compiled some win32 console applications on
> WinXP with Visual Studio.

Good start :-)

> goal #1: On WinXP I want now to compile a 16 bit real mode executable for
> DOS. The exe should become at best a standalone exe. Working without
> himem/emm386/jemmex (and use only conventional memory).

> Is goal #1 feasible with HX?

NO. As already suggested, use WATCOM: Win32 host, DOS16RM target. But compiling DOS stuff on DOS is better :-)

VCC will NOT produce 16-bit code (except some 20 years old versions maybe) ... 32 bit at best (the future has 64 or 128 bits :clap: )

> goal #2: On WinXP I want now to compile a 32 bit protected mode executable
> for DOS. The exe should become at best a standalone exe.

Then use DPMI and include HDPMI32 / LOADPEX, no need to care about HIMEM/JAM ;-)

> In case #1/#2 what files do I need to include or link?

If you use a formally Win32 compiler, you have to link in the static Win32 emulation stuff from HX. This will bloat the executable (big problem, but DGJPP is even worse here).

FloX wrote:

> MR...why do you want to compile 16-bit programs? Wouldn't 32-bit DOS programs also ok?

16-bit is good if code fits into 64 KiB and totally hogs cca 480 KiB at most ... using 8086 instructions only.

If you need more, it's indeed better to design a fully 32-bit application, rather than pick a fight with XMS/EMS/MZ-Overliars/... that can't be really won, as 20 years of experience have shown :-|

---
This is a LOGITECH mouse driver, but some software expect here
the following string:*** This is Copyright 1983 Microsoft ***

 

Complete thread:

Back to the forum
Board view  Mix view
15196 Postings in 1365 Threads, 250 registered users, 15 users online (0 registered, 15 guests)
DOS ain't dead | Admin contact
RSS Feed
powered by my little forum