(experimental instructions for) Building and Testing C10

Getting started

This page is experimental and actually links to the head of the Cloudy svn trunk. Appropriate links will be created when C10 is released.

These instructions assume you are working with a *nix system with GNU tools installed. You need functional versions of g++ (or another C++ compiler), svn, perl, and make to build Cloudy.

Most Linux distributions will have what you need. Mac OS X users will need to download Apple Developer's Tools (free with registration from Apple's developer website) which includes these tools.

Download Cloudy

You do this with svn. Go to the location where you want to install the code and execute the command

svn checkout

The code will be downloaded into a new directory created under your current location. A large number of files will be downloaded.

What you have downloaded

The top directory will have the same name as the end of the svn version you checked out. Below this directory are the following subdirectories:

  • data - data files needed by the code to function.
  • docs - The documentation.
  • doxygen - input for the doxygen documentation system.
  • library - some helper files
  • source - The C++ source. The code can be built in this directory, or in one of the sys_XXX directories beneath it.
  • tsuite - A set of directories which contain test cases for Cloudy.

Choose a compiler and location to build the executable

cd into the source directory. Do a ls -d sys_* to see the compilers we support. Most people will use the GNU g++ compiler. If you use g++ you can build the executable either within the source or sys_gcc directories. Some other compilers we support include those from Intel, Portland, and Sun.

Build the executable =

Use the make command to build the executable. If you are on a system with more than one core you can use the -j option to speed up the build by using more cores. Two examples:

make -j 8

The first uses a single core while the second uses eight cores. This will create the executable file cloudy.exe

Run the smoke test

Do a simple test by running Cloudy as follows:


The first line executes the file cloudy.exe while the remaining lines, the word "test" followed by several carriage returns, tells the code to perform its smoke test.

If the smoke test is successful you will see the following as the last line

[Stop in cdMain at ../maincl.cpp:417, Cloudy exited OK]

Review the documentation

The documentation is a set of PDF files that live in the docs directory of the download. Look at the Quick Start Guide first.

Run the auto and slow test suites

The svn checkout will include the auto and slow directories beneath the tsuite directory. These contain a number of test cases which are used both to validate the code and to illustrate its use. These tests should be run to confirm that you have a valid executable.

Use the script to run the tests. It has two options. The first indicates which compiler you used to build the code. It is the name of the directory where the code was build in a previous step above. We assume sys_gcc in the following example. The second option is a number indicating how many cores should be allocated to the test. The tests will be run in parallel using these cores. The script can use up to 20 cores profitably for auto, and about ten cores for slow. So, to run the auto test suite using eight cores you would enter the auto directory and enter the following command:

./ sys_gcc 8

The results of the models are checked after the calculations are complete. You will find a summary of all serious problems in the file serious.txt. This will be empty if the calculation is successful.

Updating your copy of the code

Could we make it as simple as

svn update

This would require a tag that did not change names, perhaps something like c10_current?

Return to DeveloperPages

Return to main wiki page

Last modified 10 years ago Last modified on 2010-03-15T22:34:11Z