【发布时间】:2019-04-05 04:01:42
【问题描述】:
在尝试安装 warbleR 软件包时,我不断收到以下错误消息:
> install.packages("warbleR")
also installing the dependency ‘bioacoustics’
There is a binary version available but the source version is later:
binary source needs_compilation
warbleR 1.1.14 1.1.15 FALSE
Package which is only available in source form, and may need compilation of C/C++/Fortran:
‘bioacoustics’
Do you want to attempt to install these from sources? (Yes/no/cancel) Yes
installing the source packages ‘bioacoustics’, ‘warbleR’
trying URL 'https://cran.rstudio.com/src/contrib/bioacoustics_0.1.5.tar.gz'
Content type 'application/x-gzip' length 834645 bytes (815 KB)
==================================================
downloaded 815 KB
trying URL 'https://cran.rstudio.com/src/contrib/warbleR_1.1.15.tar.gz'
Content type 'application/x-gzip' length 2348150 bytes (2.2 MB)
==================================================
downloaded 2.2 MB
* installing *source* package ‘bioacoustics’ ...
** package ‘bioacoustics’ successfully unpacked and MD5 sums checked
checking for gcc... clang
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether clang accepts -g... yes
checking for clang option to accept ISO C89... none needed
checking whether we are using the GNU C++ compiler... yes
checking whether clang++ -std=gnu++11 accepts -g... yes
configure: CXX: clang++ -std=gnu++11
checking for cmake... not found
configure: error: Could not find cmake
ERROR: configuration failed for package ‘bioacoustics’
* removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/bioacoustics’
Warning in install.packages :
installation of package ‘bioacoustics’ had non-zero exit status
ERROR: dependency ‘bioacoustics’ is not available for package ‘warbleR’
* removing ‘/Library/Frameworks/R.framework/Versions/3.5/Resources/library/warbleR’
Warning in install.packages :
installation of package ‘warbleR’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/z9/6d_1kkxd0jxcj0r88hng7crm0000gn/T/RtmpSUXFDU/downloaded_packages’
>
【问题讨论】:
-
您是否尝试过对问题回答“否”?
-
是的,但是 R 仍然为包返回非零退出状态。
-
你能告诉我们当你说“不”时打印的完整输出吗?
-
我认为关键错误(在您的原始问题中)是
checking whether the C compiler works... no。您似乎使用的是 OSX,所以终端中的xcode-select --install可能会有所帮助。 -
新的错误表明你没有
cmake。您可以尝试使用 .dmg from this site 安装它,或者如果您是自制软件用户,请使用brew install cmake。
标签: r macos rstudio install.packages