Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

install-dependencies-linux.sh 1.2 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
  1. #!/usr/bin/env bash
  2. #
  3. # Bash script to install GMT dependencies on Ubuntu.
  4. #
  5. # Environmental variables that can control the installation:
  6. #
  7. # - BUILD_DOCS: Build GMT documentations [false]
  8. # - RUN_TESTS: Run GMT tests [false]
  9. #
  10. set -x -e
  11. # set defaults to false
  12. BUILD_DOCS="${BUILD_DOCS:-false}"
  13. RUN_TESTS="${RUN_TESTS:-false}"
  14. EXCLUDE_OPTIONAL=${EXCLUDE_OPTIONAL:-false}
  15. # required packages for compiling GMT
  16. packages="build-essential cmake ninja-build libcurl4-gnutls-dev libnetcdf-dev \
  17. ghostscript curl git"
  18. #
  19. if [ "$EXCLUDE_OPTIONAL" = "false" ]; then
  20. packages+=" libgdal-dev libfftw3-dev libpcre3-dev liblapack-dev libglib2.0-dev"
  21. fi
  22. # packages for building documentations
  23. if [ "$BUILD_DOCS" = "true" ]; then
  24. packages+=" python3-pip python3-setuptools python3-wheel graphicsmagick ffmpeg"
  25. fi
  26. # packages for running GMT tests
  27. if [ "$RUN_TESTS" = "true" ]; then
  28. packages+=" graphicsmagick gdal-bin"
  29. fi
  30. # Install packages
  31. sudo apt-get update
  32. sudo apt-get install -y --no-install-recommends --no-install-suggests $packages
  33. # Install more packages for building documentation
  34. if [ "$BUILD_DOCS" = "true" ]; then
  35. sudo snap install pngquant
  36. pip3 install --user sphinx
  37. fi
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...