https://gitlab.opengeosys.org/ogs/ogs.git
Raw File
Tip revision: 3818161cb73576bdb2d499c59de390c962967035 authored by Dmitry Yu. Naumov on 26 January 2023, 17:03:45 UTC
Merge branch 'MultipleSolidMaterials' into 'master'
Tip revision: 3818161
build_petsc.sh
if [ -n "$ZSH_VERSION" ]; then
    DIR=$( cd $(dirname "${(%):-%x}") ; pwd -P )

else
    DIR=$( cd $(dirname "${BASH_SOURCE[0]}") ; pwd -P )
fi

source $DIR/petsc.sh

PETSC_INSTALL=$ALL_PETSC_DIR/$PARTITION_NAME/
mkdir -p $PETSC_INSTALL

cd $ALL_PETSC_DIR
echo "Clone or checkout PETSC (Version: $PETSC_VERSION) to $PETSC_DIR."
git clone --depth 1 --branch $PETSC_VERSION --single-branch https://gitlab.com/petsc/petsc.git $PETSC_DIR || (cd $PETSC_DIR ; git pull)
mkdir -p petsc_$PETSC_VERSION
cd $PETSC_DIR
echo "Build PETSC in $PETSC_DIR started."
./configure --with-cc=gcc --with-cxx=g++ --with-fc=0 --prefix=PETSC_INSTALL --with-debugging=0
make
make PETSC_DIR=$PETSC_DIR PETSC_ARCH=arch-linux-c-opt install
echo "Build PETSC in $PETSC_DIR done."
back to top