Changeset 1403 for trunk/LMDZ.MARS/makegcm_pgf
- Timestamp:
- Mar 31, 2015, 3:49:07 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.MARS/makegcm_pgf
r1246 r1403 8 8 set physique=mars 9 9 set phys="PHYS=$physique" 10 set include='-I$(LIBF)/grid -I$(LIBF)/ bibio -I. -I$(LIBF)/aeronomars'10 set include='-I$(LIBF)/grid -I$(LIBF)/misc -I. -I$(LIBF)/dynlonlat_phylonlat' 11 11 set ntrac = 1 12 12 set filtre=filtrez … … 14 14 set dyntype="dyn" 15 15 set full="" 16 #src_dirs: directories containing source files 17 set src_dirs="grid misc" 18 16 19 ######################################################################## 17 20 # path a changer contenant les sources et les objets du modele … … 27 30 ## NetCDF Libraries: what follows is OK for LMD 32 and 64bit Linux Machines 28 31 #if ( `uname -m` == "x86_64" ) then 29 # #64 bit machines32 # 64 bit machines 30 33 setenv NCDFLIB /donnees/emlmd/netcdf64-4.0.1_pgi/lib 31 34 setenv NCDFINC /donnees/emlmd/netcdf64-4.0.1_pgi/include … … 35 38 #endif 36 39 #### 37 38 40 39 41 setenv localdir "`pwd`" … … 221 223 endif 222 224 223 set nomlib=$machine 225 # Ehouarn: add 'g9fortran' string to pathname 226 set nomlib=${machine} 224 227 225 228 # Impose distinct name for 64 bit Linux machines (to avoid mixing 32 and 64) 226 229 if (`uname` == Linux && `uname -m` == "x86_64") then 227 set nomlib=${machine} 64230 set nomlib=${machine} 228 231 endif 229 232 … … 407 410 if ( "$physique" == 'nophys' ) then 408 411 set phys="L_PHY= LIBPHY=" 409 endif 410 412 else 413 set src_dirs="$src_dirs aerono$physique phy$physique" 414 set include="$include "'-I$(LIBF)/aerono'"$physique"' -I$(LIBF)/phy'"$physique" 415 endif 416 set libdyn_phy="" 417 set LIBDYN_PHYS="" 411 418 ######################################################################## 412 419 # choix du nombre de traceur par defaut si il n'a pas ete choisi, … … 490 497 set include="$include "'-I$(LIBF)/dyn2d ' 491 498 set dimh=$dim 492 else 499 endif 500 if ( "$dimc" == "3" ) then 493 501 if ( "$dyntype" == "olddyn" ) then 494 502 set include="$include "'-I$(LIBF)/olddyn3d ' 503 set src_dirs="$src_dirs olddyn3d dynlonlat_phylonlat dynlonlat_phylonlat/phy$physique" 495 504 else 496 505 set include="$include "'-I$(LIBF)/dyn3d ' 506 set src_dirs="$src_dirs dyn3d dynlonlat_phylonlat dynlonlat_phylonlat/phy$physique" 497 507 endif 508 set libdyn_phy="-ldynlonlat_phylonlat" 509 set LIBDYN_PHYS='$(LIBO)/libdynlonlat_phylonlat.a' 498 510 set dimh=`echo $dim | awk ' { print $1 "." $2 } '` 499 511 endif … … 554 566 ## NB: we still need to have L_DYN=libdyn3d to reach routines and module 555 567 ## objects which are located in dyn3d 556 set dyn="L_DYN=-ldyn3d DYN= L_FILTRE= DIRMAIN=phy$physique " 568 set dyntype="" 569 set filtre="L_DYN= DYN= FILTRE= L_FILTRE= " 570 set dyn="L_DYN= DYN= L_FILTRE= " 571 set dirmain="phy$physique/dyn1d" 572 set src_dirs="$src_dirs phy$physique/dyn1d " 573 set include="$include "' -I$(LIBF)/phy'"$physique"'/dyn1d' 557 574 endif 558 575 endif … … 594 611 if ( `expr $dimc \> 2` == 1 ) then 595 612 set filtre="FILTRE=$filtre" 613 if ( "$dyntype" == "olddyn" ) then 614 set src_dirs="$src_dirs oldfiltrez" 615 else 616 set src_dirs="$src_dirs filtrez" 617 endif 596 618 else 597 set filtre="FILTRE= L_FILTRE= "619 set filtre="FILTRE= L_FILTRE= L_DYN= " 598 620 endif 599 621 echo "MACRO FILTRE $filtre" … … 637 659 \cp tmp90 liste_des_sources_f90 638 660 echo "On recree le makefile" 639 if ("$dyntype" == "olddyn") then 640 ./create_make_gcm olddyn3d grid bibio aeronomars phy$physique >! tmp 641 else 642 ./create_make_gcm dyn3d grid bibio aeronomars phy$physique >! tmp 643 endif 661 echo "src_dirs: $src_dirs" 662 create_make_gcm $src_dirs >! tmp 644 663 \mv tmp makefile 645 664 echo "Nouveau makefile cree." … … 739 758 cd $localdir 740 759 741 ## locate main program (could be in dyn3d or phy$physique742 ## 760 ## locate main program (could be in dyn3d or dynlonlat_phylonlat/phy$physique 761 ## or phy$physique/dyn1d and could be .F or .F90) 743 762 set source_code=${code}.F 763 set dirmain=dyn${dimc}d 744 764 if ( -f $LMDGCM/libf/dyn3d/${code}.F90 ) then 745 765 set source_code=${code}.F90 746 766 endif 747 if ( -f $LMDGCM/libf/phy${physique}/${code}.F ) then 767 if ( -f $LMDGCM/libf/phy${physique}/dyn1d/${code}.F ) then 768 set dirmain=phy${physique}/dyn1d 748 769 set source_code=${code}.F 749 770 endif 750 if ( -f $LMDGCM/libf/phy${physique}/${code}.F90 ) then 771 if ( -f $LMDGCM/libf/phy${physique}/dyn1d/${code}.F90 ) then 772 set dirmain=phy${physique}/dyn1d 751 773 set source_code=${code}.F90 752 774 endif 753 754 ## locate directory where main program is located 755 if ( $dimension == 3 ) then 756 if ( -f $LMDGCM/libf/dyn3d/${source_code} ) then 757 set dyn="DIRMAIN=dyn3d " 758 endif 759 if ( -f $LMDGCM/libf/phy${physique}/${source_code} ) then 760 set dyn="DIRMAIN=phy${physique} " 761 endif 775 if ( -f $LMDGCM/libf/dynlonlat_phylonlat/phy${physique}/${code}.F ) then 776 set dirmain=dynlonlat_phylonlat/phy${physique} 777 set source_code=${code}.F 778 endif 779 if ( -f $LMDGCM/libf/dynlonlat_phylonlat/phy${physique}/${code}.F90 ) then 780 set dirmain=dynlonlat_phylonlat/phy${physique} 781 set source_code=${code}.F90 762 782 endif 763 783 … … 770 790 $filtre \ 771 791 LIBO=$libo \ 772 $dyn \773 792 $phys \ 793 LIBDYN_PHYS=${LIBDYN_PHYS} \ 774 794 DIM=$dimc \ 775 795 DYNTYPE="$dyntype" \ 796 L_DYN_PHY="$libdyn_phy" \ 776 797 L_ADJNT="$adjnt" \ 777 798 LOCAL_DIR="$localdir" \ … … 784 805 MOD_SUFFIX=$mod_suffix \ 785 806 AR=$ar \ 807 DIRMAIN=$dirmain \ 786 808 SOURCE=$source_code \ 787 809 PROG=$code … … 796 818 $filtre \ 797 819 LIBO=$libo \ 798 $dyn \799 820 $phys \ 821 LIBDYN_PHYS=${LIBDYN_PHYS} \ 800 822 DIM=$dimc \ 801 823 DYNTYPE="$dyntype" \ 824 L_DYN_PHY="$libdyn_phy" \ 802 825 L_ADJNT="$adjnt" \ 803 826 LOCAL_DIR="$localdir" \ … … 810 833 MOD_SUFFIX=$mod_suffix \ 811 834 AR=$ar \ 835 DIRMAIN=$dirmain \ 812 836 SOURCE=$source_code \ 813 837 PROG=$code 814 838 815 # cleanup, remove dimensions.h 839 # cleanup, remove dimensions.h 816 840 \rm -f $libf/grid/dimensions.h
Note: See TracChangeset
for help on using the changeset viewer.