NASM - The Netwide Assembler
NASM Forum => Programming with NASM => Topic started by: michael weaser on March 24, 2013, 04:36:01 PM
-
how do you create a mz .exe header for dos and how do you make the ne .exe header for 16 bit windows?
-
Use an appropriate linker.
If you really insist on throwing perfectly good linkers into the unemployment lines... you can use "-f bin" and "just" stuff the appropriate bytes into the appropriate places. For an MZ header, there are macros in the "misc" directory of the Nasm source code to assist. The NaGoA includes have macros for a PE header...
http://home.myfairpoint.net/fbkotler/nagoa20120202.zip
(a somewhat "updated" version) There MAY be something for NE in there (too much sun on my monitor to read it comfortably at the moment). As I think you know, NE is rather "rare" these days...
I'd go with the "linker" option, if you can...
Best,
Frank
-
I got the files to make MZ and PE headers in Nasm but No NE header. Is there any other files or way to help me make NE exe header in nasm. I just can't find any way to create a NE header.
-
http://www.fileformat.info/format/exe/corion-ne.htm
Does that help at all? (just the first thing I found)
If we were to attempt to create an NE header, do you have a way to determine if it's right? A system that expects to run NE? Or a "known good" NE executable we could compare to? I know nothing about the format, I'm afraid...
Best,
Frank