Changeset 168
- Timestamp:
- Dec 18, 2000, 5:01:05 PM (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ.3.3/trunk/create_make_gcm
r20 r168 10 10 CRAY=1 11 11 fi 12 XNEC=0 13 if [ "$machine" = "rhodes" ] ; then 14 XNEC=1 15 fi 16 VPP=0 17 if [ "$machine" = "nymphea0" ] ; then 18 VPP=1 19 fi 12 20 # 13 21 echo "#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" … … 43 51 echo '# Les differentes librairies pour l"edition des liens:' 44 52 echo 45 echo 'dyn3d = $(LIBO)/libdyn3d.a $(LIBO)/lib$(FILTRE).a' 46 echo 'dyn2d = $(LIBO)/libdyn2d.a' 47 echo 'dyn1d = $(LIBO)/libdyn1d.a' 48 echo 'L_DYN = -ldyn$(DIM)d' 49 echo 'L_FILTRE = -l$(FILTRE)' 50 echo 'L_PHY = -lphy$(PHYS) ' 51 echo 'L_BIBIO = -lbibio' 52 echo 'L_ADJNT =' 53 if [ "$XNEC" = '1' ] ; then 54 echo 'dyn3d = $(LIBO)/libsxdyn3d.a $(LIBO)/libsx$(FILTRE).a' 55 echo 'dyn2d = $(LIBO)/libsxdyn2d.a' 56 echo 'dyn1d = $(LIBO)/libsxdyn1d.a' 57 echo 'L_DYN = -lsxdyn$(DIM)d' 58 echo 'L_FILTRE = -lsx$(FILTRE)' 59 echo 'L_PHY = -lsxphy$(PHYS) ' 60 echo 'L_BIBIO = -lsxbibio' 61 echo 'L_ADJNT =' 62 else 63 echo 'dyn3d = $(LIBO)/libdyn3d.a $(LIBO)/lib$(FILTRE).a' 64 echo 'dyn2d = $(LIBO)/libdyn2d.a' 65 echo 'dyn1d = $(LIBO)/libdyn1d.a' 66 echo 'L_DYN = -ldyn$(DIM)d' 67 echo 'L_FILTRE = -l$(FILTRE)' 68 echo 'L_PHY = -lphy$(PHYS) ' 69 echo 'L_BIBIO = -lbibio' 70 echo 'L_ADJNT =' 71 fi 53 72 echo 54 73 echo "#%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%" … … 58 77 echo 'COMPILE = $(F77) $(OPTIM) $(INCLUDE) -c' 59 78 echo 'COMPILE90 = $(F90) $(OPTIM90) $(INCLUDE) -c' 60 echo 'LINK = f90' 61 echo "AR = ar" 79 echo 'COMPTRU90 = $(F90) $(OPTIMTRU90) $(INCLUDE) -c' 80 echo "LINK = $LINK" 81 echo "AR = $AR" 62 82 echo 63 83 echo … … 73 93 echo 'main : $(DYN) bibio phys $(OPTION_DEP) ' 74 94 echo ' cd $(LIBO) ; $(RANLIB) lib*.a ; cd $(GCM) ;\' 75 if [ "$CRAY" = '0' ] ; then76 95 echo ' cd $(LOCAL_DIR); \' 77 #echo ' $(COMPILE90) $(LIBF)/$(DIRMAIN)/$(PROG).F -o $(PROG).o ; \' 78 echo ' $(COMPILE) $(LIBF)/$(DIRMAIN)/$(PROG).F -o $(PROG).o ; \'79 else 80 echo ' $(COMPILE90) $(LIBF)/$(DIRMAIN)/$(PROG).F; \'96 if [ "$CRAY" = '1' -o "$VPP" = '1' ] ; then 97 echo ' $(COMPILE90) $(LIBF)/$(DIRMAIN)/$(PROG).F -o $(PROG).o ; \' 98 else 99 echo ' $(COMPILE) $(LIBF)/$(DIRMAIN)/$(PROG).F -o $(PROG).o ; \' 81 100 fi 82 101 if [ "$CRAY" = '0' ] ; then … … 109 128 do 110 129 if [ -d $diri ] ; then 111 if [ "`ls $diri/*.F`" != "" ] ; then130 if [ "`ls $diri/*.F`" != "" ] || [ "`ls $diri/*.F90`" != "" ] ; then 112 131 cd $diri >/dev/null 2>&1 113 132 echo … … 121 140 fi 122 141 done 142 for i in `ls *.F90` 143 do 144 fili=`basename $i .F90` 145 test=` ( head $i | grep ' PROGRAM' ) ` 146 if [ "$test" = "" ] ; then 147 listlib=$listlib" "$fili 148 fi 149 done 123 150 # 124 151 echo … … 140 167 for fili in $listlib 141 168 do 142 F90=0 ; egrep -i '^ *use ' $fili.F > /dev/null 2>&1 && F90=1 143 egrep -i '^ *module ' $fili.F > /dev/null 2>&1 && F90=1 144 str1='$(LIBO)/lib'$diri'.a('$fili'.o) : $(LIBF)/'$diri/$fili.F 169 if [ -f $fili.F90 ] ; then 170 trufile=$fili.F90 171 else 172 trufile=$fili.F 173 fi 174 F90=0 ; egrep -i '^ *use ' $trufile > /dev/null 2>&1 && F90=1 175 egrep -i '^ *module ' $trufile > /dev/null 2>&1 && F90=1 176 str1='$(LIBO)/lib'$diri'.a('$fili'.o) : $(LIBF)/'$diri/$trufile 145 177 [ "$fili" = "chem.subs" ] && str1=$str1' $(LIBF)/'$diri/chem.mods.F 146 for stri in ` ( sed -n "/\#include/s/\#include//p" $ fili.F | sed 's/\"//g' ; egrep -i '^ *use ' $fili.F| awk ' { print $2 } ' ) `178 for stri in ` ( sed -n "/\#include/s/\#include//p" $trufile | sed 's/\"//g' ; egrep -i '^ *use ' $trufile | awk ' { print $2 } ' ) ` 147 179 do 148 180 stri=`echo $stri | tr [A-Z] [a-z]` … … 151 183 str1='$(LIBF)/'$diri'/'$stri 152 184 else 153 if [ -f $stri.F ] ; then185 if [ -f $stri.F ] || [ -f $stri.F90 ] ; then 154 186 str1='$(LIBO)/lib'$diri'.a('$stri'.o)' 155 187 else … … 166 198 echo $str1 167 199 if [ "$F90" -eq '0' ] ; then 168 169 echo ' $(COMPILE) $(LIBF)/'$diri'/'$fili'.F; \'200 echo ' cd $(LOCAL_DIR); \' 201 echo ' $(COMPILE) $(LIBF)/'$diri'/'$trufile' ; \' 170 202 else 171 echo ' cd $(LOCAL_DIR); \' 172 echo ' $(COMPILE90) $(LIBF)/'$diri'/'$fili'.F ; \' 173 MODU=0; egrep -i ' *module ' $fili.F> /dev/null 2>&1 && MODU=1 203 echo ' cd $(LOCAL_DIR); \' 204 if [ -f $fili.F90 ] ; then 205 echo ' $(COMPTRU90) $(LIBF)/'$diri'/'$trufile' ; \' 206 else 207 echo ' $(COMPILE90) $(LIBF)/'$diri'/'$trufile' ; \' 208 fi 209 MODU=0; egrep -i ' *module ' $trufile> /dev/null 2>&1 && MODU=1 174 210 if [ "$MODU" -eq '1' -a "$CRAY" != '1' ] ; then 175 211 if [ "$os" -eq 'UNIX_System_V' -o "$os" -eq 'SUPER-UX' ] ; then … … 180 216 fi 181 217 fi 218 if [ "$XNEC" -eq '1' ] ; then 219 echo ' sxar r $(LIBO)/libsx'$diri'.a '$fili'.o ; \' 220 fi 182 221 echo ' $(AR) r $(LIBO)/lib'$diri'.a '$fili'.o ; $(RM) '$fili'.o ; \' 183 222 echo ' cd $(GCM)'
Note: See TracChangeset
for help on using the changeset viewer.