www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Compiling in BINARY format

reply kinghajj <kinghajj_member pathlink.com> writes:
I'm thinking of writing a small OS in D, and I need to know how to compile the
kernel in BINARY format (not PE/ELF/etc.).
Jan 31 2005
next sibling parent "Walter" <newshound digitalmars.com> writes:
"kinghajj" <kinghajj_member pathlink.com> wrote in message
news:ctmhqj$2251$1 digitaldaemon.com...
 I'm thinking of writing a small OS in D, and I need to know how to compile

 kernel in BINARY format (not PE/ELF/etc.).

The linker doesn't have that capability. However, the PE format is pretty simple to write a converter for that will convert it to binary.
Jan 31 2005
prev sibling next sibling parent "=?iso-8859-1?Q?Robert_M._M=FCnch?=" <robert.muench robertmuench.de> writes:
On Tue, 1 Feb 2005 00:17:23 +0000 (UTC), kinghajj  
<kinghajj_member pathlink.com> wrote:

 I'm thinking of writing a small OS in D, and I need to know how to  
 compile the kernel in BINARY format (not PE/ELF/etc.).

Hi, I have done this too. I made it up to be able to outpu text. But no input (yet). I'm using GRUB and than you can compile the stuff into ELF files via the Linux version of D. Makes things a lot simpler. -- Robert M. Münch Management & IT Freelancer http://www.robertmuench.de
Feb 01 2005
prev sibling next sibling parent Roberto Mariottini <Roberto_member pathlink.com> writes:
In article <ctmhqj$2251$1 digitaldaemon.com>, kinghajj says...
I'm thinking of writing a small OS in D, and I need to know how to compile the
kernel in BINARY format (not PE/ELF/etc.).

Using the MultiBoot standard (see http://www.gnu.org/software/grub/manual/multiboot/multiboot.html), you won't need a kernel image in a pure binary image, you can use non-relocatable ELF/PE/etc... GRUB (http://www.gnu.org/software/grub/) is a MultiBoot compliant boot loader. To reduce the start-up time, you can use also OSLib (http://oslib.sourceforge.net/overview.html), a library to ease the development of operating systems. Freedos32 (http://freedos-32.sourceforge.net/) is an example of a MultiBoot compliant OS that uses OSLib. Ciao
Feb 01 2005
prev sibling parent J C Calvarese <jcc7 cox.net> writes:
In article <ctmhqj$2251$1 digitaldaemon.com>, kinghajj says...
I'm thinking of writing a small OS in D, and I need to know how to compile the
kernel in BINARY format (not PE/ELF/etc.).

I don't know anything about this subject, but other people have taken steps to write a small OS in D. Maybe some of the information on this page will prove useful: http://www.prowiki.org/wiki4d/wiki.cgi?KernelWithD Good luck! jcc7
Feb 01 2005