/[MITgcm]/MITgcm/tools/build_options/sunos_sparc_sunf90_m64+mpi_generic+mth
ViewVC logotype

Annotation of /MITgcm/tools/build_options/sunos_sparc_sunf90_m64+mpi_generic+mth

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.2 - (hide annotations) (download)
Sun Mar 21 22:22:53 2010 UTC (14 years, 1 month ago) by jmc
Branch: MAIN
CVS Tags: checkpoint62g, checkpoint62f, checkpoint62e, checkpoint62d, checkpoint62k, checkpoint62j, checkpoint62i, checkpoint62h, checkpoint62o, checkpoint62n, checkpoint62m, checkpoint62l, checkpoint62s, checkpoint62r, checkpoint62q, checkpoint62p, checkpoint62w, checkpoint62v, checkpoint62u, checkpoint62t, checkpoint62z, checkpoint62y, checkpoint62x, checkpoint63a, checkpoint63b, checkpoint63c, checkpoint63
Changes since 1.1: +3 -1 lines
add cvs Name and Header (if missing)

1 ce107 1.1 #!/bin/bash
2     #
3 jmc 1.2 # $Header: $
4     # $Name: $
5 ce107 1.1
6     # Build options for the Sun fortran compiler with a generic MPI
7     # DON'T FORGET to set environment variable MPI_INC_DIR to the include
8     # directory of your MPI implementation
9 jmc 1.2
10 ce107 1.1 FC=${FC:=mpif77}
11     F90C=${F90C:=mpif90}
12     CC=${CC:=mpicc}
13     LINK=${F90C}
14     FC_NAMEMANGLE="#define FC_NAMEMANGLE(X) X ## _"
15     DEFINES='-DWORDLENGTH=4 -DUSE_OMP_THREADING'
16     CPP='/usr/ccs/lib/cpp -P'
17     NOOPTFLAGS='-O0 -g -m64 -u -r8const -xopenmp=noopt'
18     NOOPTFILES=''
19     EXTENDED_SRC_FLAG='-e'
20    
21     if test "x$DEVEL" != x ; then
22     FFLAGS='-u -r8const -g -xs -C -xcommonchk -xcheck=init_local -fpover -xopenmp=noopt'
23     else
24     FFLAGS='-u -r8const -xopenmp'
25     fi
26    
27     if test "x$IEEE" = x ; then
28     # No need for IEEE-754
29     FOPTIM='-fast -m64 -xvector=lib -xpad=local'
30     LIBS="$LIBS -lmopt -lsunmath"
31     else
32     # Try to follow IEEE-754
33     # FOPTIM='-O0 -m64'
34     FOPTIM='-fast -m64 -xpad=local -fsimple=1'
35     fi
36     F90FLAGS=$FFLAGS
37     F90OPTIM=$FOPTIM
38     CFLAGS='-O3 -m64 -xopenmp'
39    
40     if [ "x$NETCDF_ROOT" != x ] ; then
41     INCLUDEDIR="${NETCDF_ROOT}/include"
42     INCLUDES="-I${NETCDF_ROOT}/include"
43     LIBDIR="${NETCDF_ROOT}/lib"
44     LIBS="-L${NETCDF_ROOT}/lib"
45     elif [ "x$NETCDF_HOME" != x ]; then
46     INCLUDEDIR="${NETCDF_HOME}/include"
47     INCLUDES="-I${NETCDF_HOME}/include"
48     LIBDIR="${NETCDF_HOME}/lib"
49     LIBS="-L${NETCDF_HOME}/lib"
50     elif [ "x$NETCDF_INC" != x -a "x$NETCDF_LIB" != x ]; then
51     NETCDF_INC=`echo $NETCDF_INC | sed 's/-I//g'`
52     NETCDF_LIB=`echo $NETCDF_LIB | sed 's/-L//g'`
53     INCLUDEDIR="${NETCDF_INC}"
54     INCLUDES="-I${NETCDF_INC}"
55     LIBDIR="${NETCDF_LIB}"
56     LIBS="-L${NETCDF_LIB}"
57     elif [ "x$NETCDF_INCDIR" != x -a "x$NETCDF_LIBDIR" != x ]; then
58     INCLUDEDIR="${NETCDF_INCDIR}"
59     INCLUDES="-I${NETCDF_INCDIR}"
60     LIBDIR="${NETCDF_LIBDIR}"
61     LIBS="-L${NETCDF_LIBDIR}"
62     elif test -d /usr/include/netcdf ; then
63     INCLUDES='-I/usr/include/netcdf'
64     elif test -d /usr/local/netcdf ; then
65     INCLUDES='-I/usr/local/netcdf/include'
66     LIBS='-L/usr/local/netcdf/lib'
67     elif test -d /usr/local/include/netcdf.inc ; then
68     INCLUDES='-I/usr/local/include'
69     LIBS='-L/usr/local/lib64 -L/usr/local/lib'
70     fi
71    
72     INCLUDES="$INCLUDES -I$MPI_INC_DIR"
73     INCLUDEDIRS="$INCLUDEDIRS $MPI_INC_DIR"
74     MPIINCLUDEDIR="$MPI_INC_DIR"
75     MPI_HEADER_FILES=${MPI_HEADER_FILES:='mpif.h mpiof.h'}
76     MPI_HEADER_FILES_INC=${MPI_HEADER_FILES_INC:='./mpi_headers/mpif.h ./mpi_headers/mpiof.h'}
77    

  ViewVC Help
Powered by ViewVC 1.1.22