From eb9090cc90bac15672d6b70851f2eae505f31ca8 Mon Sep 17 00:00:00 2001 From: Miikka Vaisala Date: Mon, 21 Sep 2020 15:19:55 +0800 Subject: [PATCH] Added a helpful template script for running Astaroth simulations. This is has been personally helpful in practical use. --- scripts/my_cmake.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 scripts/my_cmake.sh diff --git a/scripts/my_cmake.sh b/scripts/my_cmake.sh new file mode 100644 index 0000000..528e3f1 --- /dev/null +++ b/scripts/my_cmake.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +# This is a sample script. Please copy it to the directory you want to run the +# code in and customize occordingly. + +# The following write the commit indentifier corresponding to the simulation +# run into a file. This is to help keep track what version of the code was +# used to perform the simulation. + +git rev-parse HEAD > COMMIT_CODE.log + +# Run cmake to construct makefiles +# In the case you compile in astaroth/build/ directory. Otherwise change ".." to +# the correct path to astaroth/CMakeLists.txt + +cmake -DDOUBLE_PRECISION=ON -DDSL_MODULE_DIR=acc/mhd_solver .. + +# Standard compilation + +make -j