Install Hydro-Quebec Tools in test loop
[foam-extend-3.2.git] / etc / settings.sh
blob8b0518697402b9d8d1d7817a09ef9bc2dbc233b7
1 #----------------------------------*-sh-*--------------------------------------
2 # ========= |
3 # \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4 # \\ / O peration |
5 # \\ / A nd | Copyright held by original author
6 # \\/ M anipulation |
7 #------------------------------------------------------------------------------
8 # License
9 # This file is part of OpenFOAM.
11 # OpenFOAM is free software; you can redistribute it and/or modify it
12 # under the terms of the GNU General Public License as published by the
13 # Free Software Foundation; either version 2 of the License, or (at your
14 # option) any later version.
16 # OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19 # for more details.
21 # You should have received a copy of the GNU General Public License
22 # along with OpenFOAM; if not, write to the Free Software Foundation,
23 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25 # Script
26 # etc/settings.sh
28 # Description
29 # Startup file for OpenFOAM
30 # Sourced from OpenFOAM-??/etc/bashrc
32 #------------------------------------------------------------------------------
34 # prefix to PATH
35 _foamAddPath()
37 while [ $# -ge 1 ]
39 export PATH=$1:$PATH
40 shift
41 done
44 # prefix to LD_LIBRARY_PATH
45 _foamAddLib()
47 while [ $# -ge 1 ]
49 export LD_LIBRARY_PATH=$1:$LD_LIBRARY_PATH
50 if [ "$WM_ARCH_BASE" = "darwin" ]
51 then
52 # do NOT add the lib of MacPort as this might break programs
53 if [ "$1" != "/opt/local/lib" ]
54 then
55 export DYLD_LIBRARY_PATH=$1:$DYLD_LIBRARY_PATH
58 shift
59 done
62 # Source files, possibly with some verbosity
63 # Yes, this is the same definition as in the file etc/bash
64 # We need that definition available for scripts sourcing
65 # settings.sh directly.
66 _foamSource()
68 while [ $# -ge 1 ]
70 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo "Sourcing: $1"
71 . $1
72 shift
73 done
76 # location of the jobControl directory
77 export FOAM_JOB_DIR=$HOME/$WM_PROJECT/jobControl
79 # wmake configuration
80 export WM_DIR=$WM_PROJECT_DIR/wmake
81 export WM_LINK_LANGUAGE=c++
82 export WM_OPTIONS=$WM_ARCH$WM_COMPILER$WM_PRECISION_OPTION$WM_COMPILE_OPTION
83 export PATH=$WM_DIR:$PATH
85 # base configuration
86 export FOAM_APP=$WM_PROJECT_DIR/applications
87 export FOAM_APPBIN=$WM_PROJECT_DIR/applications/bin/$WM_OPTIONS
88 export FOAM_LIB=$WM_PROJECT_DIR/lib
89 export FOAM_LIBBIN=$WM_PROJECT_DIR/lib/$WM_OPTIONS
90 export FOAM_SRC=$WM_PROJECT_DIR/src
92 # shared site configuration - similar naming convention as ~OpenFOAM expansion
93 export FOAM_SITE_APPBIN=$WM_PROJECT_INST_DIR/site/$WM_PROJECT_VERSION/bin/$WM_OPTIONS
94 export FOAM_SITE_LIBBIN=$WM_PROJECT_INST_DIR/site/$WM_PROJECT_VERSION/lib/$WM_OPTIONS
96 # user configuration
97 export FOAM_USER_APPBIN=$WM_PROJECT_USER_DIR/applications/bin/$WM_OPTIONS
98 export FOAM_USER_LIBBIN=$WM_PROJECT_USER_DIR/lib/$WM_OPTIONS
100 # convenience
101 export FOAM_TUTORIALS=$WM_PROJECT_DIR/tutorials
102 export FOAM_UTILITIES=$FOAM_APP/utilities
103 export FOAM_SOLVERS=$FOAM_APP/solvers
104 export FOAM_RUN=$WM_PROJECT_USER_DIR/run
106 # add OpenFOAM scripts and wmake to the path
107 export PATH=$WM_DIR:$WM_PROJECT_DIR/bin:$PATH
109 _foamAddPath $FOAM_APPBIN $FOAM_SITE_APPBIN $FOAM_USER_APPBIN
110 # Make sure to pick up dummy versions of external libraries last
111 _foamAddLib $FOAM_LIBBIN/dummy
112 _foamAddLib $FOAM_LIBBIN $FOAM_SITE_LIBBIN $FOAM_USER_LIBBIN
115 # Compiler settings
116 # ~~~~~~~~~~~~~~~~~
117 unset compilerBin compilerLib
119 # Select compiler installation
120 # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
121 # compilerInstall = OpenFOAM | System
123 # We can override the value of compilerInstall from prefs.sh
124 : ${compilerInstall:=System}
126 # Or we can force it right here
127 #compilerInstall=OpenFOAM
128 #compilerInstall=System
130 case "${compilerInstall:-OpenFOAM}" in
131 OpenFOAM)
132 case "$WM_COMPILER" in
133 Gcc)
134 export WM_COMPILER_DIR=$WM_THIRD_PARTY_DIR/gcc-4.3.3/platforms/$WM_ARCH$WM_COMPILER_ARCH
135 _foamAddLib $WM_THIRD_PARTY_DIR/mpfr-2.4.1/platforms/$WM_ARCH$WM_COMPILER_ARCH/lib
136 _foamAddLib $WM_THIRD_PARTY_DIR/gmp-4.2.4/platforms/$WM_ARCH$WM_COMPILER_ARCH/lib
138 Gcc45)
139 export WM_COMPILER_DIR=$WM_THIRD_PARTY_DIR/packages/gcc-4.5.1/platforms/$WM_OPTIONS
140 _foamSource $WM_THIRD_PARTY_DIR/packages/gmp-5.0.1/platforms/$WM_OPTIONS/etc/gmp-5.0.1.sh
141 _foamSource $WM_THIRD_PARTY_DIR/packages/mpfr-3.0.1/platforms/$WM_OPTIONS/etc/mpfr-3.0.1.sh
142 _foamSource $WM_THIRD_PARTY_DIR/packages/mpc-0.8.2/platforms/$WM_OPTIONS/etc/mpc-0.8.2.sh
143 _foamSource $WM_THIRD_PARTY_DIR/packages/gcc-4.5.1/platforms/$WM_OPTIONS/etc/gcc-4.5.1.sh
145 Gcc44)
146 export WM_COMPILER_DIR=$WM_THIRD_PARTY_DIR/packages/gcc-4.4.5/platforms/$WM_OPTIONS
147 _foamSource $WM_THIRD_PARTY_DIR/packages/mpfr-3.0.1/platforms/$WM_OPTIONS/etc/mpfr-3.0.1.sh
148 _foamSource $WM_THIRD_PARTY_DIR/packages/gmp-5.0.1/platforms/$WM_OPTIONS/etc/gmp-5.0.1.sh
149 _foamSource $WM_THIRD_PARTY_DIR/packages/gcc-4.4.5/platforms/$WM_OPTIONS/etc/gcc-4.4.5.sh
151 Gcc43)
152 export WM_COMPILER_DIR=$WM_THIRD_PARTY_DIR/gcc-4.3.3/platforms/$WM_ARCH$WM_COMPILER_ARCH
153 _foamAddLib $WM_THIRD_PARTY_DIR/mpfr-2.4.1/platforms/$WM_ARCH$WM_COMPILER_ARCH/lib
154 _foamAddLib $WM_THIRD_PARTY_DIR/gmp-4.2.4/platforms/$WM_ARCH$WM_COMPILER_ARCH/lib
156 Gcc42)
157 export WM_COMPILER_DIR=$WM_THIRD_PARTY_DIR/gcc-4.2.4/platforms/$WM_ARCH$WM_COMPILER_ARCH
159 esac
161 # Check that the compiler directory can be found
162 if [ ! -d "$WM_COMPILER_DIR" ]
163 then
164 echo
165 echo "Warning in $WM_PROJECT_DIR/etc/settings.sh:"
166 echo " Cannot find $WM_COMPILER_DIR installation."
167 echo " Please install this compiler version or if you wish to use the system compiler,"
168 echo " change the 'compilerInstall' setting to 'System' in this file"
169 echo
172 compilerBin=$WM_COMPILER_DIR/bin
173 compilerLib=$WM_COMPILER_DIR/lib$WM_COMPILER_LIB_ARCH:$WM_COMPILER_DIR/lib
175 esac
177 if [ -d "$compilerBin" ]
178 then
179 _foamAddPath $compilerBin
180 _foamAddLib $compilerLib
183 unset compilerBin compilerLib compilerInstall
186 if [ -z "$WM_CC" ]
187 then
188 case "$WM_COMPILER" in
189 Gcc*)
190 export WM_CC='gcc'
191 export WM_CXX='g++'
193 Icc)
194 export WM_CC='icc'
195 export WM_CXX='icpc'
197 esac
200 # Communications library
201 # ~~~~~~~~~~~~~~~~~~~~~~
203 unset MPI_ARCH_PATH
204 mpi_version=unknown
205 case "$WM_MPLIB" in
206 OPENMPI)
207 if [ -e $WM_THIRD_PARTY_DIR/packages/openmpi-1.6.5/platforms/$WM_OPTIONS ]
208 then
209 mpi_version=openmpi-1.6.5
210 if [ "$FOAM_VERBOSE" -a "$PS1" ]
211 then
212 echo "Using openmpi-1.6.5 from the ThirdParty package: $WM_THIRD_PARTY_DIR/packages/$mpi_version"
214 _foamSource $WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS/etc/$mpi_version.sh
216 elif [ -e $WM_THIRD_PARTY_DIR/packages/openmpi-1.4.3/platforms/$WM_OPTIONS ]
217 then
218 mpi_version=openmpi-1.4.3
219 if [ "$FOAM_VERBOSE" -a "$PS1" ]
220 then
221 echo "Using openmpi-1.4.3 from the ThirdParty package: $WM_THIRD_PARTY_DIR/packages/$mpi_version"
223 _foamSource $WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS/etc/$mpi_version.sh
225 elif [ -e $WM_THIRD_PARTY_DIR/packages/openmpi-1.5/platforms/$WM_OPTIONS ]
226 then
227 mpi_version=openmpi-1.5
228 if [ "$FOAM_VERBOSE" -a "$PS1" ]
229 then
230 echo "Using openmpi-1.5 from the ThirdParty package: $WM_THIRD_PARTY_DIR/packages/$mpi_version"
232 _foamSource $WM_THIRD_PARTY_DIR/packages/$mpi_version/platforms/$WM_OPTIONS/etc/$mpi_version.sh
235 export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/$mpi_version
236 unset mpi_version
239 MACPORTOPENMPI)
240 unset OPAL_PREFIX
242 export FOAM_MPI=openmpi-macport
243 libDir=`openmpicc --showme:link | sed -e 's/.*-L\([^ ]*\).*/\1/'`
245 # Bit of a hack: strip off 'lib' and hope this is the path to openmpi
246 # include files and libraries.
247 export MPI_ARCH_PATH="${libDir%/*}"
249 _foamAddLib $libDir
250 unset libDir
253 SYSTEMOPENMPI)
254 mpi_version=openmpi-system
256 # make sure not the "old" mpi is used
257 # Not sure if this is necessary anymore.
258 # export OPAL_PREFIX=
260 # Make sure OPENMPI_BIN_DIR is set and valid
261 if [ -n "${OPENMPI_BIN_DIR}" ] && [ -d "${OPENMPI_BIN_DIR}" ]
262 then
263 # User defined value specified for OPENMPI_BIN_DIR
265 # WARNING:
266 # We assume this path specified by $OPENMPI_BIN_DIR is valid
267 # We assume the command mpicc is located somewhere under this path
268 # We assume the file mpi.h is located somewhere under this path
270 # Otherwise, please double check your openmpi installation, you are
271 # probably missing the openmpi runtime and/or development packages
272 # available for your system.
274 _foamAddPath $OPENMPI_BIN_DIR
275 else
276 # Here, we assume your environment is already set for running
277 # and developping with openmpi.
279 # Initialize OPENMPI_BIN_DIR using the path to mpicc
280 export OPENMPI_BIN_DIR=$(dirname `which mpicc`)
283 # Make sure OPENMPI_LIB_DIR is set
284 if [ ! -n "${OPENMPI_LIB_DIR}" ]
285 then
286 # Initialize OPENMPI_LIB_DIR using the path to mpicc
287 export OPENMPI_LIB_DIR="`mpicc --showme:libdirs`"
290 # Make sure the dynamic libraries are accessible
291 [ -n "${OPENMPI_LIB_DIR}" ] && _foamAddLib $OPENMPI_LIB_DIR
293 export MPI_HOME=`dirname $OPENMPI_BIN_DIR`
294 export MPI_ARCH_PATH=$MPI_HOME
295 export OPAL_PREFIX=$MPI_ARCH_PATH
297 # We initialize the rest of the environment using mpicc --showme:
298 [ ! -n "${OPENMPI_INCLUDE_DIR}" ] && export OPENMPI_INCLUDE_DIR="`mpicc --showme:incdirs`"
299 [ ! -n "${OPENMPI_COMPILE_FLAGS}" ] && export OPENMPI_COMPILE_FLAGS="`mpicc --showme:compile`"
300 [ ! -n "${OPENMPI_LINK_FLAGS}" ] && export OPENMPI_LINK_FLAGS="`mpicc --showme:link`"
303 # WARNING: We assume the file mpi.h will be available under the directories identified
304 # by the variable $OPENMPI_INCLUDE_DIR. Otherwise, please double check your
305 # system openmpi installation.
307 # Set compilation flags here instead of in wmake/rules/../mplibSYSTEMOPENMPI
308 export PINC="${OPENMPI_COMPILE_FLAGS}"
309 export PLIBS="${OPENMPI_LINK_FLAGS}"
311 # No longer needed, but we keep this as a reference, just in case...
312 #libDir=`echo "$PLIBS" | sed -e 's/.*-L\([^ ]*\).*/\1/'`
313 #_foamAddLib $libDir
315 if [ "$FOAM_VERBOSE" -a "$PS1" ]
316 then
317 echo " Environment variables defined for OpenMPI:"
318 echo " OPENMPI_BIN_DIR : $OPENMPI_BIN_DIR"
319 echo " OPENMPI_LIB_DIR : $OPENMPI_LIB_DIR"
320 echo " OPENMPI_INCLUDE_DIR : $OPENMPI_INCLUDE_DIR"
321 echo " OPENMPI_COMPILE_FLAGS : $OPENMPI_COMPILE_FLAGS"
322 echo " OPENMPI_LINK_FLAGS : $OPENMPI_LINK_FLAGS"
323 echo ""
324 echo " MPI_HOME : $MPI_HOME"
325 echo " MPI_ARCH_PATH : $MPI_ARCH_PATH"
326 echo " OPAL_PREFIX : $OPAL_PREFIX"
327 echo " PINC : $PINC"
328 echo " PLIBS : $PLIBS"
331 export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/$mpi_version
332 unset mpi_version
335 MPICH)
336 mpi_version=mpich-1.2.4
337 export MPI_HOME=$WM_THIRD_PARTY_DIR/$mpi_version
338 export MPI_ARCH_PATH=$MPI_HOME/platforms/$WM_OPTIONS
339 export MPICH_ROOT=$MPI_ARCH_PATH
341 _foamAddPath $MPI_ARCH_PATH/bin
342 _foamAddLib $MPI_ARCH_PATH/lib
344 export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/$mpi_version
345 unset mpi_version
348 MPICH-GM)
349 export MPI_ARCH_PATH=/opt/mpi
350 export MPICH_PATH=$MPI_ARCH_PATH
351 export MPICH_ROOT=$MPI_ARCH_PATH
352 export GM_LIB_PATH=/opt/gm/lib64
354 _foamAddPath $MPI_ARCH_PATH/bin
355 _foamAddLib $MPI_ARCH_PATH/lib
356 _foamAddLib $GM_LIB_PATH
358 export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/mpich-gm
361 HPMPI)
362 export MPI_HOME=/opt/hpmpi
363 export MPI_ARCH_PATH=$MPI_HOME
364 export MPICH_ROOT=$MPI_ARCH_PATH
366 _foamAddPath $MPI_ARCH_PATH/bin
368 case `uname -m` in
369 i686)
370 _foamAddLib $MPI_ARCH_PATH/lib/linux_ia32
373 x86_64)
374 _foamAddLib $MPI_ARCH_PATH/lib/linux_amd64
376 ia64)
377 _foamAddLib $MPI_ARCH_PATH/lib/linux_ia64
380 echo Unknown processor type `uname -m` for Linux
382 esac
384 export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/hpmpi
387 GAMMA)
388 export MPI_ARCH_PATH=/usr
389 export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/gamma
392 MPI)
393 export MPI_ARCH_PATH=/opt/mpi
394 export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/mpi
397 FJMPI)
398 export MPI_ARCH_PATH=/opt/FJSVmpi2
399 export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/mpi
401 _foamAddPath $MPI_ARCH_PATH/bin
402 _foamAddLib $MPI_ARCH_PATH/lib/sparcv9
403 _foamAddLib /opt/FSUNf90/lib/sparcv9
404 _foamAddLib /opt/FJSVpnidt/lib
407 QSMPI)
408 export MPI_ARCH_PATH=/usr/lib/mpi
409 export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/qsmpi
411 _foamAddPath $MPI_ARCH_PATH/bin
412 _foamAddLib $MPI_ARCH_PATH/lib
417 export FOAM_MPI_LIBBIN=$FOAM_LIBBIN/dummy
419 esac
421 _foamAddLib $FOAM_MPI_LIBBIN
424 # Set the minimum MPI buffer size (used by all platforms except SGI MPI)
425 # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
426 minBufferSize=20000000
428 if [ "${MPI_BUFFER_SIZE:=$minBufferSize}" -lt $minBufferSize ]
429 then
430 MPI_BUFFER_SIZE=$minBufferSize
432 export MPI_BUFFER_SIZE
435 # CUDA if available
436 # ~~~~~~~~~~~~~~~~~
437 [ -z "$CUDA_SYSTEM" ] && [ -e /usr/local/cuda-5.5/bin/nvcc ] && {
438 export CUDA_DIR=/usr/local/cuda-5.5
439 export CUDA_BIN_DIR=$CUDA_DIR/bin
440 export CUDA_LIB_DIR=$CUDA_DIR/lib64
441 export CUDA_INCLUDE_DIR=$CUDA_DIR/include
444 [ -d "$CUDA_LIB_DIR" ] && _foamAddPath $CUDA_BIN_DIR && _foamAddLib $CUDA_LIB_DIR
447 # CGAL library if available
448 # ~~~~~~~~~~~~~~~~~~~~~~~~~
449 [ -d "$CGAL_LIB_DIR" ] && _foamAddLib $CGAL_LIB_DIR
452 # Switch on the hoard memory allocator if available
453 # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
454 #if [ -f $FOAM_LIBBIN/libhoard.so ]
455 #then
456 # export LD_PRELOAD=$FOAM_LIBBIN/libhoard.so:$LD_PRELOAD
459 # HOARD seems to crash Paraview on Mac OS X 10.6
460 #if [ -f $FOAM_LIBBIN/libhoard.dylib ]
461 #then
462 # if [ -z "$DYLD_INSERT_LIBRARIES" ]
463 # then
464 # export DYLD_INSERT_LIBRARIES=$FOAM_LIBBIN/libhoard.dylib
465 # else
466 # export DYLD_INSERT_LIBRARIES=$FOAM_LIBBIN/libhoard.dylib:$DYLD_INSERT_LIBRARIES
467 # fi
471 # Third party packages
473 # In order to use a pre-installed version of the ThirdParty packages, just set the
474 # appropriate XXX_SYSTEM environment variable for a given package in your prefs.sh
475 # file in order to disable the sourcing of the ThirdParty version of the same package.
477 # Load Mesquite library
478 # ~~~~~~~~~~~~~~~~~~~~~~
479 [ -z "$MESQUITE_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/mesquite-2.1.2/platforms/$WM_OPTIONS ] && {
480 _foamSource $WM_THIRD_PARTY_DIR/packages/mesquite-2.1.2/platforms/$WM_OPTIONS/etc/mesquite-2.1.2.sh
482 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " MESQUITE_DIR is initialized to: $MESQUITE_DIR"
485 # Load Metis library
486 # ~~~~~~~~~~~~~~~~~~
487 [ -z "$METIS_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/metis-5.1.0/platforms/$WM_OPTIONS ] && {
488 _foamSource $WM_THIRD_PARTY_DIR/packages/metis-5.1.0/platforms/$WM_OPTIONS/etc/metis-5.1.0.sh
490 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " METIS_DIR is initialized to: $METIS_DIR"
493 # Load ParMetis library
494 # ~~~~~~~~~~~~~~~~~~~~~
495 [ -z "$PARMETIS_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/parmetis-4.0.3/platforms/$WM_OPTIONS ] && {
496 _foamSource $WM_THIRD_PARTY_DIR/packages/parmetis-4.0.3/platforms/$WM_OPTIONS/etc/parmetis-4.0.3.sh
498 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " PARMETIS_DIR is initialized to: $PARMETIS_DIR"
501 # Load ParMGridGen library
502 # ~~~~~~~~~~~~~~~~~~~~~~~~~
503 [ -z "$PARMGRIDGEN_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/ParMGridGen-1.0/platforms/$WM_OPTIONS ] && {
504 _foamSource $WM_THIRD_PARTY_DIR/packages/ParMGridGen-1.0/platforms/$WM_OPTIONS/etc/ParMGridGen-1.0.sh
506 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " PARMGR IDGEN_DIR is initialized to: $PARMGRIDGEN_DIR"
509 # Load Libccmio library
510 # ~~~~~~~~~~~~~~~~~~~~~
511 [ -z "$LIBCCMIO_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/libccmio-2.6.1/platforms/$WM_OPTIONS ] && {
512 _foamSource $WM_THIRD_PARTY_DIR/packages/libccmio-2.6.1/platforms/$WM_OPTIONS/etc/libccmio-2.6.1.sh
514 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " LIBCCMIO_DIR is initialized to: $LIBCCMIO_DIR"
517 # Load Scotch library
518 # ~~~~~~~~~~~~~~~~~~~
519 [ -z "$SCOTCH_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/scotch-6.0.0/platforms/$WM_OPTIONS ] && {
520 _foamSource $WM_THIRD_PARTY_DIR/packages/scotch-6.0.0/platforms/$WM_OPTIONS/etc/scotch-6.0.0.sh
522 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " SCOTCH_DIR is initialized to: $SCOTCH_DIR"
525 # Load cmake
526 # ~~~~~~~~~~
527 [ -z "$CMAKE_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/cmake-2.8.12/platforms/$WM_OPTIONS ] && {
528 _foamSource $WM_THIRD_PARTY_DIR/packages/cmake-2.8.12/platforms/$WM_OPTIONS/etc/cmake-2.8.12.sh
530 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " CMAKE_DIR is initialized to: $CMAKE_DIR"
532 # Load m4
533 # ~~~~~~~~~~
534 [ -z "$M4_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/m4-1.4.16/platforms/$WM_OPTIONS ] && {
535 _foamSource $WM_THIRD_PARTY_DIR/packages/m4-1.4.16/platforms/$WM_OPTIONS/etc/m4-1.4.16.sh
537 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " M4_DIR is initialized to: $M4_DIR"
539 # Load bison
540 # ~~~~~~~~~~
541 [ -z "$BISON_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/bison-2.4.3/platforms/$WM_OPTIONS ] && {
542 _foamSource $WM_THIRD_PARTY_DIR/packages/bison-2.4.3/platforms/$WM_OPTIONS/etc/bison-2.4.3.sh
544 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " BISON_DIR is initialized to: $BISON_DIR"
546 # Load flex
547 # ~~~~~~~~~~
548 [ -z "$FLEX_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/flex-2.5.35/platforms/$WM_OPTIONS ] && {
549 _foamSource $WM_THIRD_PARTY_DIR/packages/flex-2.5.35/platforms/$WM_OPTIONS/etc/flex-2.5.35.sh
551 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " FLEX_DIR is initialized to: $FLEX_DIR"
554 # Load zoltan
555 # ~~~~~~~~~~
556 [ -z "$ZOLTAN_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/zoltan_3.5 ] && {
557 _foamSource $WM_THIRD_PARTY_DIR/packages/zoltan_3.5/platforms/$WM_OPTIONS/etc/zoltan_3.5.sh
559 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " ZOLTAN_DIR is initialized to: $ZOLTAN_DIR"
562 # Load Python
563 # ~~~~~~~~~~~
564 [ -z "$PYTHON_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/Python-2.7/platforms/$WM_OPTIONS ] && {
565 _foamSource $WM_THIRD_PARTY_DIR/packages/Python-2.7/platforms/$WM_OPTIONS/etc/Python-2.7.sh
567 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " PYTHON_DIR is initialized to: $PYTHON_DIR"
569 # Load PyFoam
570 # ~~~~~~~~~~~
571 [ -z "$PYFOAM_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/PyFoam-0.6.1/platforms/noarch ] && {
572 _foamSource $WM_THIRD_PARTY_DIR/packages/PyFoam-0.6.1/platforms/noarch/etc/PyFoam-0.6.1.sh
574 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " PYFOAM_DIR is initialized to: $PYFOAM_DIR"
576 # Load hwloc
577 # ~~~~~~~~~~~
578 [ -z "$HWLOC_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/hwloc-1.7.2/platforms/$WM_OPTIONS ] && {
579 _foamSource $WM_THIRD_PARTY_DIR/packages/hwloc-1.7.2/platforms/$WM_OPTIONS/etc/hwloc-1.7.2.sh
581 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " HWLOC_DIR is initialized to: $HWLOC_DIR"
583 # Load QT
584 # ~~~~~~~
585 [ ! -z "$QT_THIRD_PARTY" ] && [ -e $WM_THIRD_PARTY_DIR/packages/qt-everywhere-opensource-src-4.7.4/platforms/$WM_OPTIONS ] && {
586 _foamSource $WM_THIRD_PARTY_DIR/packages/qt-everywhere-opensource-src-4.7.4/platforms/$WM_OPTIONS/etc/qt-everywhere-opensource-src-4.7.4.sh
588 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " QT_DIR is initialized to: $QT_DIR"
591 # Load ParaView
592 # ~~~~~~~~~~~~~
593 [ -z "$PARAVIEW_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/ParaView-3.14.1/platforms/$WM_OPTIONS ] && {
594 _foamSource $WM_THIRD_PARTY_DIR/packages/ParaView-3.14.1/platforms/$WM_OPTIONS/etc/ParaView-3.14.1.sh
595 #[ -z "$PARAVIEW_SYSTEM" ] && [ -e $WM_THIRD_PARTY_DIR/packages/ParaView-3.8.1/platforms/$WM_OPTIONS ] && {
596 # _foamSource $WM_THIRD_PARTY_DIR/packages/ParaView-3.8.1/platforms/$WM_OPTIONS/etc/ParaView-3.8.1.sh
598 [ "$FOAM_VERBOSE" -a "$PS1" ] && echo " PARAVIEW_DIR is initialized to: $PARAVIEW_DIR"
601 # cleanup environment:
602 # ~~~~~~~~~~~~~~~~~~~~
603 unset _foamAddPath _foamAddLib minBufferSize
605 # -----------------------------------------------------------------------------