source: LMDZ5/trunk/makelmdz_fcm @ 2241

Last change on this file since 2241 was 2239, checked in by Ehouarn Millour, 9 years ago

Reorganizing physics/dynamics interface:

  • what is related to dynamics-physics interface is now in a seperate directory: dynlmdz_phy* for physics in phy*
  • 1d model and related dependencies (including a couple from "dynamics", set up as symbolic links) is now in subdirectory "dyn1d" of phy*.
  • "bibio" directory is now "misc" and should only contain autonomous utilities.
  • "cosp" is now a subdirectory of phylmd.

EM

  • Property copyright set to
    Name of program: LMDZ
    Creation date: 1984
    Version: LMDZ5
    License: CeCILL version 2
    Holder: Laboratoire de m\'et\'eorologie dynamique, CNRS, UMR 8539
    See the license file in the root directory
  • Property svn:eol-style set to native
  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 16.6 KB
RevLine 
[1279]1#!/bin/bash
2# $Id: makelmdz_fcm 2239 2015-03-23 07:27:30Z fhourdin $
3# This is a script in Bash.
4
[2098]5# FH : on ne cr\'ee plus le fichier arch.mk qui est suppos\'e exister par
[783]6# FH : ailleurs.
[2098]7# FH : ulterieurement, ce fichier sera pr\'e-existant pour une s\'erie
8# FH : de configurations en versions optimis\'ees et debug qui seront
9# FH : li\'es (ln -s) avec arch.mk en fonction de l'architecture.
10# FH : Pour le moment, cette version est en test et on peut cr\'eer les
11# FH : arch.mk en lan\c{}cant une premi\`ere fois makegcm.
[783]12#
[1279]13##set -x
[2202]14set -e
[783]15########################################################################
16# options par defaut pour la commande make
17########################################################################
18
[1279]19dim="96x72x19"
20physique=lmd
21filtre=filtrez
22grille=reg
23couple=false
24veget=false
[1865]25sisvat=false
[1990]26rrtm=false
[1279]27chimie=false
28parallel=none
[1680]29paramem="par"
[1279]30compil_mod=prod
31io=ioipsl
32LIBPREFIX=""
33cosp=false
[1802]34job=1
35full=''
[783]36
[1279]37LMDGCM=`/bin/pwd`
38LIBOGCM=$LMDGCM/libo
39LIBFGCM=$LMDGCM/libf
[2239]40DYN_COMMON_PATH=$LIBFGCM/dyn3d_common
[2084]41# path for optional packages, but default set to ".void_dir"
[2239]42FILTRE_PATH=$LMDGCM/.void_dir
43DYN_PHYS_PATH=$LMDGCM/.void_dir
[2084]44RRTM_PATH=$LMDGCM/.void_dir
45SISVAT_PATH=$LMDGCM/.void_dir
[1327]46COSP_PATH=$LMDGCM/.void_dir
[1578]47fcm_path=$LMDGCM/tools/fcm/bin
[783]48
49########################################################################
50#  Quelques initialisations de variables du shell.
51########################################################################
52
[1279]53CPP_KEY="" 
54INCLUDE=""
55LIB=""
56adjnt=""
57COMPIL_FFLAGS="%PROD_FFLAGS"
58PARA_FFLAGS=""
59PARA_LD=""
60EXT_SRC=""
[783]61
62########################################################################
63# lecture des options de mymake
64########################################################################
65
[1279]66while (($# > 0))
67  do
68  case $1 in
69      "-h") cat <<fin
[783]70Usage :
[1772]71makelmdz_fcm [options] -arch nom_arch exec
72[-h]                       : brief help
73[-d [[IMx]JMx]LM]          : IM, JM, LM are the dimensions in x, y, z (default: $dim)
74[-p PHYS]                  : set of physical parametrizations (in libf/phyPHYS), (default: lmd)
75[-prod / -dev / -debug]    : compilation mode production (default) / developement / debug
[1965]76[-c false/MPI1/OMCT]       : coupling with ocean model : MPI1/OMCT/false (default: false)
[1772]77[-v false/orchidee2.0/orchidee1.9/true] : version of the vegetation model to include (default: false)
78          false       : no vegetation model
79          orchidee2.0 : compile using ORCHIDEE 2.0 (or more recent version)
80          orchidee1.9 : compile using ORCHIDEE up to the version including OpenMP in ORCHIDEE : tag 1.9-1.9.5(version AR5)-1.9.6
81          true        : (obsolete; for backward compatibility) use ORCHIDEE tag 1.9-1.9.6
82[-chimie INCA/false]       : with INCA chemistry model or without (default: false)
[2238]83[-cosp true/false]    : compile with/without cosp package (default: false)
84[-sisvat true/false]  : compile with/without sisvat package (default: false)
85[-rrtm true/false]    : compile with/without rrtm package (default: false)
[1772]86[-parallel none/mpi/omp/mpi_omp] : parallelism (default: none) : mpi, openmp or mixted mpi_openmp
87[-g GRI]                   : grid configuration in dyn3d/GRI_xy.h  (default: reg, inclues a zoom)
[2097]88[-io ioipsl/mix/xios]                   : Input/Output library (default: ioipsl)
[1772]89[-include INCLUDES]        : extra include path to add
90[-cpp CPP_KEY]             : additional preprocessing definitions
91[-adjnt]                   : adjoint model, not operational ...
92[-mem]                     : reduced memory dynamics (if in parallel mode)
93[-filtre NOMFILTRE]        : use filtre from libf/NOMFILTRE (default: filtrez)
94[-link LINKS]              : additional links with other libraries
[1802]95[-j n]                     : active parallel compiling on ntask
96[-full]                    : full recompiling
[1772]97[-fcm_path path]           : path to the fcm tool (default: tools/fcm/bin)
98[-ext_src path]            : path to an additional set of routines to compile with the model
99 -arch nom_arch            : target architecture
100 exec                      : executable to build
[783]101fin
[1279]102          exit;;
[783]103
[1279]104      "-d")
105          dim=$2 ; shift ; shift ;;
106     
107      "-p")
108          physique="$2" ;  shift ; shift ;;
[783]109
[1279]110      "-g")
111          grille="$2" ; shift ; shift ;;
[783]112
[1279]113      "-c")
114          couple="$2" ; shift ; shift ;;
[783]115
[1279]116      "-prod")
117          compil_mod="prod" ; shift ;;
[1002]118
[1279]119      "-dev")
120          compil_mod="dev" ; shift ;;
[1002]121
[1279]122      "-debug")
123          compil_mod="debug" ; shift ;;
[1002]124
[1279]125      "-io")
126          io="$2" ; shift ; shift ;;
[783]127
[1279]128      "-v")
129          veget="$2" ; shift ; shift ;;
[783]130
[1865]131      "-sisvat")
132          sisvat="$2" ; shift ; shift ;;
133
[1990]134      "-rrtm")
135          rrtm="$2" ; shift ; shift ;;
136
[1279]137      "-chimie")
138          chimie="$2" ; shift ; shift ;;
[783]139
[1279]140      "-parallel")
141          parallel="$2" ; shift ; shift ;;
142     
143      "-include")
144          INCLUDE="$INCLUDE -I$2" ; shift ; shift ;;
[783]145
[1279]146      "-cpp")
147          CPP_KEY="$CPP_KEY $2" ; shift ; shift ;;
[1132]148
[1279]149      "-adjnt")
[1772]150          echo "not operational ... work to be done here ";exit
[1279]151          opt_dep="$opt_dep adjnt" ; adjnt="-ladjnt -ldyn3d "
152          optim="$optim -Dadj" ; shift ;;
[783]153
[1279]154      "-cosp")
155          cosp="$2" ; shift ; shift ;;
[1680]156     
157      "-mem")
158          paramem="mem" ; shift ;;
[783]159
[1279]160      "-filtre")
161          filtre=$2 ; shift ; shift ;;
[783]162
[1279]163      "-link")
164          LIB="$LIB $2" ; shift ; shift ;;
[1136]165
[1279]166      "-fcm_path")
167          fcm_path=$2 ; shift ; shift ;;
[783]168
[1279]169      "-ext_src")
170          EXT_SRC=$2 ; shift ; shift ;;
[1802]171      "-j")
172          job=$2 ; shift ; shift ;;
173      "-full")
174          full="-full" ; shift ;;
[783]175
[1279]176      "-arch")
177          arch=$2 ; shift ; shift ;;
[783]178
[1279]179      *)
180          code="$1" ; shift ;;
181  esac
182done
183
[1136]184###############################################################
[1755]185# path to fcm
[1136]186###############################################################
[1755]187# handle case when provided path to fcm was given as a relative
188# path (from makelmdz_fcm script directory) and not an absolute path
189if [[ ${fcm_path:0:1} != "/" ]] ; then
190  # prepend with makelmdz_fcm location
191  fcm_path=$(cd $(dirname $0) ; pwd)"/"${fcm_path}
192fi
[783]193
[1757]194# add fcm_path to PATH
195export PATH=${fcm_path}:${PATH}
196
[1755]197echo "Path to fcm:"
198echo ${fcm_path}
[1136]199
[783]200###############################################################
[2098]201# lecture des chemins propres \`a l'architecture de la machine #
[783]202###############################################################
[1279]203rm -f .void_file
204echo > .void_file
[1327]205rm -rf .void_dir
206mkdir .void_dir
[1279]207rm -f arch.path
208ln -s arch/arch-${arch}.path ./arch.path
[783]209source arch.path
210
211########################################################################
212# Definition des clefs CPP, des chemins des includes et modules
213#  et des libraries
214########################################################################
215
[1279]216if [[ "$compil_mod" == "prod" ]]
217then
218  COMPIL_FFLAGS="%PROD_FFLAGS"
219elif [[ "$compil_mod" == "dev" ]]
220then
221  COMPIL_FFLAGS="%DEV_FFLAGS"
222elif [[ "$compil_mod" == "debug" ]]
223then
224  COMPIL_FFLAGS="%DEBUG_FFLAGS"
225fi
[783]226
[1279]227if [[ "$physique" != "nophys" ]]
228then
[1615]229   #We'll use some physics
230   CPP_KEY="$CPP_KEY CPP_PHYS"
231   if [[ "${physique:0:3}" == "lmd" ]]
232   then
233   #For lmd physics, default planet type is Earth
[1279]234   CPP_KEY="$CPP_KEY CPP_EARTH"
[1615]235   fi
[2239]236   # set the dyn/phys interface path
237   DYN_PHYS_PATH="${LIBFGCM}/dynlmdz_phy${physique}"
[1279]238fi
[783]239
[2239]240if [[ "$filtre" == "filtrez" ]]
241then
242   FILTRE_PATH=${LIBFGCM}/$filtre
243fi
244
[1279]245if [[ "$chimie" == "INCA" ]]
246then
247   CPP_KEY="$CPP_KEY INCA"
248   INCLUDE="$INCLUDE -I${INCA_INCDIR}"
249   LIB="$LIB -L${INCA_LIBDIR} -lchimie"
250fi
[783]251
[1279]252if [[ "$couple" != "false" ]]
253then
[1965]254    if [[ "$couple" == "MPI1" ]]
255    then
256        CPP_KEY="$CPP_KEY CPP_COUPLE"
257        export OASIS_INCDIR=$LMDGCM/../../prism/X64/build/lib/psmile.MPI1
258        export OASIS_LIBDIR=$LMDGCM/../../prism/X64/lib
259        INCLUDE="$INCLUDE -I${OASIS_INCDIR}"
260        LIB="$LIB -L${OASIS_LIBDIR} -lpsmile.MPI1 -lmpp_io"
261    else
262        CPP_KEY="$CPP_KEY CPP_COUPLE CPP_OMCT"
263        INCLUDE="$INCLUDE -I${OASIS_INCDIR}"
264        LIB="$LIB -L${OASIS_LIBDIR} -lpsmile.MPI1 -lscrip -lmct -lmpeu"
265    fi
[1279]266fi
[783]267
[1279]268if [[ "$parallel" == "mpi" ]]
269then
270   CPP_KEY="$CPP_KEY CPP_PARA CPP_MPI"
271   PARA_FFLAGS="%MPI_FFLAGS"
272   PARA_LD="%MPI_LD"
273elif [[ "$parallel" == "omp" ]]
274then
275   CPP_KEY="$CPP_KEY CPP_PARA CPP_OMP"
276   PARA_FFLAGS="%OMP_FFLAGS"
277   PARA_LD="%OMP_LD"
278elif [[ "$parallel" == "mpi_omp" ]]
279then
280   CPP_KEY="$CPP_KEY CPP_PARA CPP_MPI CPP_OMP"
281   PARA_FFLAGS="%MPI_FFLAGS %OMP_FFLAGS"
282   PARA_LD="%MPI_LD %OMP_LD"
283fi
[783]284
[1279]285if [[ ( "$parallel" == "omp" || "$parallel" == "mpi_omp" ) \
286   && "$compil_mod" == "debug" ]]
287then
288    echo "Usually, parallelization with OpenMP requires some optimization."
289    echo "We suggest switching to \"-dev\"."
290fi
[783]291
[1811]292if [ "$veget" = "true" -o "$veget" = "orchidee1.9" -o "$veget" = "orchidee2.0" ]
[1279]293then
[1811]294#NB: option 'true': for backward compatibility. To be used with ORCHIDEE tag 1.9-1.9.6
295#    For this case, cpp flag ORCHIDEE_NOOPENMP must be added to the makelmdz_fcm arguments
296#    option orchidee1.9 : Compile with ORCHIDEE version up to the inclusion of OpenMP in ORCHIDEE : tag 1.9-1.9.5(version AR5)-1.9.6
[1279]297   INCLUDE="${INCLUDE} -I${ORCH_INCDIR}"
[1772]298   CPP_KEY="$CPP_KEY CPP_VEGET"
[1811]299# temporary, for Orchidee versions 1.9.* (before openmp activation)
300   if [[ "$veget" == "orchidee1.9" ]] ; then
301      CPP_KEY="$CPP_KEY ORCHIDEE_NOOPENMP"
302   fi
303   if [[ "$veget" == "orchidee2.0" ]] ; then
[1854]304      orch_libs="sechiba parameters stomate parallel orglob orchidee"
[1811]305   else
306      orch_libs="sechiba parameters stomate parallel orglob"
307   fi
308   LIB="${LIB} -L${ORCH_LIBDIR}"
309   for lib in ${orch_libs} ; do
310      if [ -f ${ORCH_LIBDIR}/lib${LIBPREFIX}$lib.a ] ; then
311         LIB="${LIB} -l${LIBPREFIX}$lib "
312      fi
313   done
314elif [[ "$veget" != "false" ]] ; then
[1772]315   echo "Option -v $veget does not exist"
316   echo "Use ./makelmdz_fcm -h for more information"
317   exit 
[1279]318fi
[783]319
[1865]320if [[ "$sisvat" == "true" ]]
321then
322   CPP_KEY="$CPP_KEY CPP_SISVAT"
[2084]323   SISVAT_PATH="$LIBFGCM/%PHYS/sisvat"
[1865]324fi
325
[1990]326if [[ "$rrtm" == "true" ]]
327then
328   CPP_KEY="$CPP_KEY CPP_RRTM"
[2084]329   RRTM_PATH="$LIBFGCM/%PHYS/rrtm"
[1990]330fi
331
[1279]332if [[ $io == ioipsl ]]
333then
334   CPP_KEY="$CPP_KEY CPP_IOIPSL"
335   INCLUDE="$INCLUDE -I${IOIPSL_INCDIR}"
336   LIB="$LIB -L${IOIPSL_LIBDIR} -l${LIBPREFIX}ioipsl"
[2097]337elif [[ $io == mix ]]
[1897]338then
339   # For now, xios implies also using ioipsl
340   CPP_KEY="$CPP_KEY CPP_IOIPSL CPP_XIOS"
341   INCLUDE="$INCLUDE -I${IOIPSL_INCDIR} -I${XIOS_INCDIR}"
342   LIB="$LIB -L${IOIPSL_LIBDIR} -l${LIBPREFIX}ioipsl -L${XIOS_LIBDIR} -l${LIBPREFIX}stdc++ -l${LIBPREFIX}xios"
[2097]343elif [[ $io == xios ]]
344then
345   # For now, xios implies also using ioipsl
346   CPP_KEY="$CPP_KEY CPP_IOIPSL CPP_XIOS CPP_IOIPSL_NO_OUTPUT"
347   INCLUDE="$INCLUDE -I${IOIPSL_INCDIR} -I${XIOS_INCDIR}"
348   LIB="$LIB -L${IOIPSL_LIBDIR} -l${LIBPREFIX}ioipsl -L${XIOS_LIBDIR} -l${LIBPREFIX}stdc++ -l${LIBPREFIX}xios"
[1279]349fi
[1897]350
[1279]351if [[ "$cosp" == "true" ]]
352then
353   CPP_KEY="$CPP_KEY CPP_COSP"
[2239]354   COSP_PATH="$LIBFGCM/phylmd/cosp"
[1279]355#   LIB="${LIB} -l${LIBPREFIX}cosp"
356fi
[783]357
[1551]358INCLUDE="$INCLUDE ${NETCDF_INCDIR}"
359LIB="$LIB ${NETCDF_LIBDIR}"
360
[783]361########################################################################
362# calcul du nombre de dimensions
363########################################################################
364
365
[1279]366dim_full=$dim
367dim=`echo $dim | sed -e 's/[^0-9]/ /g'` 
368set $dim
369dimc=$#
[783]370echo calcul de la dimension
371echo dim $dim
372echo dimc $dimc
373
374
375########################################################################
376# Gestion des dimensions du modele.
[1114]377# on cree ou remplace le fichier des dimensions
[783]378########################################################################
379
[1695]380cd $LIBFGCM/grid
381if [[ -f dimensions.h ]]
382then
383  echo 'ATTENTION: vous etes sans doute en train de compiler le modele par ailleurs'
384  echo "Attendez que la premiere compilation soit terminee pour relancer la suivante."
385  echo "Si vous etes sur que vous ne compilez pas le modele par ailleurs,"
386  echo  vous pouvez continuer en repondant oui.
387  echo "Voulez-vous vraiment continuer?"
[1755]388  echo ""
389  echo "WARNING: you are probably already compiling the model somewhere else."
390  echo "Wait until the first compilation is finished before launching this one."
391  echo "If you are sure that you are not compiling elsewhere, just answer "
392  echo "yes (or 'oui') to the question below to proceed."
393  echo "Do you wish to continue?"
[1695]394  read reponse
[1755]395  if [[ $reponse == "oui" || $reponse == "yes" ]]
[1695]396  then
[1696]397    \rm -f $LIBFGCM/grid/dimensions.h
[1695]398  else
399    exit
400  fi
401fi
402
403
[783]404cd $LIBFGCM/grid/dimension
[1114]405./makdim $dim
[783]406cat $LIBFGCM/grid/dimensions.h
407cd $LMDGCM
408
409
410########################################################################
411# Differentes dynamiques (3d, 2d, 1d)
412########################################################################
413
[1279]414dimension=`echo $dim | wc -w`
[783]415echo dimension $dimension
416
[1279]417if (( $dimension == 3 ))
418then
[783]419  cd $LIBFGCM/grid
420  \rm fxyprim.h
421  cp -p fxy_${grille}.h fxyprim.h
[2239]422#else
423#  echo "Probleme dans les dimensions de la dynamique !!"
424#  echo "Non reactive pour l'instant !!!"
[1279]425fi
[783]426
[2239]427if (( $dimension == 1 ))
428then
429  CPP_KEY="$CPP_KEY CPP_1D"
430##in 1D, add dyn3d to include path (because main prog is in physics)
431  INCLUDE="$INCLUDE -Ilibf/dyn3d -Ilibf/dyn3d_common"
432## no filtre in 1d:
433  FILTRE_PATH=$LMDGCM/.void_dir
434## no need to compile all routines in dyn3d_common either:
435  DYN_COMMON_PATH=$LMDGCM/.void_dir
436## no need to compile all routines in dynlmdz_phy... ;
437## (because key ones are included in 1D main program)
438  DYN_PHYS_PATH=$LMDGCM/.void_dir
439fi
440
[783]441######################################################################
442#   Traitement special pour le nouveau rayonnement de Laurent Li.
443#   ---> YM desactive pour le traitemement en parallele
444######################################################################
445
[1279]446#if [[ -f $libf/phy$physique/raddim.h ]]
447#then
448# if [[ -f $libf/phy$physique/raddim.$dimh.h ]]
449#then
[783]450#  \rm -f $libf/phy$physique/raddim.h
451#  cp -p $libf/phy$physique/raddim.$dimh.h $libf/phy$physique/raddim.h
452#  echo $libf/phy$physique/raddim.$dimh.h
453#  cat $libf/phy$physique/raddim.h
454# else
455#  echo On peut diminuer la taille de l executable en creant
456#  echo le fichier $libf/phy$physique/raddim.$dimh.h
457#  \cp -p $libf/phy$physique/raddim.defaut.h $libf/phy$physique/raddim.h
[1279]458# fi
459#fi
[783]460
461######################################################################
462# Gestion du filtre qui n'existe qu'en 3d.
463######################################################################
464
[1279]465if (( `expr $dimc \> 2` == 1 ))
466then
467   filtre="FILTRE=$filtre"
[783]468else
[1279]469   filtre="FILTRE= L_FILTRE= "
470fi
[783]471echo MACRO FILTRE $filtre
472
473echo $dimc
474
475
476
477######################################################################
478# Creation du suffixe de la configuration
479######################################################################
480
481
[1279]482SUFF_NAME=_${dim_full}
483SUFF_NAME=${SUFF_NAME}_phy${physique}
[783]484
[1279]485if [[ "$parallel" != "none" ]]
486then
487  SUFF_NAME=${SUFF_NAME}_para
[1680]488  DYN=dyn${dimc}d${paramem}
489  if [[ "$paramem" == "mem" ]]
490  then
[2202]491      SUFF_NAME=${SUFF_NAME}_${paramem}
492  else
493      echo "The version of the dynamics in dyn3dpar is no longer updated."
494      echo "You should use option \"-mem\"."
495      exit 1
[1680]496  fi
[783]497else
[1279]498  SUFF_NAME=${SUFF_NAME}_seq
[2239]499  if (( $dimension == 1 ))
500  then
501    # dynamics-related routines in"dyn1d" subdirectory of phy${physique}
502    DYN=phy${physique}/dyn1d
503  else
504    DYN=dyn${dimc}d
505  fi
[1279]506fi
[783]507
[1772]508if [[ $veget != "false" ]]
[1279]509then
510  SUFF_NAME=${SUFF_NAME}_orch
511fi
[783]512
[1279]513if [[ $couple != "false" ]]
514then
515  SUFF_NAME=${SUFF_NAME}_couple
516fi
[783]517
[1279]518if [[ $chimie == "INCA" ]]
519then
520  SUFF_NAME=${SUFF_NAME}_inca
521fi
[783]522
523cd $LMDGCM
[1279]524config_fcm="config.fcm"
[783]525rm -f $config_fcm
526touch $config_fcm
527rm -f bin/${code}${SUFF_NAME}.e
528rm -f arch.fcm
[1279]529rm -f arch.opt
[783]530
531echo "%ARCH          $arch"          >> $config_fcm
532echo "%INCDIR        $INCLUDE"       >> $config_fcm 
533echo "%LIB           $LIB"           >> $config_fcm
534echo "%ROOT_PATH     $PWD"           >> $config_fcm
535echo "%LIBF          $LIBFGCM"       >> $config_fcm
536echo "%LIBO          $LIBOGCM"       >> $config_fcm
537echo "%DYN           $DYN"           >> $config_fcm
[2239]538echo "%DYN_COMMON    $DYN_COMMON_PATH" >> $config_fcm
539echo "%FILTRE        $FILTRE_PATH"   >> $config_fcm
[783]540echo "%PHYS          phy${physique}" >> $config_fcm
[2239]541echo "%DYN_PHYS      $DYN_PHYS_PATH" >> $config_fcm
[2084]542echo "%RRTM          $RRTM_PATH"     >> $config_fcm
543echo "%SISVAT        $SISVAT_PATH"   >> $config_fcm
[1327]544echo "%COSP          $COSP_PATH"     >> $config_fcm
[783]545echo "%CPP_KEY       $CPP_KEY"       >> $config_fcm
546echo "%EXEC          $code"          >> $config_fcm
547echo "%SUFF_NAME     $SUFF_NAME"     >> $config_fcm
[1002]548echo "%COMPIL_FFLAGS $COMPIL_FFLAGS" >> $config_fcm
549echo "%PARA_FFLAGS   $PARA_FFLAGS"   >> $config_fcm
550echo "%PARA_LD       $PARA_LD"       >> $config_fcm
[1279]551echo "%EXT_SRC       $EXT_SRC"       >> $config_fcm
[783]552
[1002]553
554
[1137]555ln -s arch/arch-${arch}.fcm arch.fcm
[1279]556if test -f arch/arch-${arch}.opt &&  [ $compil_mod = "prod" ]
557  then
558  ln -s arch/arch-${arch}.opt arch.opt
559else
560  ln -s .void_file arch.opt
561fi
562
563
[1002]564rm -f $LIBOGCM/${arch}${SUFF_NAME}/.config/fcm.bld.lock
[1802]565./build_gcm ${fcm_path} -j $job $full
[783]566
[1279]567rm -rf tmp_src
568rm -rf config
[783]569ln -s $LIBOGCM/${arch}${SUFF_NAME}/.config config
570ln -s $LIBOGCM/${arch}${SUFF_NAME}/.config/tmp tmp_src
[1695]571
[1869]572
[1696]573if [[ -r $LIBFGCM/grid/dimensions.h ]]
[1695]574then
575  # Cleanup: remove dimension.h file
[1696]576  \rm -f $LIBFGCM/grid/dimensions.h
[1695]577fi
Note: See TracBrowser for help on using the repository browser.