DAMASK_EICMD/build_FEM.sh

52 lines
1.5 KiB
Bash
Raw Normal View History

#!/bin/bash
cat README
echo
echo "Building FEM solver with ${FC}"
DAMASKVERSION=$(cat VERSION)
# prepare building directory
# structure:
# BUILD_DIR
# |-BUILD_SPECTRAL
# |-BUILD_FEM
# |-BUILD_MARC
if [ ! -d build ]; then
mkdir build
fi
cd build
2016-03-06 03:01:33 +05:30
if [ -d FEM ] ; then
rm -rf FEM
fi
mkdir FEM
cd FEM
##
# CMake call
# PETSC_DIR | PETSC directory
# DAMASK_V | DAMASK current revision
# CMAKE_BUILD_TYPE | Default set to release (no debugging output)
2016-04-16 01:56:43 +05:30
# CMAKE_VERBOSE_MAKEFILE | [ON/OFF] toggle makefile verbose output
# OPENMP | [ON/OFF]
# OPTIMIZATION | [OFF,DEFENSIVE,AGGRESSIVE,ULTRA]
# DAMASK_DRIVER | [SPECTRAL, FEM]
# DAMASK_INSTALL | Directory to install binary output
# INSTALL_PROCESSING | Build supporting pre/post processing scripts
cmake -D PETSC_DIR=${PETSC_DIR} \
-D DAMASK_V=${DAMASKVERSION} \
-D CMAKE_BUILD_TYPE=RELEASE \
2016-04-16 01:56:43 +05:30
-D CMAKE_VERBOSE_MAKEFILE=OFF \
-D OPENMP=ON \
-D OPTIMIZATION=DEFENSIVE \
-D DAMASK_DRIVER=FEM \
-D DAMASK_INSTALL=${HOME}/bin \
2016-04-16 01:56:43 +05:30
-D DAMASK_PREFIX="" \
-D DAMASK_SUFFIX="-Wl,--verbose" \
../..
echo
echo "Please move to the build directory using"
2016-03-06 03:01:33 +05:30
echo " cd build/FEM"
echo "Using the following command to build DAMASK spectral solver"
echo " make clean all install"