/[MITgcm]/MITgcm/tools/build_options/linux_ia32_g77
ViewVC logotype

Contents of /MITgcm/tools/build_options/linux_ia32_g77

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


Revision 1.19 - (show annotations) (download)
Sun Oct 16 06:51:33 2005 UTC (18 years, 7 months ago) by edhill
Branch: MAIN
CVS Tags: checkpoint57y_post, checkpoint57y_pre, checkpoint57x_post, checkpoint57w_post
Changes since 1.18: +8 -2 lines
 o better handling of netcdf libs on FC4 which ships gfortran (default)
   and g77 (optional) which have incompatible default name-mangling

1 #!/bin/bash
2 #
3 # $Header: /u/gcmpack/MITgcm/tools/build_options/linux_ia32_g77,v 1.18 2005/08/31 19:42:38 dimitri Exp $
4 # $Name: $
5 #
6
7
8 FC=g77
9 CC=gcc
10 DEFINES='-D_BYTESWAPIO -DWORDLENGTH=4'
11 CPP='cpp -traditional -P'
12 NOOPTFLAGS='-O0'
13
14 if test "x$IEEE" = x ; then
15 # No need for IEEE-754
16 FFLAGS='-Wimplicit -Wunused -Wuninitialized'
17 FOPTIM='-O3 -malign-double -funroll-loops'
18 else
19 # Try to follow IEEE-754
20 has_sse2=f
21 grep flags /proc/cpuinfo | grep sse2 > /dev/null 2>&1 && has_sse2=t
22
23 # older OS on sea.mit.edu does not support sse
24 if [ `uname -n` = "sea" ]; then has_sse2=f; fi
25
26 if test "x$has_sse2" = xt ; then
27 FFLAGS='-Wimplicit -Wunused -mfpmath=sse -msse -msse2'
28 else
29 FFLAGS='-Wimplicit -Wunused -ffloat-store'
30 fi
31 # echo 'FFLAGS="'$FFLAGS'"'
32 FOPTIM='-O0 -malign-double'
33 fi
34
35 if test -d /usr/include/netcdf-3 ; then
36 INCLUDES='-I/usr/include/netcdf-3'
37 if test -d /usr/lib/netcdf-3 ; then
38 if test -f /usr/lib/netcdf-3/libnetcdf_g77.a ; then
39 LIBS='-L/usr/lib/netcdf-3 -lnetcdf_g77'
40 else
41 LIBS='-L/usr/lib/netcdf-3'
42 fi
43 fi
44 elif test -d /usr/include/netcdf ; then
45 INCLUDES='-I/usr/include/netcdf'
46 elif test -d /usr/local/netcdf ; then
47 INCLUDES='-I/usr/local/netcdf/include'
48 LIBS='-L/usr/local/netcdf/lib'
49 fi

  ViewVC Help
Powered by ViewVC 1.1.22