<p><b>duda</b> 2009-12-23 11:34:55 -0700 (Wed, 23 Dec 2009)</p><p>BRANCH COMMIT: branches/hyd_model<br>
<br>
Update top-level Makefile to use separate make targets<br>
for different platforms.<br>
<br>
Now, compilation is accomplished by typing 'make target',<br>
where target is, e.g., xlf.<br>
<br>
M    Makefile<br>
</p><hr noshade><pre><font color="gray">Modified: branches/hyd_model/Makefile
===================================================================
--- branches/hyd_model/Makefile        2009-12-23 17:16:33 UTC (rev 96)
+++ branches/hyd_model/Makefile        2009-12-23 18:34:55 UTC (rev 97)
@@ -2,62 +2,62 @@
 MODEL_FORMULATION = -DLANL_FORMULATION
 
 EXPAND_LEVELS = -DEXPAND_LEVELS=26
+#FILE_OFFSET = -DOFFSET64BIT
 
-# IBM with Xlf compilers
-#FC = mpxlf90
-#CC = mpcc
-#SFC = xlf90
-#SCC = xlc
-#FFLAGS = -qrealsize=8 -g -C 
-#CFLAGS = -g
-#LDFLAGS = -g -C
+dummy:
+        @( echo &quot;try one of:&quot;; \
+        echo &quot;   make xlf&quot;; \
+        echo &quot;   make pgi&quot;; \
+        echo &quot;   make ifort&quot;; \
+        echo &quot;   make gfortran&quot;; \
+        )
+
+xlf:
+        ( make all \
+        &quot;FC = mpxlf90&quot; \
+        &quot;CC = mpcc&quot; \
+        &quot;SFC = xlf90&quot; \
+        &quot;SCC = xlc&quot; \
+        &quot;FFLAGS = -qrealsize=8 -g -C &quot; \
+        &quot;CFLAGS = -g&quot; \
+        &quot;LDFLAGS = -g -C&quot; \
+        &quot;CPPFLAGS = -DRKIND=8 $(MODEL_FORMULATION) $(EXPAND_LEVELS) -D_MPI $(FILE_OFFSET)&quot; )
  
-#FC = mpif90
-#CC = mpicc
-#SFC = pgf90
-#SCC = pgcc
-#FFLAGS = -r8 -O3
-#CFLAGS = -O3
-#LDFLAGS = -O3
+pgi:
+        ( make all \
+        &quot;FC = mpif90&quot; \
+        &quot;CC = mpicc&quot; \
+        &quot;SFC = pgf90&quot; \
+        &quot;SCC = pgcc&quot; \
+        &quot;FFLAGS = -r8 -O3&quot; \
+        &quot;CFLAGS = -O3&quot; \
+        &quot;LDFLAGS = -O3&quot; \
+        &quot;CPPFLAGS = -DRKIND=8 $(MODEL_FORMULATION) $(EXPAND_LEVELS) -D_MPI -DUNDERSCORE $(FILE_OFFSET)&quot; )
 
-#FC = pgf95
-#CC = pgcc
-#SFC = pgf95
-#SCC = pgcc
-#FFLAGS = -r8 -O3
-#CFLAGS = -O3
-#LDFLAGS = -O3
+ifort:
+        ( make all \
+        &quot;FC = mpif90&quot; \
+        &quot;CC = gcc&quot; \
+        &quot;SFC = ifort&quot; \
+        &quot;SCC = gcc&quot; \
+        &quot;FFLAGS = -real-size 64 -O3&quot; \
+        &quot;CFLAGS = -O3 -m64&quot; \
+        &quot;LDFLAGS = -O3&quot; \
+        &quot;CPPFLAGS = -DRKIND=8 $(MODEL_FORMULATION) $(EXPAND_LEVELS) -D_MPI -DUNDERSCORE -m64 $(FILE_OFFSET)&quot; )
 
-#FC = pgf90
-#CC = pgcc
-#SFC = pgf90
-#SCC = pgcc
-#FFLAGS = -r8 -O0 -g -Mbounds -Mchkptr -Ktrap=divz,inv,fp
-#CFLAGS = -O0 -g
-#LDFLAGS = -O0 -g -Mbounds -Mchkptr -Ktrap=divz,inv,fp
-#CPPFLAGS = -DRKIND=8 $(MODEL_FORMULATION) $(EXPAND_LEVELS) -DUNDERSCORE
+gfortran:
+        ( make all \
+        &quot;FC = mpif90&quot; \
+        &quot;CC = mpicc&quot; \
+        &quot;SFC = gfortran&quot; \
+        &quot;SCC = gcc&quot; \
+        &quot;FFLAGS = -O3 -m64 -ffree-line-length-none&quot; \
+        &quot;CFLAGS = -O3 -m64&quot; \
+        &quot;LDFLAGS = -O3 -m64&quot; \
+        &quot;CPPFLAGS = -DRKIND=8 $(MODEL_FORMULATION) $(EXPAND_LEVELS) -D_MPI -DUNDERSCORE -m64 $(FILE_OFFSET)&quot; )
 
-FC = mpif90
-CC = mpicc
-SFC = pgf90
-SCC = pgcc
-FFLAGS = -r8 -O0 -g -Mbounds -Mchkptr
-CFLAGS =  -O0 -g
-LDFLAGS =  -O0 -g -Mbounds -Mchkptr
-CPPFLAGS = -DRKIND=8 $(MODEL_FORMULATION) $(EXPAND_LEVELS) -DUNDERSCORE -D_MPI # -DOFFSET64BIT 
 
-#ifort (for Intel Macs and Quad-Core AMD Opteron Clusters)
-#FC = mpif90
-#CC = mpicc
-#SFC = ifort
-#SCC = icc
-#FFLAGS = -real-size 64 -O3
-#CFLAGS = -O3
-#LDFLAGS = -O3
 
-#CPPFLAGS = -DRKIND=8 $(MODEL_FORMULATION) $(EXPAND_LEVELS) -D_MPI -DUNDERSCORE # -DOFFSET64BIT
-#CPPFLAGS = -DRKIND=8 $(MODEL_FORMULATION) $(EXPAND_LEVELS) -DUNDERSCORE # -DOFFSET64BIT
-
 CPPINCLUDES = -I../inc -I$(NETCDF)/include
 FCINCLUDES = -I../inc -I$(NETCDF)/include
 LIBS = -L$(NETCDF)/lib -lnetcdf

</font>
</pre>