Index: BOL/script_install/install.sh
===================================================================
--- BOL/script_install/install.sh	(revision 2409)
+++ BOL/script_install/install.sh	(revision 2430)
@@ -74,5 +74,5 @@
 ## compile_with_fcm=1 : use makelmdz_fcm, possible a of version 20111103.trunk (LMDZ5/trunk rev 1578)
 ## compile_with_fcm=0 : use makelmdz
-compile_with_fcm=1
+compile_with_fcm=0
 
 
@@ -439,13 +439,45 @@
   cd $MODEL/modipsl/modeles/ORCHIDEE
   echo OKpwd ; pwd
-  if [ -d src_parallel ] ; then
-     liste_src="parallel parameters global stomate sechiba driver"
+
+  export ORCHPATH=`pwd`
+  if [ -d tools ] ; then
+#     orchidee_rev=2247
      veget_version=orchidee2.0
+      cd arch
+      fpp_flags='-P -traditional'
+      sed -e s:"%COMPILER        .*.$":"%COMPILER            $compilo":1 \
+     -e s:"%LINK            .*.$":"%LINK                $compilo":1 \
+     -e s:"%FPP_FLAGS       .*.$":"%FPP_FLAGS           $fpp_flags":1 \
+     -e s:"%PROD_FFLAGS     .*.$":"%PROD_FFLAGS         $OPTIM":1 \
+     -e s:"%DEV_FFLAGS      .*.$":"%DEV_FFLAGS          $OPTDEV":1 \
+     -e s:"%DEBUG_FFLAGS    .*.$":"%DEBUG_FFLAGS        $OPTDEB":1 \
+     -e s:"%BASE_FFLAGS     .*.$":"%BASE_FFLAGS         $OPTPREC -cpp":1 \
+     arch-gfortran.fcm > arch-local.fcm
+     echo "NETCDF_LIBDIR=\"-L${ncdfdir}/lib -lnetcdf\"" > arch-local.path
+     echo "NETCDF_INCDIR=${ncdfdir}/include" >> arch-local.path
+     echo "IOIPSL_INCDIR=$ORCHPATH/../../lib" >> arch-local.path
+     echo "IOIPSL_LIBDIR=$ORCHPATH/../../lib" >> arch-local.path
+     cd ../
+# compiling ORCHIDEE sequential mode
+     ./makeorchidee_fcm -noxios -prod -parallel none -arch local
   else
-     # Obsolete, for ORCHIDEE_beton only
-     liste_src="parameters stomate sechiba "
-     # A trick to compile ORCHIDEE depending on if we are using real*4 or real*8
-     cd src_parameters ; \cp reqdprec.$real reqdprec.f90 ; cd ..
-     veget_version=orchidee1.9
+     if [ -d src_parallel ] ; then
+       liste_src="parallel parameters global stomate sechiba driver"
+       veget_version=orchidee2.0
+     else
+       # Obsolete, for ORCHIDEE_beton only
+       liste_src="parameters stomate sechiba "
+       # A trick to compile ORCHIDEE depending on if we are using real*4 or real*8
+       cd src_parameters ; \cp reqdprec.$real reqdprec.f90 ; cd ..
+       veget_version=orchidee1.9
+     fi
+     for d in $liste_src ; do src_d=src_$d
+        echo src_d $src_d
+        echo ls ; ls
+        if [ ! -d $src_d ] ; then echo Problem orchidee : no $src_d ; exit ; fi
+        cd $src_d ; \rm -f *.mod make ; make clean
+        make ; if [ "$compilo" = "$gfortran" -o "$compilo" = "mpif90" ] ; then cp -f *.mod ../../../lib ; fi
+        cd ..
+     done
   fi
   echo liste_strc $liste_src
