News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

buil 16-bit Masm program with masm32

Started by baghdadi13, January 02, 2007, 12:15:17 AM

Previous topic - Next topic

baghdadi13

Hi

I'm new with masm32
I have programs for 16-bit masm (I use masm 6.11)
I tried one of them , but it doesn't work
Do I have to make some changes on my 16-bit masm programs to build them with masm32
or there is an other solution !!!


code    Segment
addition proc far
        mov dl,5
        add dl,3

        add dl,48

        mov AH,2
        int 21h

        mov ah,4ch
        int 21h

addition  endp
code     ends
         end addition


this is a sample code for 16-bit masm ,,, but it doesn't work on masm32

baghdadi13

I saw an other post  (a problem similar to my problem)
the solution was to use the 16-bit linker

is there any other way to make my 16-bit programs work directly

I get this message when I Link from the qedit


LINK : warning L4017: /SUBSYSTEM : unrecognized option name; option ignored
LINK : warning L4017: /OPT : unrecognized option name; option ignored
Run File [c:1.exe]:
..........
.........
2.obj : fatal error L1101: invalid object module
Object file offset: 1 Record type: 4c





what does it mean ?????

MichaelW

In addition to using a 16-bit linker, you must use different command lines for ML and the linker. Using these command lines in a batch file, with copies of ML.EXE, ML.ERR, and LINK16.EXE in the current directory, I was able to assemble and link your source, with a no-stack-segment warning, and run the result, which displayed "8" and terminated:

ML /c baghdadi13.asm
pause
LINK16 baghdadi13.obj;
pause
baghdadi13
pause
eschew obfuscation

baghdadi13

yes it works
thank you   :U

but is it possible to the same thing from the quick editor
i.e : I write the prograam and then assemble it by clicking on assemble
and link it by clicking link and then tun it

and in the same time be able to link a 32bit program?



MichaelW

Yes, this should be possible. The menus are programmable, and you could create your own batch file(s) to do whatever you require.
eschew obfuscation