Check out projects
Checking out a project
Before checking out a project, be sure that your development environment is set up for $G.
$G uses CVS for source control and you can read more about it on its official site or on Wikipedia.
After you have your Sandbox set up you can checkout a project. Even if you are working on Windows you should use Linux to perform CVS operations. Many projects will only build on certain platforms.
Project code will either be in the common/ or project/ top level CVS directories. The common/ directory has code that is shared by multiple projects in the project/ directory.
If you wanted to check out the "wrist" project, you would type:
> cd /research/graphics/users/$USER # Go into your Sandbox. > cvs co project/wrist # Creates: /research/graphics/users/goo/project/wrist/...
CVS requires that check outs be performed from the top level directory of your sandbox.
Please do not waste space in your sandbox and retain only the files you need. When you are done with your account please be sure to delete it.
Building a Project on Linux
Before a project can be built any dependent packages need to be in the import/ directory. The wrist project depends on Blitz.
> cp -R /research/graphics/tools/linux/import/blitz/ /research/graphics/users/$USER/import/blitz/
The wrist project is a large project composed of several programs and libraries. It follows the convention of using a Makefile in the top level directory to build the entire project. Each project developer decides how their projects are organized and how they are built. You'll need to look at documentation for a project to determine how to build it.
Continuing the wrist project example from above, you would type:
> cd /research/graphics/users/$USER/project/wrist > make all
Building a Project on Windows
The wrist project does not build on Windows. Instead we'll show how to build some of the common libraries. Your sandbox should be set up with the contents of the common/ directory so you will not need to check anything else out. The following examples use the native Windows command shell "cmd.exe".
The common/utility/ directory has some utilities used in several projects. Libraries are often configured to build on all available compilers. This way when you go to use a library a version is available for whatever compiler you choose.
> cd/d Y:\research\graphics\users\<User Id>\common\utility > make all > make install
The common/gg/ directory has several libraries that are useful for writing C/C++ applications. It depends on the utilities so it needs to be built after them. Only a portion of these libraries have been rewritten to build on Windows.
> cd/d Y:\research\graphics\users\<User Id>\common\gg > make all > make install
The common/mri/libmri/ directory is a library for processing MRI datasets. It depends on having the gg libraries installed. Note that the other directories under common\mri\ will not build on Windows.
> cd/d Y:\research\graphics\users\<User Id>\common\mri\libmri > make all > make install
The common/is3d/ directory has a library used by some for processing MRI datasets. It uses the g3d libraries; which is imported. If it has not been set up then you will need to do so.
> cd/d Y:\research\graphics\users\<User Id>\import > mkdir g3d > xcopy/e Y:\research\graphics\tools\linux\import\g3d\g3d_8_cl9 g3d\g3d_8_cl9
Only the is3d/src/ directory has been rewritten for Windows. Since g3d only links with the cl9 compiler, this directory must be built using cl9. If you have set G_COMPILER to a different compiler you will need to reset it.
> cd/d Y:\research\graphics\users\<User Id>\common\is3d\src > make all > make install