wiki:Documentation/UserGuide

Version 2 (modified by dsolyga, 12 years ago) (diff)

--

How to page

This page will answer some questions like How to Install ORCHIDEE on my laptop? How To launch run?

How to install ORCHIDEE on an linux pc (Ubuntu or Fedora distribution)

This installation guide has been tested on a laptop computer using Ubuntu 12.04 version. Softwares used : gcc (C compiler), gfortran (Fortran 90 compiler), subversion (version control system), netcdf 3.6.3
Follow the steps and you will be able to compile and launch ORCHIDEE in sequential on a point to test it !

1. Installing netcdf library

The most difficult part consists to install the netcdf library. The version chosen is netcdf 3.6.3 ; it is entirely sufficient for your laptop.

Download netcdf : Open a terminal and type the following command (> represents the prompt) to download netcdf 3.6.3 :

    >   wget http://www.unidata.ucar.edu/downloads/netcdf/ftp/netcdf-3.6.3.tar.gz

Extract the archive :

    >    tar -xvzf netcdf-3.6.3.tar.gz

A directory called netcdf-3.6.3 will be created. Go inside it :

    >    cd  netcdf-3.6.3

If you type ls, you will find :

    > ls
acinclude.m4  config.guess  configure     cxx      dods.m4   fortran     libsrc     Makefile.am  man4      ncdump  nc_test   README
aclocal.m4    config.h.in   configure.ac  cxx4     examples  INSTALL     libsrc4    Makefile.in  missing   ncgen   nc_test4  RELEASE_NOTES
compile       config.sub    COPYRIGHT     depcomp  f90       install-sh  ltmain.sh  man          ncdap.m4  nctest  nf_test   win32

Now focus on the script called configure. This script uses different options like (look at this page to know more ): I execute this script like this :

      >  ./configure  --disable-largefile --disable-cxx

In my case, I deactivate the creation of large netcdf files (larger than 2 GB) with the option --disable-largefile. I also deactivate the creation of netcdf libraries for C++ because I don't need it. But to create netcdf libraries for FORTRAN, you have to create netcdf libraries for C. If you have a C compiler and a FORTRAN compiler, you will have no problems. Now you need to be root user. If you are on Ubuntu system (or Debian), type :

      >  sudo su

On Fedora :

      >  su

Enter your password then execute in the following order :

      > make

( compile netcdf on your computer.) Then

      > make check

( Test the buiding ) and finally the installation :

      > make install

If your installation was successful, the following message will appears :

+-------------------------------------------------------------+
| Congratulations! You have successfully installed netCDF!    |
|                                                             |
| CAUTION:                                                    |
|                                                             |
| If you have not already run "make check", then we strongly  |
| recommend you do so. It does not take very long.            |
|                                                             |
| Before using netCDF to store important data, test your      |
| build with "make check".                                    |
|                                                             |
| NetCDF is tested nightly on many platforms at Unidata       |
| but your platform is probably different in some ways.       |
|                                                             |
| If any tests fail, please see the netCDF web site:          |
| http://www.unidata.ucar.edu/software/netcdf/                |
|                                                             |
| NetCDF is developed and maintained at the Unidata Program   |
| Center. Unidata provides a broad array of data and software |
| tools for use in geoscience education and research.         |
| http://www.unidata.ucar.edu                                 |
+-------------------------------------------------------------+

After, you can delete the directory netcdf-3.6.3 :

     >  rm -rf netcdf-3.6.3  netcdf-3.6.3.tar.gz

2. Installing ORCHIDEE

After this hard task, you need to install the modipsl environment into MY_ORCHIDEE (you can change the name of this directory) :

      >  svn co http://forge.ipsl.jussieu.fr/igcmg/svn/modipsl/trunk MY_ORCHIDEE

Then go to :

      >  cd MY_ORCHIDEE/util

You can install a public version on your laptop. Execute :

      > ./model ORCHIDEE_TAG

If you are a developer of ORCHIDEE, you can download your own version with the script recup_my_ORCHIDEE (see SVN course for that). Nearly the end ! Edit AA_make.gdef and replace the following line by :

#-Q- gfortran  F_C = gfortran -c

by

#-Q- gfortran  F_C = gfortran -c -cpp

and execute the script called ins_make :

    >  ./ins_make -t gfortran

Then go to modeles/ORCHIDEE_OL :

    >  cd ../modeles/ORCHIDEE_OL

and finally compile :

   >  make; make teststomate; make forcesoil

CONGRATULATIONS, it's done !

Attachments (5)