From 29bc2d9641ccb7d159afbe821a762c26f8f60882 Mon Sep 17 00:00:00 2001 From: Constantine Khrulev Date: Tue, 17 Sep 2024 10:38:23 -0800 Subject: [PATCH] Improve docs describing how to install YAC --- doc/sphinx/global.txt | 3 +++ doc/sphinx/installation/code/yac.sh | 20 +++++++++++++++++-- doc/sphinx/installation/code/yaxt.sh | 24 ----------------------- doc/sphinx/installation/interpolation.rst | 13 +++--------- 4 files changed, 24 insertions(+), 36 deletions(-) delete mode 100755 doc/sphinx/installation/code/yaxt.sh diff --git a/doc/sphinx/global.txt b/doc/sphinx/global.txt index 61f55683e5..1ad7dfa207 100644 --- a/doc/sphinx/global.txt +++ b/doc/sphinx/global.txt @@ -137,6 +137,9 @@ .. _YAXT: https://dkrz-sw.gitlab-pages.dkrz.de/yaxt/ .. _YAC: https://dkrz-sw.gitlab-pages.dkrz.de/yac/ +.. _libyaml: https://pyyaml.org/wiki/LibYAML +.. _Autoconf: https://www.gnu.org/software/autoconf/ +.. _Automake: https://www.gnu.org/software/automake/ .. CF conventions diff --git a/doc/sphinx/installation/code/yac.sh b/doc/sphinx/installation/code/yac.sh index 86f6129a4a..b8e8cbcfb9 100755 --- a/doc/sphinx/installation/code/yac.sh +++ b/doc/sphinx/installation/code/yac.sh @@ -4,13 +4,29 @@ set -u set -e set -x +rm -rf yaxt rm -rf yac # manual-begin -version=3.3.0 prefix=$HOME/local/yac -git clone -b release-${version} \ +yaxt_version=0.11.2 +git clone -b release-${yaxt_version} \ + https://gitlab.dkrz.de/dkrz-sw/yaxt.git + +cd yaxt + +autoreconf -i + +./configure --prefix=${prefix} \ + --with-pic + +make all && make install + +cd - + +yac_version=3.3.0 +git clone -b release-${yac_version} \ https://gitlab.dkrz.de/dkrz-sw/yac.git cd yac diff --git a/doc/sphinx/installation/code/yaxt.sh b/doc/sphinx/installation/code/yaxt.sh deleted file mode 100755 index d4750eede4..0000000000 --- a/doc/sphinx/installation/code/yaxt.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/bash - -set -u -set -e -set -x - -rm -rf yaxt - -# manual-begin -prefix=$HOME/local/yac -version=0.11.2 - -git clone -b release-${version} \ - https://gitlab.dkrz.de/dkrz-sw/yaxt.git - -cd yaxt - -autoreconf -i - -./configure --prefix=${prefix} \ - --with-pic - -make all && make install -# manual-end diff --git a/doc/sphinx/installation/interpolation.rst b/doc/sphinx/installation/interpolation.rst index 91c2319b69..164d463f5b 100644 --- a/doc/sphinx/installation/interpolation.rst +++ b/doc/sphinx/installation/interpolation.rst @@ -10,19 +10,12 @@ Enabling flexible interpolation using YAC and PROJ PISM's projection-aware interpolation code uses PROJ_\ [#f1]_ to compute *longitude, latitude* coordinates of cell centers and cell corners and YAC_ for the interpolation itself. -YAC depends on YAXT_. Use the following commands to install it: - -.. literalinclude:: code/yaxt.sh - :language: bash - :caption: Building YAXT - :start-after: manual-begin - :end-before: manual-end - -Once this is done, build and install YAC: +YAC depends on YAXT_. Please make sure you have Autoconf_, Automake_, and libyaml_ +installed, then use the following commands to install both YAXT and YAC: .. literalinclude:: code/yac.sh :language: bash - :caption: Building YAC + :caption: Building YAXT and YAC :start-after: manual-begin :end-before: manual-end