Skip to content

Commit 629cf95

Browse files
authored
Add instructions on how to compile udunits from source (#329)
📝 Add instructions on how to compile udunits from source
1 parent 582cea7 commit 629cf95

1 file changed

Lines changed: 19 additions & 0 deletions

File tree

docs/src/user-guide/installation.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,25 @@ You will need [`uv`](https://docs.astral.sh/uv/getting-started/installation/) to
2020
export UDUNITS2_LIBDIR=/projects/u6iz/public/shared/udunits/lib/
2121
```
2222

23+
Alternatively, if you prefer to compile `udunits` yourself, you can do the following:
24+
25+
```bash
26+
mkdir -p $HOME/software/src
27+
cd $HOME/software/src
28+
29+
curl -L -o udunits-2.2.28.tar.gz https://downloads.unidata.ucar.edu/udunits/2.2.28/udunits-2.2.28.tar.gz
30+
tar -xzf udunits-2.2.28.tar.gz
31+
cd udunits-2.2.28
32+
33+
./configure --prefix=$HOME/software/udunits-2.2.28
34+
make -j4
35+
make install
36+
37+
export UDUNITS2_XML_PATH=$HOME/software/udunits-2.2.28/share/udunits/udunits2.xml
38+
export UDUNITS2_INCDIR=$HOME/software/udunits-2.2.28/include
39+
export UDUNITS2_LIBDIR=$HOME/software/udunits-2.2.28/lib
40+
```
41+
2342
Clone the repository and install with `uv`:
2443

2544
```bash

0 commit comments

Comments
 (0)