Difference between revisions of "makefile"

From WikiROMS
Jump to navigationJump to search
Line 1: Line 1:
==User Changes to the Makefile==
ROMS has a single '''makefile''' located in the top-level directory. Its generic structure facilitates the compiling of ROMS with other coupled models. The user usually needs to check/modify few definitions in the '''makefile''' before compiling a particular applications to specify primarily Fortran compiler, parallel options, and 64-bit floating-point number precision.


The ROMS Makefile is in the file '''makefile''' in the top-level directory. As a user, you need to check and perhaps edit this to set the values of '''LARGE''', '''MPI''', '''OPENMP''', '''DEBUG''', and '''FORTRAN'''. See [[Gmake#Top_Level_Makefile]] and [[Gmake#Conditionals]] for more details.
==User Changes to '''makefile'''==
 
As a user, you need to check and perhaps edit the '''makefile''' to set the values of the following definitions:
 
:'''DEBUG :='''
:'''MPI :='''
:'''MPIF90 :='''
:'''OPENMP :='''
:'''ARPACK :='''
:'''LARGE :='''
:'''FORT ?='''
 
See [[Gmake#Top_Level_Makefile]] and [[Gmake#Conditionals]] for more details.


==Compiler-dependent Changes==
==Compiler-dependent Changes==


Also as a user, you need to be aware of the files in the '''Compilers''' directory. The top-level '''makefile''' will be including one of these files, based on combining the result of '''uname -s''' with the value of '''FORTRAN'''. For instance, it might be including '''Darwin-gfortran.mk''' if you are on a Mac and using the '''gfortran''' compiler. You need to make sure this file exists and has the correct values for the compiler options and for finding the [http://www.unidata.ucar.edu/software/netcdf/ NetCDF] library. The file should contain pointers to both the '''NetCDF library''' and '''include''' files. If the library is different for '''32-bit''' and '''64-bit''' options, that needs to be taken care of as well. See [[Gmake#Conditionals]] for an example.
Also as a user, you need to be aware of the files in the '''Compilers''' directory. The top-level '''makefile''' will be including one of these files, based on combining the result of '''uname -s''' with the value of '''FORTRAN'''. For instance, it might be including '''Darwin-gfortran.mk''' if you are on a Mac and using the '''gfortran''' compiler. You need to make sure this file exists and has the correct values for the compiler options and for finding the [http://www.unidata.ucar.edu/software/netcdf/ NetCDF] library. The file should contain pointers to both the '''NetCDF library''' and '''include''' files. If the library is different for '''32-bit''' and '''64-bit''' options, that needs to be taken care of as well. See [[Gmake#Conditionals]] for an example.

Revision as of 16:21, 12 November 2006

ROMS has a single makefile located in the top-level directory. Its generic structure facilitates the compiling of ROMS with other coupled models. The user usually needs to check/modify few definitions in the makefile before compiling a particular applications to specify primarily Fortran compiler, parallel options, and 64-bit floating-point number precision.

User Changes to makefile

As a user, you need to check and perhaps edit the makefile to set the values of the following definitions:

DEBUG :=
MPI :=
MPIF90 :=
OPENMP :=
ARPACK :=
LARGE :=
FORT ?=

See Gmake#Top_Level_Makefile and Gmake#Conditionals for more details.

Compiler-dependent Changes

Also as a user, you need to be aware of the files in the Compilers directory. The top-level makefile will be including one of these files, based on combining the result of uname -s with the value of FORTRAN. For instance, it might be including Darwin-gfortran.mk if you are on a Mac and using the gfortran compiler. You need to make sure this file exists and has the correct values for the compiler options and for finding the NetCDF library. The file should contain pointers to both the NetCDF library and include files. If the library is different for 32-bit and 64-bit options, that needs to be taken care of as well. See Gmake#Conditionals for an example.