Skip to content

Instantly share code, notes, and snippets.

@remlapmot
Last active August 12, 2022 08:45
Show Gist options
  • Save remlapmot/99bbc668b25249454bbc6fa8e74cac22 to your computer and use it in GitHub Desktop.
Save remlapmot/99bbc668b25249454bbc6fa8e74cac22 to your computer and use it in GitHub Desktop.
Install gmp R package from source on macOS
# Install gmp from source
#
# * brew install gmp # gets latest gmp
# * obtain gmp from here https://mac.r-project.org/libs/ and follow instructions at bottom of page
# For some reason using Sys.setenv() didn't work so copy files from /opt/homebrew/Cellar/gmp/6.2.1_1/ subdirectories
# (include, lib, share) to /usr/local subdirectories
# Sys.setenv(C_INCLUDE_PATH="/opt/homebrew/Cellar/gmp/6.2.1_1/include:/opt/homebrew/Cellar/gmp/6.2.1_1/lib")
install.packages("gmp", type = "source")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment