user3675494
user3675494

Reputation: 1

Assembly language compilation in Visual Studio 13

I have an assembly language code in notepad file. I heard it can be compiled without installing MASM exclusively. I've searched for that and I found out that Visual Studio can compile it. I have Visual Studio 13, Kindly guide me what would I have to do to do so.

Upvotes: 0

Views: 2279

Answers (1)

rcgldr
rcgldr

Reputation: 28828

Visual Studio includes masm or actually ml.exe, which is the actual name of microsoft's assembler since version 6.11, which goes back to the days of msdos 6.22. For 64 bit mode, use ml64.exe.

To create a project:

  • create a folder to hold the project.
  • Create the project specifying the folder name as the project name, do not check create directories.
  • Choose win32 console application when the choice appears.
  • Click on next when it appears and click on empty project. This should open up the project window.
  • Right click on the project name ... all configurations ... characters ... and change from unicode to not set if you don't want unicode.
  • Click on project in the menu and add the .asm file name, such as example.asm.
  • Then right click on example.asm, properties, item type , and select custom build tool.
  • Then click on custom build tool.
    • For debug build:
      • command line: ml /Zi /c /Fo$(outdir)\example.obj example.asm
      • outputs: $(outdir)\example.obj
    • For release build:
      • command line: ml /c /Fo$(outdir)\example.obj example.asm
      • outputs: $(outdir)\example.obj

Upvotes: 2

Related Questions