<p><b>dwj07@fsu.edu</b> 2012-09-12 21:38:14 -0600 (Wed, 12 Sep 2012)</p><p><br>
        -- BRANCH COMMIT --<br>
<br>
        More fixes for CESM coupling.<br>
</p><hr noshade><pre><font color="gray">Modified: branches/ocean_projects/cesm_coupling/src/Makefile
===================================================================
--- branches/ocean_projects/cesm_coupling/src/Makefile        2012-09-12 20:52:57 UTC (rev 2159)
+++ branches/ocean_projects/cesm_coupling/src/Makefile        2012-09-13 03:38:14 UTC (rev 2160)
@@ -17,8 +17,6 @@
 include $(CASEROOT)/Macros
 
 all:
-        @echo $(CPPINCLUDES)
-        @echo $(FCINCLUDES)
         ( $(MAKE) mpas RM=&quot;$(RM)&quot; CPP=&quot;$(CPP)&quot; NETCDF=&quot;$(NETCDF)&quot; PNETCDF=&quot;$(PNETCDF)&quot; \
           PIO=&quot;$(PIO)&quot; FC=&quot;$(FC)&quot; CC=&quot;$(CC)&quot; SFC=&quot;$(SFC)&quot; SCC=&quot;$(SCC)&quot; \
           CPPFLAGS=&quot;$(CPPFLAGS)&quot; CPPINCLUDES=&quot;$(CPPINCLUDES)&quot; FCINCLUDES=&quot;$(FCINCLUDES)&quot; )
@@ -43,26 +41,27 @@
         ( cd inc; $(CPP) ../core_$(CORE)/Registry | ../registry/parse &gt; Registry.processed)
 
 externals: reg_includes
-        ( cd external; $(MAKE) FC=&quot;$(FC)&quot; SFC=&quot;$(SFC)&quot; CC=&quot;$(CC)&quot; SCC=&quot;$(SCC)&quot; FFLAGS=&quot;$(FFLAGS)&quot; CFLAGS=&quot;$(CFLAGS)&quot; CPP=&quot;$(CPP)&quot; NETCDF=&quot;$(NETCDF)&quot; CORE=&quot;$(CORE)&quot; )
+        ( cd external; $(MAKE) )
+        #( cd external; $(MAKE) FC=&quot;$(FC)&quot; SFC=&quot;$(SFC)&quot; CC=&quot;$(CC)&quot; SCC=&quot;$(SCC)&quot; FFLAGS=&quot;$(FFLAGS)&quot; CFLAGS=&quot;$(CFLAGS)&quot; CPP=&quot;$(CPP)&quot; NETCDF=&quot;$(NETCDF)&quot; CORE=&quot;$(CORE)&quot; )
 
 frame: reg_includes externals
-        ( cd framework; $(MAKE) CPPFLAGS=&quot;$(CPPFLAGS)&quot; CPPINCLUDES=&quot;$(CPPINCLUDES)&quot; all ) 
+        ( cd framework; $(MAKE) all ) 
         ln -sf framework/libframework.a libframework.a
 
 ops: reg_includes externals frame
-        ( cd operators; $(MAKE) CPPFLAGS=&quot;$(CPPFLAGS)&quot; CPPINCLUDES=&quot;$(CPPINCLUDES)&quot; all ) 
+        ( cd operators; $(MAKE) all ) 
         ln -sf operators/libops.a libops.a
 
 dycore: reg_includes externals frame ops
-        ( cd core_$(CORE); $(MAKE) CPPFLAGS=&quot;$(CPPFLAGS)&quot; CPPINCLUDES=&quot;$(CPPINCLUDES)&quot; all ) 
+        ( cd core_$(CORE); $(MAKE) all ) 
         ln -sf core_$(CORE)/libdycore.a libdycore.a
 
 ifeq &quot;$(CESM)&quot; &quot;true&quot;
 drver:  reg_includes externals frame ops dycore
-        ( cd $(CORE)_cesm_driver; $(MAKE) CPPFLAGS=&quot;$(CPPFLAGS)&quot; CPPINCLUDES=&quot;$(CPPINCLUDES)&quot; all ) 
+        ( cd $(CORE)_cesm_driver; $(MAKE) all ) 
 else
 drver:  reg_includes externals frame ops dycore
-        ( cd driver; $(MAKE) CPPFLAGS=&quot;$(CPPFLAGS)&quot; CPPINCLUDES=&quot;$(CPPINCLUDES)&quot; all ) 
+        ( cd driver; $(MAKE) all ) 
 endif
 
 clean:
@@ -73,6 +72,9 @@
         ( cd operators; $(MAKE) clean )
         ( cd inc; rm -f *.inc Registry.processed )
         if [ -d core_$(CORE) ] ; then \
-           ( cd core_$(CORE); $(MAKE) clean ) \
+                ( cd core_$(CORE); $(MAKE) clean ) \
         fi;
+        if [ -d $(CORE)_cesm_driver ] ; then \
+                ( cd $(CORE)_cesm_driver; $(MAKE) clean ) \
+        fi;
         ( cd driver; $(MAKE) clean )

