Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
I run a win98 SE operating system, at 133MHz with 32 Megs of RAM. I am learning assembly with MASM, upon trying to assemble a hello world program, i recieved the following linker error:
error Segment refernce in fixup record hello.obj: fatal error LNK1123: failure during conversion to COFF: file invalid or corupt.
Please can anyone help explain what is going on and how i can fix it? For more details see below:
Hello, I decided to take the plunge and learn assembly language. I found several good ASM tutorials on the net. Upon copying and pasteing the code for the clasic hello world program writen in assembly, i saved the file as hello.asm in text format (ASCII).
I then after half hour, found a download for MASM, from the Driver Development Kit on the Microsoft web site, I downloaded Bins_ddk.exe and 98setup.exe from the microsoft web server. I then executed both files and extracted them to c:\ddk then i opened that folder and executed setup.exe as instructed. This created the directory c:\98ddk\ where it installed the nessisary files. I then set my path variable in autoexec.exe to include c:/98ddk/bin/win98 and c:/98ddk/bin (link.exe is in bin) I then edited my config.sys file to contain the line shell=c:\command.com /p /e:4096
again as instructed, then I rebooted my system. Launched DOS then moved to the directory where my hello.asm file was located and issued the command ml /Flhello.1st hello.asm
as instructed, The linker gave me a few warnings, in which the tutorial said to ignore, however it allso gave me the error Segment refernce in fixup record hello.obj: fatal error LNK1123: failure during conversion to COFF: file invalid or corupt. The result haulted creation of hello.exe however did produce hello.1st and hello.objPlease help -=- aj67my@cyberspace.org

Hi Kelly,
You downloaded ddk, it's the driver development kit, so you can use this package to write drives under dos. If yoz want to learn assembly, and you are beginner, you shoould try to use tlink, tasm programms to compile assembly programs and make sure of your hardware knowledge is good.
Good luck.
Shaft

Actually, either assembler (or many others) will work fine for doing windows apps. I suspect the problem is in the command line parameters. I don't do an awful lot of assembling apps with masm32, but the one batch file I found uses several command line switches. I'm not sure what they all are, but I'm thinking you might want to look at some of them.
Here are the ones my program uses:
ml -Fl -coff -DBLD_COFF -DIS_32 -W2 -c -Cx -DMASM6 -Sa Hello.asm

![]() |
Pro C
|
link a menu with the form...
|

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |