Changeset 1403 for trunk/LMDZ.GENERIC/makegcm_gfortran
- Timestamp:
- Mar 31, 2015, 3:49:07 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.GENERIC/makegcm_gfortran
r1255 r1403 8 8 set physique=std 9 9 set phys="PHYS=$physique" 10 set include='-I$(LIBF)/grid -I$(LIBF)/ bibio -I.'10 set include='-I$(LIBF)/grid -I$(LIBF)/misc -I. -I$(LIBF)/dynlonlat_phylonlat' 11 11 set ntrac = 1 12 12 set filtre=filtrez … … 16 16 set scatterers="1" 17 17 set full="" 18 #src_dirs: directories containing source files 19 set src_dirs="grid misc" 20 18 21 ######################################################################## 19 22 # path a changer contenant les sources et les objets du modele … … 405 408 if ( "$physique" == 'nophys' ) then 406 409 set phys="L_PHY= LIBPHY=" 407 endif 408 410 else 411 set src_dirs="$src_dirs phy$physique" 412 set include="$include "' -I$(LIBF)/phy'"$physique" 413 endif 414 set libdyn_phy="" 415 set LIBDYN_PHYS="" 409 416 ######################################################################## 410 417 #subtilites sur le nom de la librairie … … 484 491 set include="$include "'-I$(LIBF)/dyn2d ' 485 492 set dimh=$dim 486 else 493 endif 494 if ( "$dimc" == "3" ) then 487 495 if ( "$dyntype" == "olddyn" ) then 488 496 set include="$include "'-I$(LIBF)/olddyn3d ' 497 set src_dirs="$src_dirs olddyn3d dynlonlat_phylonlat dynlonlat_phylonlat/phy$physique" 489 498 else 490 499 set include="$include "'-I$(LIBF)/dyn3d ' 500 set src_dirs="$src_dirs dyn3d dynlonlat_phylonlat dynlonlat_phylonlat/phy$physique" 491 501 endif 502 set libdyn_phy="-ldynlonlat_phylonlat" 503 set LIBDYN_PHYS='$(LIBO)/libdynlonlat_phylonlat.a' 492 504 set dimh=`echo $dim | awk ' { print $1 "." $2 } '` 493 505 endif … … 562 574 ## NB: we still need to have L_DYN=libdyn3d to reach routines and module 563 575 ## objects which are located in dyn3d 564 set dyn="L_DYN=-ldyn3d DYN= L_FILTRE= DIRMAIN=phy$physique " 576 set dyntype="" 577 set filtre="L_DYN= DYN= FILTRE= L_FILTRE= " 578 set dyn="L_DYN= DYN= L_FILTRE= " 579 set dirmain="phy$physique/dyn1d" 580 set src_dirs="$src_dirs phy$physique/dyn1d " 581 set include="$include "' -I$(LIBF)/phy'"$physique"'/dyn1d' 565 582 endif 566 583 endif … … 584 601 if ( `expr $dimc \> 2` == 1 ) then 585 602 set filtre="FILTRE=$filtre" 603 if ( "$dyntype" == "olddyn" ) then 604 set src_dirs="$src_dirs oldfiltrez" 605 else 606 set src_dirs="$src_dirs filtrez" 607 endif 586 608 else 587 set filtre="FILTRE= L_FILTRE= "609 set filtre="FILTRE= L_FILTRE= L_DYN= " 588 610 endif 589 611 echo "MACRO FILTRE $filtre" … … 627 649 \cp tmp90 liste_des_sources_f90 628 650 echo "Remaking the makefile!" 629 if ("$dyntype" == "olddyn") then 630 ./create_make_gcm olddyn3d grid bibio phy$physique >! tmp 631 else 632 ./create_make_gcm dyn3d grid bibio phy$physique >! tmp 633 endif 651 echo "src_dirs: $src_dirs" 652 create_make_gcm $src_dirs >! tmp 634 653 \mv tmp makefile 635 654 echo "New makefile created." … … 744 763 set source_code=${code}.F 745 764 # handle cases when the main program is in the physics directory 746 if (-f $LMDGCM/libf/phy${physique}/${code}.F) then 747 set dyn="$dyn DIRMAIN=phy$physique " 748 endif 749 if (-f $LMDGCM/libf/phy${physique}/${code}.F90) then 765 set dirmain=dyn${dimc}d 766 if ( -f $LMDGCM/libf/dyn3d/${code}.F90 ) then 750 767 set source_code=${code}.F90 751 set dyn="$dyn DIRMAIN=phy$physique " 768 endif 769 if ( -f $LMDGCM/libf/phy${physique}/dyn1d/${code}.F ) then 770 set dirmain=phy${physique}/dyn1d 771 set source_code=${code}.F 772 endif 773 if ( -f $LMDGCM/libf/phy${physique}/dyn1d/${code}.F90 ) then 774 set dirmain=phy${physique}/dyn1d 775 set source_code=${code}.F90 776 endif 777 if ( -f $LMDGCM/libf/dynlonlat_phylonlat/phy${physique}/${code}.F ) then 778 set dirmain=dynlonlat_phylonlat/phy${physique} 779 set source_code=${code}.F 780 endif 781 if ( -f $LMDGCM/libf/dynlonlat_phylonlat/phy${physique}/${code}.F90 ) then 782 set dirmain=dynlonlat_phylonlat/phy${physique} 783 set source_code=${code}.F90 752 784 endif 753 785 … … 760 792 $filtre \ 761 793 LIBO=$libo \ 762 $dyn \763 794 $phys \ 795 LIBDYN_PHYS=${LIBDYN_PHYS} \ 764 796 DIM=$dimc \ 765 797 DYNTYPE="$dyntype" \ 798 L_DYN_PHY="$libdyn_phy" \ 766 799 L_ADJNT="$adjnt" \ 767 800 LOCAL_DIR="$localdir" \ … … 774 807 MOD_SUFFIX=$mod_suffix \ 775 808 AR=$ar \ 809 DIRMAIN=$dirmain \ 776 810 SOURCE=$source_code \ 777 811 PROG=$code … … 786 820 $filtre \ 787 821 LIBO=$libo \ 788 $dyn \789 822 $phys \ 823 LIBDYN_PHYS=${LIBDYN_PHYS} \ 790 824 DIM=$dimc \ 791 825 DYNTYPE="$dyntype" \ 826 L_DYN_PHY="$libdyn_phy" \ 792 827 L_ADJNT="$adjnt" \ 793 828 LOCAL_DIR="$localdir" \ … … 800 835 MOD_SUFFIX=$mod_suffix \ 801 836 AR=$ar \ 837 DIRMAIN=$dirmain \ 802 838 SOURCE=$source_code \ 803 839 PROG=$code
Note: See TracChangeset
for help on using the changeset viewer.