default 9.31 KB
Newer Older
Uwe Schulzweida's avatar
Uwe Schulzweida committed
1
2
3
4
#! /bin/sh
#
# default configuration options and compiler flags for different hosts
#
Uwe Schulzweida's avatar
Uwe Schulzweida committed
5
6
7
8
9
10
11
12
SGE_MODE=off
SGE_SUFFIX=sge
#
CONFPATH=`echo $0 | cut -c 1-6`
if [ "$CONFPATH" != "../../" ] ; then
CONFPATH='./'
fi
#
Uwe Schulzweida's avatar
Uwe Schulzweida committed
13
14
15
if test -z "$1" ; then
  HOSTNAME=`hostname`
else
Uwe Schulzweida's avatar
Uwe Schulzweida committed
16
  if [ "$1" = "$SGE_SUFFIX" ] ; then
Uwe Schulzweida's avatar
Uwe Schulzweida committed
17
18
19
20
21
    SGE_MODE=on
    HOSTNAME=`hostname`
  else
    HOSTNAME=$1
  fi
Uwe Schulzweida's avatar
Uwe Schulzweida committed
22
23
fi
#
Uwe Schulzweida's avatar
Uwe Schulzweida committed
24
set -x
Uwe Schulzweida's avatar
Uwe Schulzweida committed
25
26
27
28
#
case "${HOSTNAME}" in
# ia64-xxx-linux
    ds*)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
29
30
        if [ "$SGE_MODE" = "off" ] ; then
	  ${CONFPATH}configure --prefix=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
31
                    --with-netcdf=/pool/ia64/netcdf/netcdf-3.6.0-p1 \
32
                    --with-szlib=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
33
                    CC=icc CFLAGS="-g -O2 -Wall -fno-alias -DMIN_BUF_SIZE=4194304"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
34
35
36
37
        else
	  ${CONFPATH}configure --prefix=$HOME/local \
                    --program-suffix=_${SGE_SUFFIX} \
                    --with-netcdf=/pool/ia64/netcdf/netcdf-3.6.0-p1 \
38
39
40
                    --with-szlib=$HOME/local \
                    CPPFLAGS="-DHAVE_LIBDRMAA -I/opt/gridware/sge/include -DHAVE_LIBCURL -I/pool/ia64/libcurl4-7.16.0/include" \
                    LIBS="-L/opt/gridware/sge/lib/lx24-ia64 -ldrmaa -ldl /pool/ia64/libcurl4-7.16.0/lib/libcurl.a -lssl -lz" \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
41
42
                    CC=icc CFLAGS="-g -O2 -Wall -fno-alias -DMIN_BUF_SIZE=4194304"
        fi
Uwe Schulzweida's avatar
Uwe Schulzweida committed
43
44
	;;
    wasser*)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
45
	${CONFPATH}configure --prefix=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
46
47
48
                    --with-netcdf=/home/dkrz/m214089/local/ia64 \
                    CC=icc CFLAGS="-g -O2 -Wall -fno-alias"
	;;
Uwe Schulzweida's avatar
Uwe Schulzweida committed
49
# x86_64-suse-linux
50
51
52
53
54
55
56
    tornado5)
 	${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/sles10-x64 \
	            --with-netcdf=/sw/sles10-x64/netcdf-4.0.1 \
	            --with-hdf5=/sw/sles10-x64/hdf5-1.8.2 \
                    --with-szlib=/sw/sles10-x64/szip-2.1 \
	            CC=gcc CFLAGS="-g -D_REENTRANT -O2 -Wall"
	;;        
Uwe Schulzweida's avatar
Uwe Schulzweida committed
57
58
    tornado1)
 	${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/sles9-x64 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
59
	            --with-netcdf=/sw/sles9-x64/netcdf-3.6.2 \
60
                    --with-szlib=$HOME/local/sles9-x64 \
61
	            CC=gcc CFLAGS="-g -D_REENTRANT -O2 -Wall"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
62
	;;        
Uwe Schulzweida's avatar
Uwe Schulzweida committed
63
64
# x86_64-etch-x64-linux
    squall1)
