0

我正在尝试在 GCP 实例上托管 R Shiny 应用程序。使用的包之一是leaflet作为terra依赖项。我似乎无法使用主页上的terra安装说明进行安装。terra

输出cat /proc/version

Linux version 4.19.0-17-cloud-amd64 (debian-kernel@lists.debian.org) (gcc version 8.3.0 (Debian 8.3.0-6)) #1 SMP Debian 4.19.194-2 (2021-06-21)

我可以在安装文本中看到我有以下版本,所有以上terra的要求:

GDAL: 2.4.0
PROJ: 5.2.0
GEOS: 3.7.1

如果我在没有 的情况下运行以下命令,INSTALL_opts = "--no-lock"则会收到错误消息:

sudo Rscript -e 'install.packages("terra", repos="https://rspatial.r-universe.dev")'
ERROR: failed to lock directory ‘/usr/local/lib/R/site-library’ for modifying
Try removing ‘/usr/local/lib/R/site-library/00LOCK-terra’

所以我根据这个相关的 SO question添加了这个论点。

sudo Rscript -e 'install.packages("terra", repos="https://rspatial.r-universe.dev",  INSTALL_opts = "--no-lock")'

但现在安装似乎挂在这部分:

g++ -std=gnu++11 -I"/usr/share/R/include" -DNDEBUG -I/usr/include/gdal -I/usr/include -I"/usr/local/lib/R/site-library/Rcpp/include"    -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-3.5.2=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g -c RcppModule.cpp -o RcppModule.o
4

0 回答 0