How to get Stellarium's source code
Latest revision as of 08:04, 11 October 2010
To get Stellarium's source code, you can choose between several different sources, depending on what exactly you need.
If you are unfamiliar with revision control systems like Bazaar, Subversion (SVN) or CVS, you can start by reading Wikipedia's article on revision control and continue to their websites (linked below). There are also pages with instructions on using them in this wiki (again, linked below). In short, revision control means that code can be stored online in a central location (a repository) as a series of changes (revisions) and a copy of its state at any time can be requested.
 Source packages
The source code of Stellarium releases is available as source packages for Linux, compressed in .tar.gz format. Due to the nature of the packaging script, the code in the packages can be used to build Stellarium on all three platforms (this is valid for at least the 0.10.* series).
Tarballs (.tar.gz files) can be opened by any decent file archiving application. Windows users can use the free/open-source 7Zip.
 Revision control
Stellarium has gone through three different revision control systems through its history, which means that its code is in three public repositories on two different websites (SourceForge and Launchpad). Starting from the most recent:
- Bazaar (BZR) - website, download. The Windows packages includes TortoiseBazaar that integrates in Windows Explorer (just like TortoiseSVN) and Bazaar Explorer, so you won't have to use the command line. Bazaar Explorer is included also in the Mac OS X installer.
- Subversion (SVN) - website, downloads.TortoiseSVN is a nice client for Windows that allows avoiding the command line..
- CVS - website. TortoiseCVS is a client for Windows that allows avoiding the command line. (But you didn't expect that, did you?)
 Development version
Since June 2010, Stellarium's "trunk" (the main code) is in a Bazaar repository hosted at Launchpad:
- Main page, trunk branch (code browser for the trunk branch)
- Instructions on how to check out the code with Bazaar
Launchpad allows anonymous users to check out (download) code. This will allow you to create patches and submit them.
If you want to create a personal Bazaar branch that can be merged with the trunk, you need to register in Launchpad. Here is what such a user branch looks like: .
The trunk code contains the code of the plug-ins that come with Stellarium, as they are statically linked at build time. Their code can be found in the "plugins" sub-directory (code browser for /trunk/plugins). As of October 2010, this includes:
- Angle Measure
- Compass Marks
- HelloStelModule (not packaged: example plug-in)
- Log Book (not packaged in 0.10.5: work in progress)
- Telescope Control
- Text User Interface
In theory, these plug-ins can be built as stand-alone plug-ins (that are separate dynamically linked libraries and are loaded on runtime), but the last time I tried to do it I was not able to.
The code for some example stand-alone plug-ins can be found in the old Subversion repository at SourceForge: Code browser for /trunk/extmodules. Only that directory can be checked out with:
svn co https://stellarium.svn.sourceforge.net/svnroot/stellarium/trunk/extmodules stellarium-plugins
As of October 2010, this includes:
- ExampleDialog - demonstrates displaying a window in Stellarium and adding a button to the bottom toolbar
- ExamplePainter - demonstrates painting on the screen
- AddRemoveLandscapes - obsolete, this feature was incorporated in the trunk after 0.10.5 in a much more mature form
- KeyBindings - obsolete, just an experimental plug-in
- VirGO - obsolete, old repository for VirGO
 Old repositories
Between August 2006 and June 2010, Stellarium used a Subversion code repository hosted at SourceForge. It is still online for archive purposes:
Old releases before 0.10.5, including 0.10.5, are available in the "tags" directory: code browser for /tags
See also the explanation about plugins above.
Before the end of August 2006, Stellarium used a CVS code repository hosted at SourceForge. It is still online for archive purposes: