Page 1 of 3
Visual Studio 2003
Posted: Sun Feb 29, 2004 5:24 pm
by gommo
Is it possible to use microsofts visual studio to create a small kernel.
I have been working on a small kernel in Linux using the base code from grubs\docs (kernel.c, boot.S, multiboot.h) as I am using an image that has grub preinstalled on it.
However, I was thinking of developing on windows instead and was wondering what kind of options are available. I.e. I need boot.S to be assembled to start @ 0x100000 and be linked first in the link phase etc..
Any one used visual studio for this??
Re:Visual Studio 2003
Posted: Sun Feb 29, 2004 8:12 pm
by Neo
use DJGPP, the GCC port for windows. it would be familiar if you've been using linux and also is OSS. You can get it from
delorie.com. IIRC osdever has a copy in their
downloads sections.
You could use a linker script for the better control of the sections in your program
www.delorie.com/gnu/docs/binutils/ld_6.html has more details.
Re:Visual Studio 2003
Posted: Sun Feb 29, 2004 8:36 pm
by Schol-R-LEA
While AFAICT it is possible to use Visual Studio 6.0 (or more specifically, Visual C++) and I think some here do so, it is a problematic choice because it means you will need to use a different compiler if and when you start developing within the OS itself. Offhand, I don't know what you'd need to do to get it to produce completely freestanding object code.
(BTW, if any of you do know these details, please add them to the
Wiki OS Dev FAQ. Try to be as accurate and complete as possible!)
I cannot say for certain if Visual Studio .NET can be used or not; I imagine that as long as you compile native rather than .NET IDL, and have all the 'Managed C++' features turned off, it should be otherwise the same as VC++ 6.0.
This is assuming you mean to use C or C++; none of the other languages supported by VS are suitable for OS development, as they are all highly OS (or .NET) dependent and have heavy runtime requirements.
As for options, well, in addition to DJGPP (which Neo mentions) there is also Cygwin and MingW, two ports for Windows of the GNU tools (DJGPP is for MS-DOS using a 32-bit extender). Details about all three (as well as development tools using them such as RHIDE and Dev-C++) can be found in the
FAQ. There is also LCC32, Watcom C++ and Borland C++, though the latter two at least present the same problems as VC++ does.
Re:Visual Studio 2003
Posted: Sun Feb 29, 2004 11:30 pm
by gommo
Yeah I maybe should have been more specific. I would be definitly using just ANSI C or C++. Not .NET. I would just like to use the VIsual Studio IDE as such but having to use a different compiler and all that basically means I'm just using it as a glorified text editor.
In the meantime I'll just keep going with my Linux based one I think.
Thanks
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 2:01 am
by bubach
U could use GCC and dev-C++
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 2:24 am
by Solar
...or KDevelop, or Eclipse, or you could be "a real programmer" and use EMacs...
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 2:37 am
by Candy
Solar wrote:
...or KDevelop, or Eclipse, or you could be "a real programmer" and use EMacs...
What's wrong with emacs? I've only used emacs for AOS up to now...
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 3:04 am
by Solar
Nothing wrong with it, but calling it an IDE is a long shot.
(Says this and prepares to be flamed... wait, this isn't a Linux forum... ;D )
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 5:27 am
by distantvoices
hehe ...
*pulls out the flame thrower ...*
emacs may be the holy egglaying milkwoolswine, but VIM is the holy grail of editors: it is quick, has nice commands directly under the fingertips and is easy to use
Honestly, I use it for editing bash scripts, php scripts and thingses in /etc.
for my daily programming **** I use Power Builder (gg) and tomDoors (editing Cobol sources on a bs2000 host), and at home, for OS brewing: KATE, gcc, nasm and ld. That's it. suficces to say, tht at least three shells are open at the same time on my desktop. *gg*
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 5:48 am
by Candy
beyond infinity wrote:
*pulls out the flame thrower ...*
Not again... Anyway, only a real additive response, no flames (or at least, I'll try not to).
emacs may be the holy egglaying milkwoolswine, but VIM is the holy grail of editors: it is quick, has nice commands directly under the fingertips and is easy to use
<esc>:wq doesn't ring a bell with me when I want to save a file and quit. Admitted, emacs doesn't have such an intuitive command either, but I don't know of a half-decent console editor that does. No comments on usability of either, they're both as ****ed up as the other.
Honestly, I use it for editing bash scripts, php scripts and thingses in /etc.
for my daily programming **** I use Power Builder (gg) and tomDoors (editing Cobol sources on a bs2000 host), and at home, for OS brewing: KATE, gcc, nasm and ld. That's it. suficces to say, tht at least three shells are open at the same time on my desktop. *gg*
At home, no true emacs (who wants 5M in mem for editing a file?) but jove, which only misses all those incredible editing options and the super-debug-compile-mode thingies that you can reach with more than 2 complex keystrokes and nobody even really knows, let alone uses. Aside with that, usually a couple of IRL books, some virtual books (in whatever editor is required / usable), browser with this forum & a few tabs of reference in RBIL at ctyme.com/rbrown.htm for asm programming, a console for bochs debugging, plus a set of consoles with jove for editing the source, both on this computer and the other two I only use as a console interface to the main one
. I have 256MB of ram, which says "imitate THAT" to winxp, and I never have it more than half full.
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 5:51 am
by Solar
Don't get into an editor pro-and-con flamewar here, or I'll tell you that the reason I'm finally switching to Linux these days is, I discovered that
UltraEdit can be run using wine... (I believe that Linux simply
lacks any
decent editor. And yes, I am
fluent in vim, and have used emacs more than once.
)
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 6:00 am
by Candy
Solar wrote:
Don't get into an editor pro-and-con flamewar here ... (I believe that Linux simply
lacks any
decent editor. And yes, I am
fluent in vim, and have used emacs more than once.
)
That was the bulk of my post. Did you even bother to read it?
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 6:41 am
by distantvoices
Ha, neither Me is bothering to start any flamewar *rofl* I just play with words and what decent writers call sarcasm/irony.
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 6:52 am
by Pype.Clicker
Thou shalt not use Another Text Editor than EMACS
btw, as the editor is the interface between your project and yourself and that all the possible instance of 'yourself' doesn't have the same preference, i don't believe in the One True Editor ...
I do love customizing every bits and put things the initial software designer didn't thought of, so EMACS is good for me ... I found the 'M-x' stuff intuitive but i don't expect other people to feel the same ...
btw, what was that thread about ?
Except if you have good reasons to switch to Windows for dev'ing, i would recommend to stick with your current environment. Or be prepared to face boring things like case-(in)sensitivity in file names, disappeared tools, need for a cross-compiler and things alike.
Re:Visual Studio 2003
Posted: Mon Mar 01, 2004 7:18 am
by Solar
Pype.Clicker wrote:
Except if you have good reasons to switch to Windows for dev'ing, i would recommend to stick with your current environment. Or be prepared to face boring things like case-(in)sensitivity in file names, disappeared tools, need for a cross-compiler and things alike.
[me=Solar]chuckling about case sensitivity being one of the things that makes me hate Unix's guts, and how building a cross-compiler has taught me several important and useful lessons...
[/me]