How can i make use of linker and executable file under MASM32

Started by dansol77, March 25, 2006, 05:08:00 PM

Previous topic - Next topic

dansol77

I have been trying to create or make .OBJ file after having my .asm file including how to link it.Please can somebody throw more light on this issue.

Mark Jones

Hello Dansol77. What exactly are you trying to do again? Assemble one .ASM file but include a second .OBJ file at link-time?
"To deny our impulses... foolish; to revel in them, chaos." MCJ 2003.08

ChrisLeslie

Hi Dansol77

The BIN folder has two important .exe's. ML.exe will assemble your source file and produce a .obj file, and LINK.exe will take the .obj file and produce a Windows .exe for your application. You can run these two steps manually every time you wish to assemble some of your code, providing that you set the appropriate options.

An easier way is to use a batch file that does the assemble and link stage in one hit, with options aleady set. If you look in the BIN folder you will find several batch files to choose from. You can use the batch files as models to create your own if you desire.

An easier way still is to use QEDITOR as a kind of IDE. It has menu options that immediately call up one of several batch files and conveniently produces and output for you. Any dumbcluck can do that!
I hope that that has cleared up that problem for you.

Chris

Vortex

ml /c /coff sourcecode.asm
link /SUBSYSTEM:WINDOWS sourcecode.obj

or if it's a console application :

link /SUBSYSTEM:CONSOLE sourcecode.obj

PBrennick

\masm32\bin\ml.exe /c /coff yourfile.asm
\masm32\bin\link.exe /SUBSYSTEM:WINDOWS yourfile.obj


or if it is a console application:
\masm32\bin\link.exe /SUBSYSTEM:CONSOLE yourfile.obj

pAUL
The GeneSys Project is available from:
The Repository or My crappy website