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

Annotation of /MITgcm/tools/build_options/linux_amd64_g77

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


Revision 1.5 - (hide annotations) (download)
Sat Oct 16 17:06:04 2010 UTC (13 years, 6 months ago) by jmc
Branch: MAIN
CVS Tags: checkpoint62o, checkpoint62n, checkpoint62m
Changes since 1.4: +4 -1 lines
add "-fPIC" for big objects

1 edhill 1.1 #!/bin/bash
2     #
3 jmc 1.5 # $Header: /u/gcmpack/MITgcm/tools/build_options/linux_amd64_g77,v 1.4 2009/07/21 19:55:13 jmc Exp $
4 edhill 1.1 # $Name: $
5     #
6     # Build options for Suse 9 Opteron
7 jmc 1.3 # tested on Linux 2.4.21-102-smp (x86_64),
8     # Linux 2.6.26.8-57.fc8 (x86_64), Linux 2.6.27.9-159.fc10.x86_64
9 edhill 1.1 #
10    
11     FC=g77
12     DEFINES='-D_BYTESWAPIO -DWORDLENGTH=4'
13     CPP='cpp -traditional -P'
14     NOOPTFLAGS='-O0'
15 jmc 1.3 EXTENDED_SRC_FLAG='-ffixed-line-length-132'
16 edhill 1.1 #MAKEDEPEND=/usr/X11R6/bin/gccmakedep
17 edhill 1.2 #MAKEDEPEND=/usr/X11R6/bin/makedepend
18 edhill 1.1 # For IEEE, use the "-ffloat-store" option
19     if test "x$IEEE" = x ; then
20     FFLAGS='-Wimplicit -Wunused -Wuninitialized'
21     FOPTIM='-O3 -funroll-loops'
22     else
23     FFLAGS='-Wimplicit -Wunused -ffloat-store'
24 jmc 1.3 # FFLAGS="$FFLAGS -g -mfpmath=sse -msse -msse2 -fbounds-check"
25     FOPTIM='-O0'
26 edhill 1.1 fi
27 jmc 1.5 # for big objects:
28     FFLAGS="$FFLAGS -fPIC"
29     CFLAGS="-O0 -fPIC"
30 edhill 1.2
31     if test -d /usr/include/netcdf-3 ; then
32 jmc 1.4 #-- some FedoraCore standard location used to be "netcdf-3"
33 edhill 1.2 INCLUDES='-I/usr/include/netcdf-3'
34     if test -d /usr/lib64/netcdf-3 ; then
35     if test -f /usr/lib64/netcdf-3/libnetcdf_g77.a ; then
36     LIBS='-L/usr/lib64/netcdf-3 -lnetcdf_g77'
37     else
38     LIBS='-L/usr/lib64/netcdf-3'
39     fi
40     elif test -d /usr/lib/netcdf-3 ; then
41     if test -f /usr/lib/netcdf-3/libnetcdf_g77.a ; then
42     LIBS='-L/usr/lib/netcdf-3 -lnetcdf_g77'
43     else
44     LIBS='-L/usr/lib/netcdf-3'
45     fi
46     fi
47     elif test -d /usr/include/netcdf ; then
48 jmc 1.4 #-- allows a "compat"(gcc 3.4) 2nd version of libs for g77 , next to the
49     # standard one (for gfortran, gcc 4.x). But uses same include files.
50 edhill 1.2 INCLUDES='-I/usr/include/netcdf'
51 jmc 1.4 if test -d /usr/lib64/netcdf34 ; then
52     if test -f /usr/lib64/netcdf34/libnetcdf_g77.a ; then
53     LIBS='-L/usr/lib64/netcdf34 -lnetcdf_g77'
54     else
55     LIBS='-L/usr/lib64/netcdf34'
56     fi
57     elif test -d /usr/lib/netcdf34 ; then
58     if test -f /usr/lib/netcdf34/libnetcdf_g77.a ; then
59     LIBS='-L/usr/lib/netcdf34 -lnetcdf_g77'
60     else
61     LIBS='-L/usr/lib/netcdf34'
62     fi
63     fi
64 edhill 1.2 elif test -d /usr/local/netcdf ; then
65     INCLUDES='-I/usr/local/netcdf/include'
66     LIBS='-L/usr/local/netcdf/lib'
67     fi
68    

  ViewVC Help
Powered by ViewVC 1.1.22