Skip to content

Commit

Permalink
Merge pull request #31 from aurora-multiphysics/minor-improvements
Browse files Browse the repository at this point in the history
Minor improvements
  • Loading branch information
rweardley authored Dec 5, 2023
2 parents 7cf7ec0 + 1ace0a9 commit 11753ca
Show file tree
Hide file tree
Showing 5 changed files with 56 additions and 46 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/c-cpp-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,5 @@ jobs:
- uses: actions/checkout@v3
- name: Ubuntu based build
run: ./scripts/install_ubuntu.sh
- name: Source MOOSE profile and run tests
run: source $HOME/.moose_profile; ./run_tests
- name: Source Proteus profile and run tests
run: source $HOME/.proteus_profile; ./run_tests
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ and are comfortable with what it is doing.
Once Proteus is built using this script,
you can use Proteus to run an input file as follows:
```
source ~/.moose_profile
source ~/.proteus_profile
proteus-opt -i <input-file>.i
```

Expand Down Expand Up @@ -81,7 +81,7 @@ Contributors
Aleksander J. Dubas,
UK Atomic Energy Authority

Rupert W. Eardley,
Rupert W. Eardley-Brunt,
UK Atomic Energy Authority

Luke Humphrey,
Expand Down
34 changes: 17 additions & 17 deletions scripts/install_csd3.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,29 +3,29 @@
# This script installs Proteus on CSD3,
# including a MOOSE framework build in the $HOME directory.
# Optimised to the native system architecture on the cclake partition.
# A .moose_profile script is added to the $HOME directory.
# A .proteus_profile script is added to the $HOME directory.
# This script is intended to be used from the proteus directory
# ./scripts/install_csd3.sh
# Use the installation by typing:
# source $HOME/.moose_profile
# source $HOME/.proteus_profile

export PROTEUS_DIR=`pwd`

# Make MOOSE profile

echo "module purge" > $HOME/.moose_profile
echo "module load dot slurm rhel7/global" >> $HOME/.moose_profile
echo "module load git-2.31.0-gcc-5.4.0-ec3ji34 python/3.8 gcc/9 openmpi/gcc/9.3/4.0.4" >> $HOME/.moose_profile
echo "export CC=mpicc" >> $HOME/.moose_profile
echo "export CXX=mpicxx" >> $HOME/.moose_profile
echo "export F90=mpif90" >> $HOME/.moose_profile
echo "export F77=mpif77" >> $HOME/.moose_profile
echo "export FC=mpif90" >> $HOME/.moose_profile
echo "export MOOSE_DIR="$HOME"/moose" >> $HOME/.moose_profile
echo "export PATH=\$PATH:"$PROTEUS_DIR >> $HOME/.moose_profile
echo "export PATH=\$MOOSE_DIR/petsc/arch-moose/bin/:\$PATH" >> $HOME/.moose_profile
echo "export OMPI_MCA_mca_base_component_show_load_errors=0" >> $HOME/.moose_profile
source $HOME/.moose_profile
# Make Proteus profile

echo "module purge" > $HOME/.proteus_profile
echo "module load dot slurm rhel7/global" >> $HOME/.proteus_profile
echo "module load git-2.31.0-gcc-5.4.0-ec3ji34 python/3.8 gcc/9 openmpi/gcc/9.3/4.0.4" >> $HOME/.proteus_profile
echo "export CC=mpicc" >> $HOME/.proteus_profile
echo "export CXX=mpicxx" >> $HOME/.proteus_profile
echo "export F90=mpif90" >> $HOME/.proteus_profile
echo "export F77=mpif77" >> $HOME/.proteus_profile
echo "export FC=mpif90" >> $HOME/.proteus_profile
echo "export MOOSE_DIR="$HOME"/moose" >> $HOME/.proteus_profile
echo "export PATH=\$PATH:"$PROTEUS_DIR >> $HOME/.proteus_profile
echo "export PATH=\$MOOSE_DIR/petsc/arch-moose/bin/:\$PATH" >> $HOME/.proteus_profile
echo "export OMPI_MCA_mca_base_component_show_load_errors=0" >> $HOME/.proteus_profile
source $HOME/.proteus_profile

# Clone MOOSE from git

Expand Down
31 changes: 18 additions & 13 deletions scripts/install_fedora.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,19 @@
# This script installs Proteus on Fedora,
# including a MOOSE framework build in the $HOME directory.
# Optimised to the native system architecture.
# A .moose_profile script is added to the $HOME directory.
# A .proteus_profile script is added to the $HOME directory.
# This script is intended to be used from the proteus directory
# ./scripts/install_fedora.sh
# Use the installation by typing:
# source $HOME/.moose_profile
# source $HOME/.proteus_profile

