Changeset 2238 for LMDZ5/trunk/makelmdz
- Timestamp:
- Mar 20, 2015, 11:54:59 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ5/trunk/makelmdz
r2202 r2238 84 84 PARA_LD="" 85 85 EXT_SRC="" 86 86 #src_dirs: directories containing source files 87 src_dirs="grid bibio" 87 88 ######################################################################## 88 89 # lecture des options … … 106 107 true : (obsolete; for backward compatibility) use ORCHIDEE tag 1.9-1.9.6 107 108 [-chimie INCA/false] : with INCA chemistry model or without (default: false) 109 [-cosp true/false] : compile with/without cosp package (default: false) 110 [-sisvat true/false] : compile with/without sisvat package (default: false) 111 [-rrtm true/false] : compile with/without rrtm package (default: false) 108 112 [-parallel none/mpi/omp/mpi_omp] : parallelism (default: none) : mpi, openmp or mixted mpi_openmp 109 113 [-g GRI] : grid configuration in dyn3d/GRI_xy.h (default: reg, inclues a zoom) … … 186 190 187 191 "-ext_src") 188 EXT_SRC=$2 ; s hift ; shift ;;192 EXT_SRC=$2 ; src_dirs="$src_dirs $EXT_SRC" ; shift ; shift ;; 189 193 190 194 "-arch") … … 283 287 then 284 288 #We'll use some physics 289 src_dirs="$src_dirs phy$physique" 285 290 CPP_KEY="$CPP_KEY CPP_PHYS" 286 291 if [[ "${physique:0:3}" == "lmd" ]] … … 316 321 echo "You should use option \"-mem\"." 317 322 exit 1 318 fi 323 fi 319 324 fi 320 325 … … 413 418 CPP_KEY="$CPP_KEY CPP_COSP" 414 419 COSP_PATH="$LIBFGCM/cosp" 420 src_dirs="$src_dirs cosp" 415 421 # LIB="${LIB} -l${LIBPREFIX}cosp" 416 422 opt_dep="$opt_dep cosp" … … 422 428 then 423 429 CPP_KEY="$CPP_KEY CPP_SISVAT" 430 src_dirs="$src_dirs phy${physique}/sisvat" 424 431 fi 425 432 … … 427 434 then 428 435 CPP_KEY="$CPP_KEY CPP_RRTM" 436 src_dirs="$src_dirs phy${physique}/rrtm" 429 437 fi 430 438 … … 489 497 490 498 if (( $dimc == 3 )) ; then 499 src_dirs="$src_dirs $filtre dyn3d_common dyn3d${FLAG_PARA}" 491 500 cd $LIBFGCM/grid 492 501 \rm fxyprim.h … … 498 507 INCLUDE="$INCLUDE "'-I$(LIBF)/dyn2d' 499 508 elif (( $dimc == 1 )) ; then 509 src_dirs="$src_dirs dyn3d dyn3d_common filtrez" 500 510 CPP_KEY="$CPP_KEY CPP_1D" 501 511 filtre="L_DYN= DYN= FILTRE= L_FILTRE= DIRMAIN=phy$physique " … … 539 549 cd $LMDGCM 540 550 541 find libf -name '*.[Fh]' -print > tmp77 542 find libf -name '*.[Fh]' -exec egrep -i " *use *ioipsl" {} \; -print > tmp90 543 find libf -name '*.F90' -print >> tmp90 544 545 if [[ ! ( -r makefile ) || ! ( -r liste_des_sources_f90 ) || ! ( -r liste_des_sources_f77 ) || ` diff tmp77 liste_des_sources_f77 | wc -w ` -ne 0 || ` diff tmp90 liste_des_sources_f90 | wc -w ` -ne 0 ]] 551 find libf -name '*.[Fh]' -print | sort > tmp77 552 #find libf -name '*.[Fh]' -exec egrep -i " *use *ioipsl" {} \; -print > tmp90 553 find libf -name '*.F90' -print | sort > tmp90 554 555 if [[ -r .makelmdz ]] 556 then 557 old_lmdz_configuration=$(cat .makelmdz ) 558 else 559 old_lmdz_configuration="" 560 fi 561 lmdz_configuration="$src_dirs" 562 if [[ "$lmdz_configuration" != "$old_lmdz_configuration" ]] 563 then 564 configuration_change="true" 565 else 566 configuration_change="false" 567 fi 568 569 if [[ $configuration_change == "true" || ! ( -r makefile ) || ! ( -r liste_des_sources_f90 ) || ! ( -r liste_des_sources_f77 ) || ` diff tmp77 liste_des_sources_f77 | wc -w ` -ne 0 || ` diff tmp90 liste_des_sources_f90 | wc -w ` -ne 0 ]] 546 570 then 547 571 echo "les fichiers suivants ont ete crees ou detruits" … … 551 575 \cp -f tmp77 liste_des_sources_f77 552 576 \cp -f tmp90 liste_des_sources_f90 553 echo "on recree le makefile" 554 ./create_make_gcm > tmp 577 echo "Recreating the makefile" 578 echo "src_dirs: $src_dirs" 579 ./create_make_gcm $src_dirs > tmp 555 580 \mv -f tmp makefile 556 echo "Nouveau makefile cree" 557 fi 581 echo "New makefile created" 582 fi 583 584 #Create a .makelmdz file containing main compilation option for later comparisons 585 echo "$lmdz_configuration" > .makelmdz 558 586 559 587 #################################################################
Note: See TracChangeset
for help on using the changeset viewer.