Modified: branches/ocean_projects/cesm_coupling/src/core_ocean/mpas_ocn_global_diagnostics.F
===================================================================
--- branches/ocean_projects/cesm_coupling/src/core_ocean/mpas_ocn_global_diagnostics.F        2012-09-12 20:52:57 UTC (rev 2159)
+++ branches/ocean_projects/cesm_coupling/src/core_ocean/mpas_ocn_global_diagnostics.F        2012-09-13 03:38:14 UTC (rev 2160)
@@ -421,27 +421,27 @@
       ! write out the data to files
       if (dminfo % my_proc_id == IO_NODE) then
          fileID = getFreeUnit()
-         open(fileID,file='stats_min.txt',STATUS='UNKNOWN', ACCESS='stream')
+         open(fileID,file='stats_min.txt',STATUS='UNKNOWN', POSITION='append')
             write (fileID,'(100es24.14)') mins(1:nVariables)
          close (fileID)
-         open(fileID,file='stats_max.txt',STATUS='UNKNOWN', ACCESS='stream')
+         open(fileID,file='stats_max.txt',STATUS='UNKNOWN', POSITION='append')
             write (fileID,'(100es24.14)') maxes(1:nVariables)
          close (fileID)
-         open(fileID,file='stats_sum.txt',STATUS='UNKNOWN', ACCESS='stream')
+         open(fileID,file='stats_sum.txt',STATUS='UNKNOWN', POSITION='append')
             write (fileID,'(100es24.14)') sums(1:nVariables)
          close (fileID)
-         open(fileID,file='stats_avg.txt',STATUS='UNKNOWN', ACCESS='stream')
+         open(fileID,file='stats_avg.txt',STATUS='UNKNOWN', POSITION='append')
             write (fileID,'(100es24.14)') averages(1:nVariables)
          close (fileID)
-         open(fileID,file='stats_time.txt',STATUS='UNKNOWN', ACCESS='stream')
+         open(fileID,file='stats_time.txt',STATUS='UNKNOWN', POSITION='append')
             write (fileID,'(i10,10x,a,100es24.14)') timeIndex, &amp;
                state % xtime % scalar, dt, &amp;
                CFLNumberGlobal
          close (fileID)
-         open(fileID,file='stats_colmin.txt',STATUS='UNKNOWN', ACCESS='stream')
+         open(fileID,file='stats_colmin.txt',STATUS='UNKNOWN', POSITION='append')
             write (fileID,'(100es24.14)') verticalSumMins(1:nVariables)
          close (fileID)
-         open(fileID,file='stats_colmax.txt',STATUS='UNKNOWN', ACCESS='stream')
+         open(fileID,file='stats_colmax.txt',STATUS='UNKNOWN', POSITION='append')
             write (fileID,'(100es24.14)') verticalSumMaxes(1:nVariables)
          close (fileID)
       end if

Modified: branches/ocean_projects/cesm_coupling/src/framework/mpas_configure.F
===================================================================
--- branches/ocean_projects/cesm_coupling/src/framework/mpas_configure.F        2012-09-12 20:52:57 UTC (rev 2159)
+++ branches/ocean_projects/cesm_coupling/src/framework/mpas_configure.F        2012-09-13 03:38:14 UTC (rev 2160)
@@ -32,8 +32,8 @@
 #include &quot;config_set_defaults.inc&quot;
 
       if (dminfo % my_proc_id == IO_NODE) then
-         write(0,*) 'Reading namelist.input'
-         open(funit,file=filename,status='old',form='formatted')
+         write(0,*) 'Reading ', trim(filename)
+         open(funit,file=trim(filename),status='old',form='formatted')
 
 #include &quot;config_namelist_reads.inc&quot;
          close(funit)

Modified: branches/ocean_projects/cesm_coupling/src/ocean_cesm_driver/ocn_comp_mct.F
===================================================================
--- branches/ocean_projects/cesm_coupling/src/ocean_cesm_driver/ocn_comp_mct.F        2012-09-12 20:52:57 UTC (rev 2159)
+++ branches/ocean_projects/cesm_coupling/src/ocean_cesm_driver/ocn_comp_mct.F        2012-09-13 03:38:14 UTC (rev 2160)
@@ -127,6 +127,7 @@
     integer :: iam,ierr 
     character(len=StrKIND)  :: starttype          ! infodata start type
     character(len=StrKIND)  :: timeStamp
+    character(len=StrKIND)  :: nml_filename
 
     integer :: lbnum
 
@@ -200,7 +201,8 @@
 !  inst_suffix = seq_comm_suffix(OCNID)
 
    call t_startf('mpas-o_init')
-   call mpas_framework_init(dminfo, domain, mpi_communicator_ocn)
+   nml_filename = &quot;mpaso.in&quot;
+   call mpas_framework_init(dminfo, domain, mpi_communicator_ocn, nml_filename)
 
    call mpas_input_state_for_domain(domain)
 

</font>
</pre>