mojave上的R Studio软件包具有“非零退出状态”

问题描述 投票:1回答:3

我已经有一段时间没有使用R了。现在,我需要再次使用它,与此同时,我已更新到mac os mojave。同样,生物导体显然在其装置中切换了某些东西,我们现在必须使用生物垃圾焚烧炉代替生物硅溶胶。无论如何,我遇到了几个安装错误,不知道该怎么办。我只是下载了xcode,希望这是问题所在,但仍然出现以下错误:

> library(DESeq2)
Fehler: package or namespace load failed for ‘DESeq2’ in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]):
 es gibt kein Paket namens ‘Hmisc’
> install.packages("Hmisc")
also installing the dependencies ‘acepack’, ‘data.table’

Warning in install.packages :
  unable to access index for repository https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6:
  kann URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/PACKAGES' nicht öffnen
Packages which are only available in source form, and may need compilation
  of C/C++/Fortran: ‘acepack’ ‘data.table’ ‘Hmisc’
Do you want to attempt to install these from sources? (Yes/no/cancel) yes
installing the source packages ‘acepack’, ‘data.table’, ‘Hmisc’

versuche URL 'https://cran.rstudio.com/src/contrib/acepack_1.4.1.tar.gz'
Content type 'application/x-gzip' length 34848 bytes (34 KB)
==================================================
downloaded 34 KB

versuche URL 'https://cran.rstudio.com/src/contrib/data.table_1.12.8.tar.gz'
Content type 'application/x-gzip' length 4948391 bytes (4.7 MB)
==================================================
downloaded 4.7 MB

versuche URL 'https://cran.rstudio.com/src/contrib/Hmisc_4.4-0.tar.gz'
Content type 'application/x-gzip' length 744545 bytes (727 KB)
==================================================
downloaded 727 KB

* installing *source* package ‘acepack’ ...
** Paket ‘acepack’ erfolgreich entpackt und MD5 Summen überprüft
** using staged installation
** libs
gfortran  -fPIC  -Wall -g -O2  -c ace.f -o ace.o
make: gfortran: No such file or directory
make: *** [ace.o] Error 1
ERROR: compilation failed for package ‘acepack’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/acepack’
Warning in install.packages :
  installation of package ‘acepack’ had non-zero exit status
* installing *source* package ‘data.table’ ...
** Paket ‘data.table’ erfolgreich entpackt und MD5 Summen überprüft
** using staged installation
zlib 1.2.8 is available ok
** libs
clang -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -I/usr/local/include -fopenmp -fPIC  -Wall -g -O2  -c assign.c -o assign.o
clang: error: unsupported option '-fopenmp'
make: *** [assign.o] Error 1
ERROR: compilation failed for package ‘data.table’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/data.table’
Warning in install.packages :
  installation of package ‘data.table’ had non-zero exit status
ERROR: dependencies ‘acepack’, ‘data.table’ are not available for package ‘Hmisc’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/Hmisc’
Warning in install.packages :
  installation of package ‘Hmisc’ had non-zero exit status

The downloaded source packages are in
    ‘/private/var/folders/7y/tklmw3f51rz8292j144_70680000gn/T/RtmpacLY8N/downloaded_packages’

有人可以帮忙吗?预先谢谢!

r macos rstudio macos-mojave bioconductor
3个回答
2
投票

我在笔记本电脑上运行Mojave,并且能够使用this guide使工作正常。

请尝试遵循该指南中的步骤。

但是,我没有使用最新的OS,因此我不得不使用略有不同的Makevars文件。

这是我的~/.R/Makevars文件的内容。

CFLAGS=-isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk
CCFLAGS=-isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk
CXXFLAGS=-isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk
CPPFLAGS=-isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -I/usr/local/include

CXX14 = /usr/local/clang7/bin/clang++ -stdlib=libc++ -nostdinc++ -I/usr/local/clang7/include/c++/v1
SHLIB_CXX14LD = /usr/local/clang7/bin/clang++ -L/usr/local/clang7/lib

FLIBS=""
F77="/usr/local/gfortran/bin/gfortran"
FC="/usr/local/gfortran/bin/gfortran"

1
投票

尝试转到R首选项>程序包,然后取消选中“对HTTP使用安全下载方法”,这似乎是无法打开URL的默认参数。


0
投票

已修复!

我可以在终端中输入以下内容来解决问题:

brew update && brew reinstall r
© www.soinside.com 2019 - 2024. All rights reserved.