Good Morning.
- install MASM.
- 2.type Assembly code below and Assembler and got an Execute code.
.386
.model flat, stdcall
option casemap :none
include \masm32\include\windows.inc
include \masm32\include\kernel32.inc
include \masm32\include\masm32.inc
includelib \masm32\lib\kernel32.lib
includelib \masm32\lib\masm32.lib
.data
Hello db "Hello Assemblerrr!!!",0
numb dword 5
.code
start:
invoke StdOut, addr Hello
xor eax,eax
mov ebx, 17
mov ecx, edi
add ebx, [edi]
mov ecx, numb
ror ebx, cl
invoke ExitProcess, 0
end start
Assembly -> save in .asm file -> Assembler this.
You will have below files and You need link them for one of two environments.
2017/11/13 05:12 521 mytest.asm
2017/11/13 05:12 625 mytest.obj
Chose console link Object file.(出来上がったobj fileをlinkしてあげてexeを作成が必要)
2017/11/13 05:15 521 mytest.asm
2017/11/13 05:15 2,560 mytest.exe
2017/11/13 05:12 625 mytest.obj
above files comes up with no errors and You got an executable.
and then run this on your windows CLI. (mytestって打つだけ)
Now You will have a running executable program.
C:\masm32>mytest
Hello Assemblerrr!!!
C:\masm32>
Enjoy