Learn virtualbox via source code

Discussions related to using the OSE version of VirtualBox.

Learn virtualbox via source code

Postby white hat » 13. Mar 2019, 19:24

I want to learn about virtual box by reading its source code, Purpose to increase the level of C ++ programming. But the source code of virtualbox is too big, there are too many files. So I don't know where to start reading from. Can you guide the reading process so that it is easy to understand?
Thank you
white hat
Posts: 5
Joined: 6. Mar 2019, 10:52

Re: read source code

Postby mpack » 13. Mar 2019, 19:27

Are you asking that someone writes you a guide to the source code? I wouldn't hold my breath waiting for that to happen!

Besides, working out the structure of the build folders is part of the learning process. And I dare say that even some of the devs don't know what's in every nook and cranny. Look for comments in the source code and header files for clues as to what purpose each module serves, I think that's the only guidance you're going to get, that and the folder names which I think are quite easy to understand.

If you don't understand C++ then perhaps you'd do better to start with a smaller project first - Github should be bursting at the seams with suitable small projects that would interest you.
Site Moderator
Posts: 29194
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Learn virtualbox via source code

Postby socratis » 14. Mar 2019, 16:57

If you manage to get the source code built, one of the "key" commands is
Code: Select all   Expand viewCollapse view
kmk docs

There's a lot of reading there...
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
Site Moderator
Posts: 23751
Joined: 22. Oct 2010, 11:03
Location: Greece
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5

Re: Learn virtualbox via source code

Postby Yurii.Ch » 15. Mar 2019, 08:17

I will also add to Socratis answer, surprisingly a lot of information about the project structure could be found in Virtualbox User Guide, which you can download by the link (current version 6.0.4):
https://download.virtualbox.org/virtual ... Manual.pdf

I'm talking about the Chapter 10, Technical Background, and especially 10.2, Oracle VM VirtualBox Executables and Components.
You can find there list of the product components, and then find it in the source tree by simple text search, because Virtualbox source code at least structured very well. You also can find a lot about components and code structure from the Makefile.kmk, located in the project root directory.

You can read just Chapter 10, however, if you're going to contribute into Virtualbox OSE, or use it as a part of your opensource solution, you'd better read all the User Guide, it has tons of useful information about Virtualbox and virtualization technology itself.

If you're interested in contributing to the project, you can contact me personally, I have some experience in using it and our team has open positions for people with Virtualbox contributing experience.

Posts: 31
Joined: 16. Oct 2018, 08:47
Primary OS: Mac OS X other
VBox Version: OSE self-compiled
Guest OSses: Windows 7-10, Linux

Return to VirtualBox OSE

Who is online

Users browsing this forum: No registered users and 3 guests