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

Annotation of /MITgcm/tools/build_options/linux_amd64_pgf77

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


Revision 1.6 - (hide annotations) (download)
Sat Jul 20 23:04:02 2013 UTC (10 years, 9 months ago) by jmc
Branch: MAIN
Changes since 1.5: +3 -3 lines
change MPI_HEADER_FILES list (used for DIVA+MPI): tested on acesgrid with
 OpenMPI (but will not work with different MPI or older OpenMPI distribution)

1 ce107 1.1 #!/bin/bash
2     #
3 jmc 1.6 # $Header: /u/gcmpack/MITgcm/tools/build_options/linux_amd64_pgf77,v 1.5 2012/01/23 20:54:07 jmc Exp $
4 ce107 1.1 # $Name: $
5     #
6 jmc 1.3 # Build options for PGI compiler on Linux AMD64 platform
7 ce107 1.1 #
8 jmc 1.3 # tested with PGI version 10.9 on baudelaire (Linux 2.6.34.7-61.fc13.x86_64), using:
9     # - sh,bash:
10     # > export PGI=/srv/software/pgi/pgi-10.9
11     # > export PATH=$PGI/linux86-64/10.9/bin:$PATH
12     # > export MANPATH=$MANPATH:$PGI/linux86-64/10.9/man
13     # > export LM_LICENSE_FILE=$PGI/license.dat
14     # - csh,tcsh:
15     # > setenv PGI /srv/software/pgi/pgi-10.9
16     # > set path=($PGI/linux86-64/10.9/bin $path)
17     # > setenv MANPATH "$MANPATH":$PGI/linux86-64/10.9/man
18     # > setenv LM_LICENSE_FILE $PGI/license.dat
19 jmc 1.4 #
20     # and tested also with MPI on acesgrid (Fedora Core 15), using:
21     # module load pgi (Version 11.7)
22     # and with mpich2:
23     # module load mvapich2
24     # or with openmpi:
25     # module load openmpi
26 jmc 1.3 #-------
27 ce107 1.1
28 jmc 1.4 if test "x$MPI" = xtrue ; then
29     CC=mpicc
30     FC=mpif77
31 jmc 1.5 F90C=mpif90
32 jmc 1.4 else
33     CC=pgcc
34     FC=pgf77
35 jmc 1.5 F90C=pgf90
36 jmc 1.4 fi
37 jmc 1.2
38 jmc 1.5 DEFINES="-DWORDLENGTH=4"
39     if test "x$ALWAYS_USE_F90" = x1 ; then
40     FC=$F90C
41     else
42     DEFINES="$DEFINES -DNML_EXTENDED_F77"
43     fi
44 jmc 1.3 CPP='cpp -traditional -P'
45 jmc 1.2 EXTENDED_SRC_FLAG='-Mextend'
46 jmc 1.3 GET_FC_VERSION="-V"
47 jmc 1.2
48 ce107 1.1 NOOPTFLAGS='-O0'
49 jmc 1.4 NOOPTFILES=''
50    
51     FFLAGS="$FFLAGS -byteswapio -Ktrap=fp"
52     #- might want to use '-r8' for fizhi pkg:
53     #FFLAGS="$FFLAGS -r8"
54 jmc 1.2
55 jmc 1.4 if test "x$IEEE" = x ; then #- with optimisation:
56 jmc 1.3 FOPTIM='-tp k8-64 -pc=64 -O2 -Mvect=sse'
57     #FOPTIM="$FOPTIM -fastsse -O3 -Msmart -Mvect=cachesize:1048576,transform"
58 jmc 1.4 else #- no optimisation + IEEE :
59     #FFLAGS="$FFLAGS -Mdclchk" #- pkg/zonal_filt does not pass with declaration-check
60 jmc 1.3 FOPTIM='-pc=64 -O0 -Kieee'
61 ce107 1.1 fi
62    
63 jmc 1.4 INCLUDEDIRS=''
64     INCLUDES=''
65     LIBS=''
66    
67     if [ -n "$MPI_INC_DIR" -a "x$MPI" = xtrue ] ; then
68     INCLUDES="$INCLUDES -I$MPI_INC_DIR"
69     INCLUDEDIRS="$INCLUDEDIRS $MPI_INC_DIR"
70     MPIINCLUDEDIR="$MPI_INC_DIR"
71 jmc 1.6 MPI_HEADER_FILES='mpif.h mpif-common.h mpif-config.h mpif-mpi-io.h'
72     MPI_HEADER_FILES_INC='./mpi_headers/mpif.h ./mpi_headers/mpif-common.h ./mpi_headers/mpif-config.h ./mpi_headers/mpif-mpi-io.h'
73 jmc 1.4 fi

  ViewVC Help
Powered by ViewVC 1.1.22