GEOS-5 Checkout and Build Instructions: Difference between revisions
Line 8: | Line 8: | ||
With the above step complete, let's get ourselves ready to check out the code. We'll be using the UNIX ''cvs'' command to check out the code. The basic syntax is: | With the above step complete, let's get ourselves ready to check out the code. We'll be using the UNIX ''cvs'' command to check out the code. The basic syntax is: | ||
% cvs -d $CVSROOT checkout -r TAGNAME MODULENAME | % cvs -d $CVSROOT checkout -r TAGNAME MODULENAME | ||
Here, $CVSROOT specifies the CVS repository we'll be getting the code from, MODULENAME is the particular module (set of code) we'll be checking out, and TAGNAME is a particular version of that module. Let's fill in the blanks: | Here, $CVSROOT specifies the CVS repository we'll be getting the code from, MODULENAME is the particular module (set of code) we'll be checking out, and TAGNAME is a particular version of that module. Let's fill in the blanks: | ||
% cvs -d :ext:c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma co -r GEOSdas-2_1_6 GEOSagcm | % cvs -d :ext:c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma co -r GEOSdas-2_1_6 GEOSagcm | ||
So our module is ''GEOSagcm'' and the tag is ''GEOSdas-2_1_6''. Note that I substituted the shortcut ''co'' for ''checkout'' in the above command. | So our module is ''GEOSagcm'' and the tag is ''GEOSdas-2_1_6''. Note that I substituted the shortcut ''co'' for ''checkout'' in the above command. | ||
Line 18: | Line 18: | ||
The above command is generally valid. You ought to be able to execute it and checkout some code. If you don't have your ''ssh keys'' setup on '''sourcemotel''' then you should be prompted for your '''sourcemotel''' password. The assumption here is that your username on '''sourcemotel''' is the same as on the machine you are checking the code out on. If not, modify the command like this: | The above command is generally valid. You ought to be able to execute it and checkout some code. If you don't have your ''ssh keys'' setup on '''sourcemotel''' then you should be prompted for your '''sourcemotel''' password. The assumption here is that your username on '''sourcemotel''' is the same as on the machine you are checking the code out on. If not, modify the command like this: | ||
% cvs -d :ext:SOURCEMOTEL_USERNAME@c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma co -r GEOSdas-2_1_6 GEOSagcm | % cvs -d :ext:SOURCEMOTEL_USERNAME@c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma co -r GEOSdas-2_1_6 GEOSagcm | ||
Here's a couple of short cuts. So that you don't have to type in the ''-d :ext:c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma'' business all the time, you can add the following lines to your, e.g., ''.cshrc'' file: | Here's a couple of short cuts. So that you don't have to type in the ''-d :ext:c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma'' business all the time, you can add the following lines to your, e.g., ''.cshrc'' file: | ||
setenv CVSROOT ':ext:c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma' | setenv CVSROOT ':ext:c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma' | ||
setenv CVS_RSH ssh | |||
setenv CVS_RSH ssh | |||
Modify as appropriate if you need to put your username in or if you use a different shell (i.e., put the analog of these lines into your .bashrc file or whatever). | Modify as appropriate if you need to put your username in or if you use a different shell (i.e., put the analog of these lines into your .bashrc file or whatever). |
Revision as of 11:18, 15 October 2008
The instructions on this page are a summary of the GEOS-5 tutorial Arlindo da Silva has been presenting. For the moment, we presume that the user has an account on sourcemotel and access to the NCCS machines (e.g., discover).
How to Check Out the Code
Find a place to store and build the code
The GEOS-5 (AGCM) source code checks out at about 40 MB of space. Once compiled, the complete package is about 500 MB. Your home space on discover may not be sufficient for checking out and building the code. You should consider either requesting either a larger quota in your home space (call the tag x6-9120 and ask, telling them you are doing GEOS-5 development work) or building in your (larger) nobackup space. But consider, nobackup is not backed up. So be careful...
Setup your environment to check out code
With the above step complete, let's get ourselves ready to check out the code. We'll be using the UNIX cvs command to check out the code. The basic syntax is:
% cvs -d $CVSROOT checkout -r TAGNAME MODULENAME
Here, $CVSROOT specifies the CVS repository we'll be getting the code from, MODULENAME is the particular module (set of code) we'll be checking out, and TAGNAME is a particular version of that module. Let's fill in the blanks:
% cvs -d :ext:c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma co -r GEOSdas-2_1_6 GEOSagcm
So our module is GEOSagcm and the tag is GEOSdas-2_1_6. Note that I substituted the shortcut co for checkout in the above command.
The above command is generally valid. You ought to be able to execute it and checkout some code. If you don't have your ssh keys setup on sourcemotel then you should be prompted for your sourcemotel password. The assumption here is that your username on sourcemotel is the same as on the machine you are checking the code out on. If not, modify the command like this:
% cvs -d :ext:SOURCEMOTEL_USERNAME@c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma co -r GEOSdas-2_1_6 GEOSagcm
Here's a couple of short cuts. So that you don't have to type in the -d :ext:c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma business all the time, you can add the following lines to your, e.g., .cshrc file:
setenv CVSROOT ':ext:c-sourcemotel.gsfc.nasa.gov:/cvsroot/esma'
setenv CVS_RSH ssh
Modify as appropriate if you need to put your username in or if you use a different shell (i.e., put the analog of these lines into your .bashrc file or whatever).