65
66
        if [ "$SGE_MODE" = "off" ] ; then
   	  ${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/etch-x64 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
67
	            --with-netcdf=/sw/etch-x64/netcdf-3.6.2 \
68
                    --with-szlib=/sw/etch-x64/szip-2.1 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
69
                    --with-proj=$HOME/local/etch-x64/proj-4.6.1 \
70
71
72
	            CC=gcc CFLAGS="-g -D_REENTRANT -O2 -Wall"
        else
   	  ${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/etch-x64 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
73
	            --with-netcdf=/sw/etch-x64/netcdf-3.6.2 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
74
                    --with-szlib=/sw/etch-x64/szip-2.1 \
75
76
                    CPPFLAGS="-DHAVE_LIBDRMAA -I/opt/gridware/sge/include -DHAVE_LIBCURL -I/usr/include" \
                    LIBS="-L/opt/gridware/sge/lib/lx24-amd64 -ldrmaa -ldl -L/usr/lib -lcurl" \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
77
	            CC=gcc CFLAGS="-g -D_REENTRANT -O2 -Wall"
78
        fi
Uwe Schulzweida's avatar
Uwe Schulzweida committed
79
	;;        
Uwe Schulzweida's avatar
Uwe Schulzweida committed
80
# i686-suse-linux
Uwe Schulzweida's avatar
Uwe Schulzweida committed
81
    linux | laptop)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
82
	${CONFPATH}configure --prefix=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
83
                    --with-netcdf=$HOME/local \
84
                    --with-szlib=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
85
                    CC=g++ CFLAGS="-g -D_REENTRANT -O2 -Wall -W -Wfloat-equal"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
86
	;;
Uwe Schulzweida's avatar
Uwe Schulzweida committed
87
# etch-ia32
88
    etch-ia32 | gata | baba)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
