icudt error while installing stringi package from r in linux offline

点点圈 提交于 2020-07-09 08:05:38

问题


I have downloaded stringi_1.4.3.tar.gz package in my System (RedHat Linux 7), but when I am trying to install offline it I am getting error as below:

Execution halted *** icudt download failed. stopping. ERROR: configuration failed for package ‘stringi’

This is a new environment RedHatLinux 7.x, R version is 3.6, here I am doing a testing for offline installation of R set up and the R packages, wherein I encountered this error.

I have already tried downloading older version of stringi, but it didn't work.

checking with pkg-config for the system ICU4C... 50.1.2 checking for ICU4C >= 52... no * ICU4C 50.1.2 has been detected Minimal requirements, i.e., ICU4C >= 52, are not met Trying with "standard" fallback flags checking whether we may build an ICU4C-based project... yes checking programmatically for sufficient U_ICU_VERSION_MAJOR_NUM... no * The available ICU4C cannot be used checking whether we may compile src/icu61/common/putil.cpp... yes checking whether we may compile src/icu61/i18n/number_affixutils.cpp... yes checking whether we can fetch icudt... downloading the ICU data library (icudt) output path: icu61/data/icudt61l.zip trying URL 'http://www.ibspan.waw.pl/~gagolews/stringi/icudt61l.zip' Error in download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb"): cannot open URL XXX

trying URL 'https://raw.githubusercontent.com/gagolews/stringi/master/src/icu61/data/icudt61l.zip' Error in download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb"): cannot open URL XXX

trying URL 'https://raw.githubusercontent.com/gagolews/stringi/master/src/icu55/data/icudt61l.zip' Error in download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb"): cannot open URL XXX

trying URL 'http://raw.githubusercontent.com/gagolews/stringi/master/src/icu61/data/icudt61l.zip' Error in download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb"): cannot open URL XXX

trying URL 'http://raw.githubusercontent.com/gagolews/stringi/master/src/icu55/data/icudt61l.zip' Error in download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb"): cannot open URL XXX

trying URL 'http://www.gagolewski.com/software/stringi/icudt61l.zip' Error in download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb"): cannot open URL XXX

icudt download failed Error: Stopping on error In addition: Warning messages: 1: In download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb") : XXX status was 'Couldn't connect to server' 2: In download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb") : URL XXX status was 'Couldn't connect to server' 3: In download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb") : URL XXX status was 'Couldn't connect to server' 4: In download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb") : URL XXX status was 'Couldn't connect to server' 5: In download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb") : URL XXX status was 'Couldn't connect to server' 6: In download.file(paste(href, fname, sep = ""), icudtzipfname, mode = "wb") : URL XXX status was 'Couldn't connect to server' Execution halted *** icudt download failed. stopping. ERROR: configuration failed for package ‘stringi’ * removing ‘/usr/lib64/R/library/stringi’

I downloaded and installed it on windows 10, there ii worked as expected.I want stringi package because it has dependency on other packages.Please Help


回答1:


I was exactly in the same case and just got finally done installing that package. I went to https://cran.r-project.org/web/packages/stringi/INSTALL and scrolled a little bit to find an answer. I'm quoting :

"If you have absolutely no internet access on the machines you try to install stringi on, try fetching the latest development version of the package. It already includes the ICU data archives. You can build a distributable source package that includes all the required ICU data files (for off-line use) by omitting some relevant lines in the .Rbuildignore file. The following command sequence should do the trick:

wget https://github.com/gagolews/stringi/archive/master.zip -O stringi.zip
unzip stringi.zip
sed -i '/\/icu..\/data/d' stringi-master/.Rbuildignore
R CMD build stringi-master

Assuming the most recent development version is 1.3.1, a file named stringi_1.3.1.tar.gz is created in the current working directory. The package can now be installed (the source bundle may be propagated via scp etc.) by executing:

R CMD INSTALL stringi_1.3.1.tar.gz

or by calling install.packages("stringi_1.3.1.tar.gz", repos=NULL), from within an R session."

For the wget part, i just had to download directly from the link and send it to my server and then i got straight to the unzip-ing :)



来源:https://stackoverflow.com/questions/56880786/icudt-error-while-installing-stringi-package-from-r-in-linux-offline

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!