How can I build .com file with MASM ? I just want MASM to take my source file and translate it to binary opcodes. How can I do that ?
I use this batch file to build DOS .COM files. It's always worked for me. You also have to download a old version of link.exe from Iczilions site (in the downloads section) to link com files, and put it in your \Masm32\Bin\ folder under the name doslink.exe, in order to use it with this .bat file. doscom.bat
@echo off if exist %1.obj del %1.obj if exist %1.exe del %1.exe \masm32\bin\ml /AT /Zm /c %1.asm if errorlevel 1 goto errasm \masm32\bin\DosLink /TINY /DOSSEG %1.obj if errorlevel 1 goto errlink dir %1.* goto TheEnd :errlink echo _ echo Link error goto TheEnd :errasm echo _ echo Assembly Error goto TheEnd :TheEnd pause