Coder's Guild Mailing List

dot COM programs for DOS

Posted by Ali Bhai on 1999-04-13

I am working in Assembly Language (Intel + DOS) and I am learning dot COM
programs by studying a book, Assembly Language Programming and Organization
of the IBM PC by Ytha Yu.

However, I am not quite successful at it. The programs given in the book as
examples assemble quite well. But when I write my own programs, I get the
following message during linking (btw I am using Turbo Assembler - while the
book prefers MS ASM)

Fatal Error: cannot generate .com program - data defined below CS:IP

I know that this error is related to the 1 segment limit of .com programs.
But when I broke the code into three files, assembled them separately and
linked them, it worked quite ok. Moreover, this doesn't always work and I
continue getting the same message sometimes.

The full segment definitions of Assembly language are quite confusing. I
can't figure them out.

Ali Bhai
BCS III - FAST Institute of Computer Science, Karachi
email: mashah@xxxxx.xxx.xx
web page: www.pak.org/mufta
<----------------------------------------->
[To err is human but to really mess up the things you need a computer.]