89
90
        if [ "$SGE_MODE" = "off" ] ; then
 	  ${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/etch-ia32 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
91
	            --with-netcdf=/sw/etch-ia32/netcdf-3.6.2 \
92
	            --with-hdf5=/sw/etch-ia32/hdf5-1.8.0 \
93
                    --with-szlib=$HOME/local/etch-ia32 \
94
                    --with-proj=/sw/etch-ia32/proj-4.6.0 \
95
	            CC=gcc CFLAGS="-g -D_REENTRANT -O2 -Wall -W -Wfloat-equal -Wno-long-long -ansi -pedantic -std=c99"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
96
97
98
        else
 	  ${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/etch-ia32 \
                    --program-suffix=_${SGE_SUFFIX} \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
99
	            --with-netcdf=/sw/etch-ia32/netcdf-3.6.2 \
100
101
102
                    --with-szlib=$HOME/local/etch-ia32 \
                    CPPFLAGS="-DHAVE_LIBDRMAA -I/opt/gridware/sge/include -DHAVE_LIBCURL -I/usr/include" \
                    LIBS="-L/opt/gridware/sge/lib/lx24-x86 -ldrmaa -ldl -L/usr/lib -lcurl" \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
103
104
105
106
                    CC=gcc CFLAGS="-g -D_REENTRANT -O2 -Wall -W -Wfloat-equal"
        fi
        ;;
# sarge-ia32
107
    sarge-ia32)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
108
# opt: -fno-PIC -O4 -march=i686 -mcpu=i686 -pipe -ffast-math -fomit-frame-pointer
Uwe Schulzweida's avatar
Uwe Schulzweida committed
109
        if [ "$SGE_MODE" = "off" ] ; then
Uwe Schulzweida's avatar
Uwe Schulzweida committed
110
 	  ${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/LINUX \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
111
	            --with-netcdf=/client \
112
                    --with-szlib=$HOME/local/LINUX \
113
	            CC=gcc CFLAGS="-g -D_REENTRANT -O2 -Wall -W -Wfloat-equal"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
114
115
116
117
        else
 	  ${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/LINUX \
                    --program-suffix=_${SGE_SUFFIX} \
	            --with-netcdf=/client \
118
119
120
                    --with-szlib=$HOME/local/LINUX \
                    CPPFLAGS="-DHAVE_LIBDRMAA -I/opt/gridware/sge/include -DHAVE_LIBCURL -I/usr/include" \
                    LIBS="-L/opt/gridware/sge/lib/lx24-x86 -ldrmaa -ldl -L/usr/lib -lcurl" \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
121
122
                    CC=gcc CFLAGS="-g -D_REENTRANT -O2 -Wall -W -Wfloat-equal"
        fi
Uwe Schulzweida's avatar
Uwe Schulzweida committed
123
124
	;;
    regio01)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
125
	${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/LINUX0 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
126
127
128
129
	            --with-netcdf=/client \
	            CC=gcc CFLAGS="-g -D_REENTRANT -O2 -Wall"
	;;
# i386-pc-solaris2.10
130
    grim)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
131
	${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/solaris10-x86 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
132
                    --with-netcdf=/client \
133
                    --with-szlib=$HOME/local/solaris10-x86 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
134
135
                    CC=cc CFLAGS="-g -mt -fast"
	;;
Uwe Schulzweida's avatar
Uwe Schulzweida committed
136
# sparc-sun-solaris2.10
Uwe Schulzweida's avatar
Uwe Schulzweida committed
137
    xxf)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
138
	${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/solaris10 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
139
                    --with-netcdf=/sw/solaris10/netcdf-3.6.2 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
140
                    CC=cc CFLAGS="-g -mt -xO3 -m64"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
141
	;;
Uwe Schulzweida's avatar
Uwe Schulzweida committed
142
# sparc-sun-solaris2.9 changed to
143
# sparc-sun-solaris2.10
Uwe Schulzweida's avatar
Uwe Schulzweida committed
144
    executor | yang | yin)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
145
        if [ "$SGE_MODE" = "off" ] ; then
146
 	  ${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/solaris10 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
147
                    --with-netcdf=/sw/solaris10/netcdf-3.6.2 \
148
                    --with-szlib=$HOME/local/solaris10 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
149
                    CC=cc CFLAGS="-g -mt -xO3 -m64"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
150
        else
151
 	  ${CONFPATH}configure --prefix=$HOME/local --exec_prefix=$HOME/local/solaris10 \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
152
                    --program-suffix=_${SGE_SUFFIX} \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
153
                    --with-netcdf=/sw/solaris10/netcdf-3.6.2 \
154
155
156
                    --with-szlib=$HOME/local/solaris10 \
                    CPPFLAGS="-DHAVE_LIBDRMAA -I/opt/gridware/sge/include -DHAVE_LIBCURL -I/usr/local/include" \
                    LIBS="-L/opt/gridware/sge/lib/sol-sparc64 -ldrmaa -ldl -L/sw/solaris10/curl-7.16.4-cc/lib -lcurl" \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
157
                    CC=cc CFLAGS="-g -mt -xO3 -m64"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
158
        fi
Uwe Schulzweida's avatar
Uwe Schulzweida committed
159
160
161
	;;
# sx6-nec-superux12.2
    cs*)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
162
	${CONFPATH}configure --prefix=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
163
164
165
166
167
         	    --with-netcdf=/pool/netcdf/netcdf-3.6.0-p1 \
		    CC=c++ \
                    CFLAGS="-O -Onooverlap,restrict=all -pvctl,fullmsg,noassume,loopcnt=1000000"
	;;
    sx6)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
168
	${CONFPATH}configure --host=sx6 --prefix=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
169
170
171
172
173
                    --with-netcdf=/pool/SX-6/netcdf/netcdf-3.6.0-p1 \
		    CC=sxc++ AR=sxar \
                    CFLAGS="-O -Onooverlap,restrict=all -pvctl,fullmsg,noassume,loopcnt=1000000"
	;;
    es)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
