Last active
November 1, 2019 05:37
-
-
Save ateucher/15d25169a5f60a6dadee8cf912861ee6 to your computer and use it in GitHub Desktop.
Install SAGA GIS on a Mac (2019-10-30)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# If you haven't installed homebrew, see some instructions here: | |
# https://github.com/bcgov/envreportutils/wiki/Macbook-Pro-Setup-for-Data-Science-at-EnvReportBC#homebrew | |
# These have not been tested on macOS Catalina, but the Mojave instructions _should_ work. | |
# If you run into issues, this looks like it might be helpful: | |
# https://medium.com/faun/macos-catalina-xcode-homebrew-gems-developer-headaches-cf7b1edf10b7 | |
# The osgeo homebrew tap is in a bit of a mess, so `brew install saga-gis` doesn't work (as of 2019-10-30). | |
# This is because SAGA dependencies have been updated, but they haven't updated the brew formula for SAGA itself. | |
# Same goes for QGIS; and now that there is a fully self-contained signed installer, I recommend that over heomebrew for QGIS | |
# (https://qgis.org/en/site/forusers/download.html) | |
# The following worked for me for SAGA: | |
# if you have only just installed homebrew or don't have these installed don't run this line: | |
brew unlink osgeo-gdal osgeo-proj osgeo-libspatialite osgeo-gdal-python | |
# Then run: | |
brew install https://raw.githubusercontent.com/OSGeo/homebrew-osgeo4mac/f6e7b27c7485afbdc5a8d9844231fd2e64f02659/Formula/osgeo-gdal.rb | |
brew install https://raw.githubusercontent.com/OSGeo/homebrew-osgeo4mac/b37f82142e347c293cf0b7992f6187d40116b2ca/Formula/osgeo-proj.rb | |
brew install https://raw.githubusercontent.com/OSGeo/homebrew-osgeo4mac/27f4ac2bc4056750307cee1b7a6abb9e33c846dd/Formula/osgeo-libspatialite.rb | |
brew install https://raw.githubusercontent.com/OSGeo/homebrew-osgeo4mac/de5db18027bc37cd3bb0d4be07f59fdc8fe55df9/Formula/osgeo-gdal-python.rb | |
brew install saga-gis --with-app | |
# The SAGA command-line tools will be installed, and the GUI will too at: /usr/local/opt/osgeo-saga/ | |
# You can make the SAGA GUI available in your Applications folder by running: | |
ln -Fs `find $(brew --prefix) -name "SAGA.app"` /Applications/SAGA.app | |
# In R, RSAGA::rsaga.env() was able to find the SAGA installation, so that seems like a good sign! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks @j-krogh... I'm not sure if you would have got this far without it, but just to be sure, do you have XCode command-line tools installed (
xcode-select --install
)? And/or tryxcode-select --reset
as suggested here?