Skip to Content.
Sympa Menu

baslinux - Re: [BL] nasm

baslinux AT lists.ibiblio.org

Subject: Baslinux mailing list

List archive

Chronological Thread  
  • From: Sindi Keesan <keesan AT iamjlamb.com>
  • To: baslinux AT lists.ibiblio.org
  • Subject: Re: [BL] nasm
  • Date: Tue, 27 Apr 2004 20:56:43 -0400 (EDT)

On Tue, 27 Apr 2004, Ken Martwick wrote:

> nasm defaults to assembling programs in flat binary format as in DOS
> "sys" or "com" programs. Running "nasm -hf" will list the output
> formats nasm can produce. For current Linux, the command line should
> be "nasm -f elf -o myprog myprog.asm". This will give the right out-
> put format, but other changes may also be needed for Linux.
> Ken Martwick

Jim tried compiling with elf on the line and got some error messages.

Can you suggest what he might read to learn what changes are needed for
linux? He thinks he needs to change interrupt calls to DOS into interrupt
calls to linux. He uses 10h 16h 17h and 21h. Is 10h an x86 BIOS call and
21h a DOS call? Can you recommend a good website or a primer for
translating between DOS and linux assembly languages?

> On Tue, 27 Apr 2004, Sindi Keesan wrote:
>
> > Nasm is an assembler (used to 'compile' programs written in assembler
> > language) that exists in both DOS and linux (maybe also Windows). I used
> > it to produce e3 executables.
> >
> > My partner wrote a DOS text editor in a86 assembler (similar to masm) and
> > would like to port it to linux. So he read the nasm.doc and modified a
> > few things (added square brackets) and last night got his code to assemble
> > with DOS nasm to produce a working DOS text editor.
> >
> > This morning he assembled the same code with nasm for linux and it
> > produced a working text editor, but it is in DOS not linux.
> >
> > What step did he miss? It is over 2000 lines of code so I don't want to
> > include it in my posting.
> >
> > He would like to use this editor in linux and contribute it to basiclinux
> > users once we get it documented. It does a lot more than e3 in only 4K.
> >
> > _______________________________________________
> > BasLinux mailing list
> > BasLinux AT lists.ibiblio.org
> > http://lists.ibiblio.org/mailman/listinfo/baslinux
> >
> >
> _______________________________________________
> BasLinux mailing list
> BasLinux AT lists.ibiblio.org
> http://lists.ibiblio.org/mailman/listinfo/baslinux
>





Archive powered by MHonArc 2.6.24.

Top of Page