/[MITgcm]/MITgcm/tools/build_options/linux_ia32_open64+mth
ViewVC logotype

Contents of /MITgcm/tools/build_options/linux_ia32_open64+mth

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


Revision 1.5 - (show annotations) (download)
Mon Mar 22 22:56:31 2010 UTC (14 years, 1 month ago) by ce107
Branch: MAIN
CVS Tags: checkpoint62g, checkpoint62f, checkpoint62e, 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.4: +2 -2 lines
Changed elif to else to get the logic right

1 #!/bin/bash
2 #
3 # $Header: /u/gcmpack/MITgcm/tools/build_options/linux_ia32_open64+mth,v 1.4 2010/03/19 03:32:54 ce107 Exp $
4 # $Name: $
5 #
6 # Multithreaded tests require
7 # export OMP_SLAVE_STACK_SIZE=400m
8 # export OMP_NUM_THREADS=2
9 #
10 # Note: use just -O2 optimisation to avoid some wierd problems with -O3
11 # on aces (open64/4.1 & 4.2) (ideal_2D_ocean)
12
13 CC=opencc
14 FC=openf90
15 F90C=openf90
16 F90FIXEDFORMAT='-fixedform -x f95'
17 LD=openf90
18 DEFINES='-DWORDLENGTH=4 -DUSE_OMP_THREADING'
19 CPP='cpp -traditional -P'
20 EXTENDED_SRC_FLAG='-extend-source'
21 MAKEDEPEND=/usr/X11R6/bin/makedepend
22 NOOPTFLAGS='-O0 -m32 -g -openmp'
23 # to avoid a bug in ealier version (4.1) of compiler with openMP:
24 NOOPTFILES='mon_set_iounit.F mon_init.F'
25
26 if test "x$DEVEL" != x ; then
27 FFLAGS='-m32 -convert big_endian -openmp -ffortran-bounds-check -trapuv -g'
28 else
29 FFLAGS='-m32 -convert big_endian -openmp'
30 fi
31
32 if test "x$IEEE" = x ; then
33 # No need for IEEE-754
34 FOPTIM='-O2 -LNO:fusion=2 -OPT:roundoff=1:IEEE_arithmetic=3 -OPT:early_mp=ON' # -funsafe-math-optimizations'
35 else
36 # Try to follow IEEE-754
37 FOPTIM='-O2 -LNO:fusion=2 -OPT:roundoff=0:IEEE_arithmetic=1 -fmath-errno -fno-fast-math -OPT:early_mp=ON'
38 fi
39
40 F90FLAGS=$FFLAGS
41 F90OPTIM=$FOPTIM
42 CFLAGS='-O2 -m32 -openmp'
43 GSLLIB='-lgsl -lgslcblas'
44
45 if [ "x$NETCDF_ROOT" != x ] ; then
46 INCLUDEDIR="${NETCDF_ROOT}/include"
47 INCLUDES="-I${NETCDF_ROOT}/include"
48 LIBDIR="${NETCDF_ROOT}/lib"
49 LIBS="-L${NETCDF_ROOT}/lib"
50 elif [ "x$NETCDF_HOME" != x ]; then
51 INCLUDEDIR="${NETCDF_HOME}/include"
52 INCLUDES="-I${NETCDF_HOME}/include"
53 LIBDIR="${NETCDF_HOME}/lib"
54 LIBS="-L${NETCDF_HOME}/lib"
55 elif [ "x$NETCDF_INC" != x -a "x$NETCDF_LIB" != x ]; then
56 NETCDF_INC=`echo $NETCDF_INC | sed 's/-I//g'`
57 NETCDF_LIB=`echo $NETCDF_LIB | sed 's/-L//g'`
58 INCLUDEDIR="${NETCDF_INC}"
59 INCLUDES="-I${NETCDF_INC}"
60 LIBDIR="${NETCDF_LIB}"
61 LIBS="-L${NETCDF_LIB}"
62 elif [ "x$NETCDF_INCDIR" != x -a "x$NETCDF_LIBDIR" != x ]; then
63 INCLUDEDIR="${NETCDF_INCDIR}"
64 INCLUDES="-I${NETCDF_INCDIR}"
65 LIBDIR="${NETCDF_LIBDIR}"
66 LIBS="-L${NETCDF_LIBDIR}"
67 elif test -d /usr/include/netcdf-3 ; then
68 INCLUDES='-I/usr/include/netcdf-3'
69 LIBS='-L/usr/lib/netcdf-3 -lnetcdf_g77'
70 elif test -d /usr/include/netcdf ; then
71 INCLUDES='-I/usr/include/netcdf'
72 elif test -d /usr/local/netcdf ; then
73 INCLUDES='-I/usr/local/netcdf/include'
74 LIBS='-L/usr/local/netcdf/lib'
75 elif test -d /usr/local/include/netcdf.inc ; then
76 INCLUDES='-I/usr/local/include'
77 LIBS='-L/usr/local/lib'
78 fi
79
80 if [ "x$LIBS" != x ] ; then
81 LIBS="$LIBS -lstdc++"
82 else
83 LIBS="-lstdc++"
84 fi

  ViewVC Help
Powered by ViewVC 1.1.22