174
	${CONFPATH}configure --host=sx6 --prefix=$HOME/local/ES \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
175
176
177
178
179
180
                    --with-netcdf=/S/n010/home010/c0148/local/SX \
		    CC=esc++ AR=esar \
                    CFLAGS="-O -Onooverlap,restrict=all -pvctl,fullmsg,noassume,loopcnt=1000000"
	;;
# mips-sgi-irix6.5
    ecgate1)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
181
	${CONFPATH}configure --prefix=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
182
183
184
185
186
 	            --with-netcdf=/home/ms/spdekplb/hmk/include,/home/ms/spdekplb/hmk/lib64 \
	            CC=cc CFLAGS="-O -64"
	;;
# 5000-fujitsu-uxpv4.1_ES
    vpp5*)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
187
	${CONFPATH}configure --prefix=$HOME \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
188
189
190
191
192
	            --with-netcdf=$HOME/PROJ \
	            CC=vcc CFLAGS="-O -Wv,-m3 -K4"
	;;
# powerpc-ibm-aix5.2.0.0
    ecgate)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
193
	${CONFPATH}configure --prefix=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
194
                    --with-netcdf=/usr/local/apps/netCDF/3.6.2/LP64_underscore \
195
                    --with-szlib=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
196
	            CC=xlc_r CFLAGS="-g -O3 -q64 -qMAXMEM=-1 -qarch=auto -DHAVE_MMAP"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
197
	;;
Uwe Schulzweida's avatar
Uwe Schulzweida committed
198
# powerpc-ibm-aix5.3.0.0
Uwe Schulzweida's avatar
Uwe Schulzweida committed
199
    vip*)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
200
201
202
	${CONFPATH}configure --prefix=$HOME/local \
                    --with-netcdf=$HOME/local \
                    --with-szlib=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
203
	            CC=xlc_r CFLAGS="-g -O3 -q64 -qstrict -qarch=auto -qtune=auto -DHAVE_MMAP"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
204
	;;
Uwe Schulzweida's avatar
Uwe Schulzweida committed
205
# powerpc-ibm-aix6.0.0.0
206
    hpc*)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
207
	${CONFPATH}configure --prefix=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
208
                    --with-netcdf=/usr/local/lib/netcdf/3.6.2/LP64_underscore \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
209
                    --with-hdf5=/usr/local/lib/hdf5/1.8.1/LP64_underscore \
210
                    --with-szlib=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
211
                    --with-proj=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
212
	            CC=xlc_r CFLAGS="-g -O3 -q64 -qstrict -qarch=auto -qtune=auto -qreport -qsmp=omp -DHAVE_MMAP"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
213
	;;
Uwe Schulzweida's avatar
Uwe Schulzweida committed
214
# powerpc-ibm-aix6.0.0.0
Uwe Schulzweida's avatar
Uwe Schulzweida committed
215
    dwd | p???et01)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
216
	${CONFPATH}configure --prefix=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
217
                    --with-netcdf=/uhome/mpischul/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
218
	            CC=xlc_r CFLAGS="-g -O -q64 -qMAXMEM=-1 -qarch=auto -DHAVE_MMAP"
Uwe Schulzweida's avatar
Uwe Schulzweida committed
219
220
221
	;;
# hppa2.0w-hp-hpux11.11
    moon)
Uwe Schulzweida's avatar
Uwe Schulzweida committed
222
        ${CONFPATH}configure --prefix=$HOME/local \
Uwe Schulzweida's avatar
Uwe Schulzweida committed
223
224
225
226
227
228
229
                    --with-netcdf=/S/n010/home010/c0148/local \
	            CC=cc CFLAGS="-g -fast"
	;;
    *)
	echo "configuration for hostname $HOSTNAME not found!"
	;;
esac