delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/01/29/15:13:35

Date: Thu, 30 Jan 1997 09:07:55 +0000
From: Bill Currie <billc AT blackmagic DOT tait DOT co DOT nz>
Subject: Re: Any one writing OS in DJGPP?
To: Francis BOURQUE <bourque AT art DOT alcatel DOT fr>
Cc: djgpp AT delorie DOT com
Reply-to: billc AT blackmagic DOT tait DOT co DOT nz
Message-id: <32F064EB.2BD4@blackmagic.tait.co.nz>
Organization: Tait Electronics NZ
MIME-version: 1.0
References: <Pine DOT SGI DOT 3 DOT 93 DOT 970127104340 DOT 2166A-100000 AT gibson DOT eee DOT upd DOT edu DOT ph>
<32EF12AD DOT 59E2B600 AT art DOT alcatel DOT fr>

Francis BOURQUE wrote:
> 
> I've done the exercise of writing an tiny OS with DJGPP myself (which
> I lost in a HD crash) and I would like to ask two questions to those
> who tried it too:
> 
> Is there a way to generate 16-bits code with DJGPP or do we still have
> to use a commercial compiler/assembler like Borland C++/v3.1???

Use djasm (comes in djdev*).  It's the assembler used to produce the
real 
mode stub for every djgpp executable.  I used it to write my boot sector 
wich loads the coff file, enters protected mode, and jumps into the 
loaded image.

> 
> At what step do you stop programming in assembly and use the C language?

Assembly for the boot sector, then (for me) about 10 lines of gas
assembly which turns off the floppy motor, calls the startup code (C)
and then main().

> 
> Thanks for your answers.
> 
No problem

Bill
-- 
Leave others their otherness.

- Raw text -


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