You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -35,7 +38,9 @@ Furthermore, a Fortran compiler must be installed and discoverable by CMake.
35
38
36
39
NetCDF has been - and maybe still will be a headache - but it is assumed that NetCDF is installed with Fortran support. For Windows we provide a prebuilt set of libraries.
37
40
38
-
Configuration is done with cmake - and example being:
41
+
*As an alternative to use system installed programs (CMake, Ninja, Fortran and required libraries) scroll to the bottom of the page(**) and follow the instructions to create a Conda environment with everything required. Then return and continue from here.*
42
+
43
+
Configuration is done with cmake - an example being:
39
44
```
40
45
cmake -G Ninja -B build -S code
41
46
```
@@ -44,25 +49,25 @@ This will create a new folder - build - with the necessary information for actua
44
49
The build system for GOTM provides support for options to pass to the actual compilation. These are provided as extra arguments to the above cmake execution. As and example to include support for ice - use the following:
45
50
46
51
```
47
-
cmake -B build -S code -DGOTM_USE_STIM
52
+
cmake -G Ninja -B build -S code -DGOTM_USE_STIM
48
53
```
49
-
It is always safe to completely remove the build folder and start all over
54
+
If something goes wrong it is always safe to completely remove the build folder and start all over.
50
55
51
56
#### Compiling the code
52
57
53
58
If the cmake command did not result in any errors we are ready to actually compile the code into an executable:
54
59
```
55
60
cmake --build build
56
61
```
57
-
This will take a little while but should en up in a compiled GOTM executable in the build/folder.
62
+
This will take a little while but should en up in a compiled GOTM executable in the buildfolder.
58
63
This executable is ready to run but for convinience you might install it in a folder in the PATH on your computer - in which case you can just type - gotm - in any folder.
To test if it works open a new terminal window and execute - gotm.
70
+
To test if it works open a new terminal window and execute - *gotm*.
66
71
67
72
#### GOTM test cases
68
73
GOTM comes with a number of ready to run test cases. There are also in a Git repository and can be obtained like:
@@ -74,3 +79,15 @@ Entering any of the cases folders and just executing - gotm - should run the mod
74
79
An older description is provided here [GOTM homepage](http://www.gotm.net/portfolio/software).
75
80
76
81
(*) For people who intend to contribute to the GOTM source code a 'fork' is a better solution.
82
+
83
+
(**) Create a Conda environment.
84
+
If a Conda is not already available install [miniconda](https://www.anaconda.com/docs/getting-started/miniconda/main). Activate the base environment and do (note you must be in the root of the GOTM source code - where the *environment.yml* files is):
85
+
```
86
+
conda env create -f environment.yml
87
+
```
88
+
If successful activate the *gfortran* environment.
89
+
```
90
+
conda activate gfortran
91
+
```
92
+
Return to the configuration instructions give further up.
0 commit comments