0

I am trying to install GLM3r in my mac Pro M1(12.6)

I use this code : devtools::install_github("GLEON/GLM3r", ref = "GLMv.3.1.0a3") and I got this error :

Downloading GitHub repo GLEON/GLM3r@GLMv.3.1.0a3 ── R CMD build ✔ checking for file ‘/private/var/folders/8p/db7_6hmd27b8x9mzg6qh_5k00000gn/T/Rtmp3as7Dn/remotes45c6c103ec1/GLEON-GLM3r-a3c1fa0/DESCRIPTION’ ... ─ preparing ‘GLM3r’: ✔ checking DESCRIPTION meta-information ... ─ checking for LF line-endings in source and make files and shell scripts ─ checking for empty or unneeded directories ─ building ‘GLM3r_3.1.2.tar.gz’

installing source package ‘GLM3r’ ... ** using staged installation ** R ** exec ** inst ** byte-compile and prepare package for lazy loading ** help *** installing help indices ** building package indices ** testing if installed package can be loaded from temporary location ** checking absolute paths in shared objects and dynamic libraries ERROR: some hard-coded temporary paths could not be fixed

removing ‘/Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/library/GLM3r’ Warning message: In i.p(...) : installation of package ‘/var/folders/8p/db7_6hmd27b8x9mzg6qh_5k00000gn/T//Rtmp3as7Dn/file45c1e882854/GLM3r_3.1.2.tar.gz’ had non-zero exit status

I would appreciate it if someone could help me to fix this problem. I don't have any clue how to solve this problem.

1 Answers1

0

I could fix it by setting --no-staged-install parameter.

devtools::install_github("GLEON/GLM3r", ref = "GLMv.3.1.0a3", INSTALL_opts="--no-staged-install")

You can read more about it here: https://blog.r-project.org/2019/02/14/staged-install/index.html

And, here is an example of a similar issue that is fixed by --no-staged-install parameter: hisafer installation - how do I solve hard-coded installation path?

Ehsan Hamzei
  • 339
  • 2
  • 8
  • Thank you .. yes it works for me now .. however I still have problem with glmtools . how did you install glmtools then ? I used both : devtools::install_github("USGS-R/glmtools") and devtools::install_github("USGS-R/glmtools", ref='ggplot_overhaul') but when I execute glm_version().. I dont get response – Faranak Omidi Jun 25 '23 at 07:11
  • I followed their installation method here: https://github.com/GLEON/glmtools/tree/main Even though, it shows build failed in github repo, I was able to install it with # if needed: install.packages('remotes') remotes::install_github('usgs-r/glmtools') I am not sure about these packages, but when I run glm_version() it results in '6' - even runnable before installing glm_tools (so, should be a dependency that is already installed). Maybe, try with a fresh R as there might be some complications with current libraries... – Ehsan Hamzei Jun 25 '23 at 07:23