April 17, 2006

OMF File Format is not longer supported

If you have some obj-files, with for example assembler-code, which was generated by older compilers/assemblers, they mostly generated the obj-file in the OMF format. This format was indroduced by Intel and Microsoft. Later Microsoft changed to their new COFF format.

Linking OMF files with VC-compilers was always a supported scenario. But starting with VC5 you got a warning like:

test.obj : warning LNK4033 : converting object format from OMF to COFF

In VC8 (VS2005) they silently removed to support for the OMF format in the linker. So now you are not able to link OMF files. You will get an error message like:

test.obj : fatal error LNK1107: invalid or corrupt file: cannot read at 0×70

(And if you double click two-times on this error message VS2005 will crash ;-) )
To use your old obj-file you have two options:

  • Use editbin from VC7.1 or before to permanently convert the OMF file to COFF format (editbin in VC8 does not support the conversion from OMF to COFF!)
  • Recompile your source files into COFF format

Posted 1 year, 8 months ago on April 17, 2006
The trackback url for this post is http://blog.kalmbachnet.de/bblog/trackback.php/79/

Comments have now been turned off for this post