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

Annotation of /MITgcm/tools/build_options/linux_ia32_gfortran

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


Revision 1.2 - (hide annotations) (download)
Fri Jun 17 22:38:18 2005 UTC (18 years, 10 months ago) by edhill
Branch: MAIN
CVS Tags: checkpoint57t_post, checkpoint57o_post, checkpoint57m_post, checkpoint57s_post, checkpoint57k_post, checkpoint57i_post, checkpoint57v_post, checkpoint57r_post, checkpoint57n_post, checkpoint57p_post, checkpint57u_post, checkpoint57q_post, checkpoint57j_post, checkpoint57l_post
Changes since 1.1: +10 -9 lines
 o mostly fix namelists for gcc-gfortran

1 edhill 1.1 #!/bin/bash
2     #
3 edhill 1.2 # $Header: /u/gcmpack/MITgcm/tools/build_options/linux_ia32_gfortran,v 1.1 2005/04/28 18:01:19 edhill Exp $
4 edhill 1.1 # $Name: $
5     #
6    
7 edhill 1.2 # Tested with gcc-gfortran v4.0.x as shipped with Fedora Core 4.
8     # It fixes the ' \' versus ' &' terminator problem but some
9     # namelist problems remain. The biggest seems to be the inability
10     # of current gfortran versions to support namelist syntax such as:
11     #
12     # fields(1,1) = 'UVELSLT ','VVELSLT ','WVELSLT ',
13     #
14     # which results in run-time errors.
15 edhill 1.1
16    
17     FC=gfortran
18     CC=gcc
19 edhill 1.2 DEFINES='-D_BYTESWAPIO -DWORDLENGTH=4 -DNML_TERMINATOR'
20 edhill 1.1 CPP='cpp -traditional -P'
21     NOOPTFLAGS='-O0'
22    
23     if test "x$IEEE" = x ; then
24     # No need for IEEE-754
25     FFLAGS='-Wimplicit -Wunused -Wuninitialized'
26     FOPTIM='-O3 -malign-double -funroll-loops'
27     else
28     # Try to follow IEEE-754
29     has_sse2=f
30     grep flags /proc/cpuinfo | grep sse2 > /dev/null 2>&1 && has_sse2=t
31     if test "x$has_sse2" = xt ; then
32     FFLAGS='-Wimplicit -Wunused -mfpmath=sse -msse -msse2'
33     else
34     FFLAGS='-Wimplicit -Wunused -ffloat-store'
35     fi
36     # echo 'FFLAGS="'$FFLAGS'"'
37     FOPTIM='-O0 -malign-double'
38     fi
39    
40     if test -d /usr/include/netcdf-3 ; then
41     INCLUDES='-I/usr/include/netcdf-3'
42     LIBS='-L/usr/lib/netcdf-3'
43     elif test -d /usr/include/netcdf ; then
44     INCLUDES='-I/usr/include/netcdf'
45     elif test -d /usr/local/netcdf ; then
46     INCLUDES='-I/usr/local/netcdf/include'
47     LIBS='-L/usr/local/netcdf/lib'
48     fi
49    

  ViewVC Help
Powered by ViewVC 1.1.22