gpt4 book ai didi

r - stringi 软件包不会在 CentOS 中安装

转载 作者:行者123 更新时间:2023-12-04 03:15:57 24 4
gpt4 key购买 nike

我正在尝试在 R 中安装 stringi 包,但安装从未完成。下载并编译后,我收到以下消息:

Error in dyn.load(file, DLLpath = DLLpath, ...) :
unable to load shared object '/home/marcus/R/x86_64-redhat-linux-gnu-library/3.3/stringi/libs/stringi.so':
/lib64/libstdc++.so.6: version `CXXABI_1.3.8' not found (required by /home/marcus/R/x86_64-redhat-linux-gnu-library/3.3/stringi/libs/stringi.so)
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/home/marcus/R/x86_64-redhat-linux-gnu-library/3.3/stringi’

The downloaded source packages are in
‘/tmp/RtmpT5KQVP/downloaded_packages’
Warning message:
In install.packages("stringi") :
installation of package ‘stringi’ had non-zero exit status

我在互联网上搜索过,但无法理解此错误消息的含义。如果有帮助,这是我的 sessionInfo():

R version 3.3.1 (2016-06-21)
Platform: x86_64-redhat-linux-gnu (64-bit)
Running under: CentOS Linux 7 (Core)

locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C
[3] LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8
[7] LC_PAPER=en_US.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

attached base packages:
[1] stats graphics grDevices utils datasets methods base

loaded via a namespace (and not attached):
[1] tools_3.3.1

最佳答案

我在安装 gcc 4.9.2 时解决了我的问题。为此,我跑了

$ sudo yum install devtoolset-3-gcc-c++
$ sudo yum install devtoolset-3-gcc-gfortran
$ scl enable devtoolset-3 bash

在外壳中。前两个命令安装 gccgfortran。最后一个使gcc 4.9.2成为系统中的标准编译器。之后,我打开 R 并运行 install.packages("stringi") 来解决我的问题。

关于r - stringi 软件包不会在 CentOS 中安装,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40965895/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com