(Gast)
n/a Beiträge
|
Re: ASM mit NASM Problem
10. Okt 2003, 05:09
'mov ax, daten' dürfte das Problem sein, hab mal schnell mit TASM5 getestet...
HelloExe.bat
Code:
;@goto build
data segment
Hello db "Hello, World!", 0Dh, 0Ah, "$"
data ends
code segment
Start:
mov ax, seg Hello
mov ds, ax
mov dx, offset Hello
mov ah, 09h
int 21h
mov ax, 4C00h
int 21h
code ends
end Start
:build
@echo off
set PATH=P:\BORLAND\TASM5\BIN;%PATH%
tasm /m3 /ml /q /t /w2 /z HelloExe.bat, HelloExe.obj
tlink /c /k /Tde /x HelloExe.obj, Hello.exe
del HelloExe.obj
Hello.exe
pause
HelloCom.bat
Code:
;@goto build
code segment
org 100h
Start:
mov ah, 09h
lea dx, Hello
int 21h
mov ax, 4C00h
int 21h
Hello:
db "Hello, World!", 0Dh, 0Ah, "$"
code ends
end Start
:build
@echo off
set PATH=P:\BORLAND\TASM5\BIN;%PATH%
tasm /m3 /ml /q /t /w2 /z HelloCom.bat, HelloCom.obj
tlink /c /t /x HelloCom.obj, Hello.com
del HelloCom.obj
Hello.com
pause
|
|
Zitat
|