www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/05/28/06:24:23

Date: Sun, 28 May 2000 13:23:32 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: djgpp AT delorie DOT com
Subject: Re: MASM coff images
In-Reply-To: <3930ec5c.5410549@news.freeserve.net>
Message-ID: <Pine.SUN.3.91.1000528131819.18901A@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Sun, 28 May 2000, Steamer wrote:

> >PUBLIC _setText
> >_setText PROC C
> >  mov ah, 0
> >  mov al, 3
> >  int 10
> >  ret
> >_setText ENDP
> 
> You can't call real-mode BIOS interrupts directly from 32-bit protected
> mode and expect it work.

Actually, you can.  The interrupt gets reflected to real mode, and if the 
function is register-based (i.e., does not involve any buffers), like in 
this case, it will work.

It *is* true that calling interrupts via DPMI is the recommended way,
though.

> >gcc vgatest.c vga.obj -Wall -g -o vgatest.exe
> 
> Probably you need to rename vga.obj to vga.o, as I'm not sure that
> gcc recognises .obj as an object file extension.

I don't think this matters: any file with an unknown extension is
handled as if it were an object file.

I think running objdump with different switches on vga.obj will reveal 
what does the compiler and the linker think about that file.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019