Bona Fide OS Development
http://forums.osdever.net/

Multiple main()s
http://forums.osdever.net/viewtopic.php?f=5&t=52
Page 2 of 3

Author:  Michael [ Sun Oct 18, 2009 1:16 pm ]
Post subject:  Re: Multiple main()s

ctimko wrote:
Oh, neato. So then you are just using the loader as the first position on the "primary disk"


My inital loader is in assembly. I plan to use a secondary loader to load other systems later on

Quote:
so no grub.


Of course not - I hate using premade software for my own programs - I made my own bootloader.

Author:  ctimko [ Sun Oct 18, 2009 2:14 pm ]
Post subject:  Re: Multiple main()s

nifty. did you follow a tutorial or make it without one... I would like to see that tutorial, or if you could make one, that would be neat.

Charles

Author:  Love4Boobies [ Mon Oct 19, 2009 4:14 pm ]
Post subject:  Re: Multiple main()s

As a clarification, you can't have the same symbol defined twice or you'll get a linker error. Apart from that, you can also have only one entry point (which may or may not be main(), depending on the implementation of the compiler). That's why you can never link two executable object files together.

Author:  ctimko [ Mon Oct 19, 2009 10:57 pm ]
Post subject:  Re: Multiple main()s

+rep (speaking of, we need rep system)

Author:  Kieran [ Tue Oct 20, 2009 2:58 am ]
Post subject:  Re: Multiple main()s

I was thinking the same, a rep system would be good :)

Author:  Love4Boobies [ Tue Oct 20, 2009 10:58 am ]
Post subject:  Re: Multiple main()s

Michael wrote:
Quote:
so no grub.


Of course not - I hate using premade software for my own programs - I made my own bootloader.


There's something wrong with your judgement here. This is the whole point of open source - people don't need to rewrite the same crap over and over again and can focus on whatever they want to bring new.

Author:  Michael [ Tue Oct 20, 2009 11:06 am ]
Post subject:  Re: Multiple main()s

Yes, but I still dislike using Open Source Projects for my Projects.

Author:  ctimko [ Tue Oct 20, 2009 4:08 pm ]
Post subject:  Re: Multiple main()s

I understand where he is coming from. I decided that I wanted to write my own, for the experience and the learning, but then I realized that it would be a little more work than I should start with. I tried starting with the boot loader, but I really had no idea what was going on, so I picked Grub. I would like to customize it a bit more, but I will worry about it after the kernel is running.

Author:  Love4Boobies [ Thu Oct 22, 2009 1:59 am ]
Post subject:  Re: Multiple main()s

Well okay, Michael. But you won't get very far. You know how many lines of code real OSes have? You wouldn't have time to code anything serious on your own if you lived 200 years.

Author:  Jarvix [ Thu Oct 22, 2009 4:32 am ]
Post subject:  Re: Multiple main()s

I was running my small kernel with GRUB first. But afer then i wanted my kernel in 3GiB and some other paging stuff, so i made my simple bootloader with elf parser and paging. Most code is seen on the tutorials of Mike (brokenthorn)

// PHPnerd

Page 2 of 3 All times are UTC - 6 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/