export PROTEUS_DIR=`pwd`

# If MOOSE_JOBS is unset, set to 1
if [ -z $MOOSE_JOBS ]; then
export MOOSE_JOBS=1
fi

# Install pre-requisites

sudo dnf install gcc gcc-c++ gcc-fortran cmake bison flex git
Expand All @@ -19,17 +24,17 @@ sudo dnf install openmpi openmpi-devel
sudo dnf install libtirpc-devel zlib-devel
sudo dnf install perl-File-Compare

# Make MOOSE profile
# Make Proteus profile

echo "export CC=mpicc" > $HOME/.moose_profile
echo "export CXX=mpicxx" >> $HOME/.moose_profile
echo "export F90=mpif90" >> $HOME/.moose_profile
echo "export F77=mpif77" >> $HOME/.moose_profile
echo "export FC=mpif90" >> $HOME/.moose_profile
echo "export MOOSE_DIR="$HOME"/moose" >> $HOME/.moose_profile
echo "export PATH=\$PATH:"$PROTEUS_DIR >> $HOME/.moose_profile
echo "module load mpi/openmpi" >> $HOME/.moose_profile
source $HOME/.moose_profile
echo "export CC=mpicc" > $HOME/.proteus_profile
echo "export CXX=mpicxx" >> $HOME/.proteus_profile
echo "export F90=mpif90" >> $HOME/.proteus_profile
echo "export F77=mpif77" >> $HOME/.proteus_profile
echo "export FC=mpif90" >> $HOME/.proteus_profile
echo "export MOOSE_DIR="$HOME"/moose" >> $HOME/.proteus_profile
echo "export PATH=\$PATH:"$PROTEUS_DIR >> $HOME/.proteus_profile
echo "module load mpi/openmpi" >> $HOME/.proteus_profile
source $HOME/.proteus_profile

# Clone MOOSE from git

Expand Down Expand Up @@ -63,6 +68,6 @@ METHODS="opt" ./scripts/update_and_rebuild_libmesh.sh --with-mpi
./configure --with-derivative-size=81

cd $PROTEUS_DIR
make
make -j $MOOSE_JOBS

echo "Installation complete."
29 changes: 17 additions & 12 deletions scripts/install_ubuntu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,35 @@
# This script installs Proteus on Ubuntu,
# including a MOOSE framework build in the $HOME directory.
# Optimised to the native system architecture.
# A .moose_profile script is added to the $HOME directory.
# A .proteus_profile script is added to the $HOME directory.
# This script is intended to be used from the proteus directory
# ./scripts/install_ubuntu.sh
# Use the installation by typing:
# source $HOME/.moose_profile
# source $HOME/.proteus_profile

export PROTEUS_DIR=`pwd`

# If MOOSE_JOBS is unset, set to 1
if [ -z $MOOSE_JOBS ]; then
export MOOSE_JOBS=1
fi

# Install pre-requisites

sudo apt install -y gcc g++ gfortran cmake bison flex git
sudo apt install -y python3 python3-dev python-is-python3 python3-packaging
sudo apt install -y openmpi-bin libopenmpi-dev libboost-all-dev

# Make MOOSE profile
# Make Proteus profile

echo "export CC=mpicc" > $HOME/.moose_profile
echo "export CXX=mpicxx" >> $HOME/.moose_profile
echo "export F90=mpif90" >> $HOME/.moose_profile
echo "export F77=mpif77" >> $HOME/.moose_profile
echo "export FC=mpif90" >> $HOME/.moose_profile
echo "export MOOSE_DIR="$HOME"/moose" >> $HOME/.moose_profile
echo "export PATH=\$PATH:"$PROTEUS_DIR >> $HOME/.moose_profile
source $HOME/.moose_profile
echo "export CC=mpicc" > $HOME/.proteus_profile
echo "export CXX=mpicxx" >> $HOME/.proteus_profile
echo "export F90=mpif90" >> $HOME/.proteus_profile
echo "export F77=mpif77" >> $HOME/.proteus_profile
echo "export FC=mpif90" >> $HOME/.proteus_profile
echo "export MOOSE_DIR="$HOME"/moose" >> $HOME/.proteus_profile
echo "export PATH=\$PATH:"$PROTEUS_DIR >> $HOME/.proteus_profile
source $HOME/.proteus_profile

# Clone MOOSE from git

Expand Down Expand Up @@ -60,6 +65,6 @@ METHODS="opt" ./scripts/update_and_rebuild_libmesh.sh --with-mpi
./configure --with-derivative-size=81

cd $PROTEUS_DIR
make
make -j $MOOSE_JOBS

echo "Installation complete."

0 comments on commit 11753ca

Please sign in to comment.