Problemy z instalacją pakietu devtools
Chcę skorzystać z pakietu devtools
. Wykonałem następujące polecenia:
> install.packages("devtools", dependencies = TRUE)
....
> library(devtools)
Error in library(devtools) : there is no package called ‘devtools’
Co robię źle?
Edit: oto wyniki ponownego uruchomienia polecenia install.packages
po ponownym uruchomieniu sesji.
> install.packages("devtools", dependencies = TRUE)
Installing package into ‘/home/evanaad/R/x86_64-pc-linux-gnu-library/3.0’
(as ‘lib’ is unspecified)
--- Please select a CRAN mirror for use in this session ---
Warning: dependencies ‘roxygen2’, ‘BiocInstaller’, ‘rstudio’ are not available
also installing the dependencies ‘httr’, ‘RCurl’
trying URL 'http://cran.at.r-project.org/src/contrib/httr_0.2.tar.gz'
Content type 'application/x-gzip' length 50183 bytes (49 Kb)
opened URL
==================================================
downloaded 49 Kb
trying URL 'http://cran.at.r-project.org/src/contrib/RCurl_1.95-4.1.tar.gz'
Content type 'application/x-gzip' length 870915 bytes (850 Kb)
opened URL
==================================================
downloaded 850 Kb
trying URL 'http://cran.at.r-project.org/src/contrib/devtools_1.4.1.tar.gz'
Content type 'application/x-gzip' length 105214 bytes (102 Kb)
opened URL
==================================================
downloaded 102 Kb
* installing *source* package ‘RCurl’ ...
** package ‘RCurl’ successfully unpacked and MD5 sums checked
checking for curl-config... no
Cannot find curl-config
ERROR: configuration failed for package ‘RCurl’
* removing ‘/home/evanaad/R/x86_64-pc-linux-gnu-library/3.0/RCurl’
ERROR: dependency ‘RCurl’ is not available for package ‘httr’
* removing ‘/home/evanaad/R/x86_64-pc-linux-gnu-library/3.0/httr’
ERROR: dependencies ‘httr’, ‘RCurl’ are not available for package ‘devtools’
* removing ‘/home/evanaad/R/x86_64-pc-linux-gnu-library/3.0/devtools’
The downloaded source packages are in
‘/tmp/RtmptvmTrA/downloaded_packages’
Warning messages:
1: In install.packages("devtools", dependencies = TRUE) :
installation of package ‘RCurl’ had non-zero exit status
2: In install.packages("devtools", dependencies = TRUE) :
installation of package ‘httr’ had non-zero exit status
3: In install.packages("devtools", dependencies = TRUE) :
installation of package ‘devtools’ had non-zero exit status
8 answers
Zgodnie z sugestią damienfrancois zainstalowałem libcurl4-gnutls-dev i problem został rozwiązany.
EDIT (@dardisco)
W powłoce:
apt-get -y build-dep libcurl4-gnutls-dev
apt-get -y install libcurl4-gnutls-dev
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/doraprojects.net/template/agent.layouts/content.php on line 54
2017-05-23 11:33:26
Jeśli używasz Ubuntu / Linuksa:
sudo apt-get install libcurl4-openssl-dev libssl-dev
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/doraprojects.net/template/agent.layouts/content.php on line 54
2016-08-01 11:56:49
W przypadku, gdy używasz CentOS:
Try:
sudo yum -y install libcurl libcurl-devel
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/doraprojects.net/template/agent.layouts/content.php on line 54
2014-11-14 20:15:05
Obecnie (ubuntu 14.04) potrzebuję obu:
$ sudo apt-get -y install libcurl4-gnutls-dev
$ sudo apt-get -y install libssl-dev
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/doraprojects.net/template/agent.layouts/content.php on line 54
2016-09-01 04:05:52
Dla użytkowników ubuntu, uruchom to polecenie w terminalu [testowane w UBUNTU 16.04]
sudo apt-get -y install libcurl4-openssl-dev
Opublikuj tę bibliotekę instalacyjną tak, jak zwykle robisz to w R używając
install.packages("package name")
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/doraprojects.net/template/agent.layouts/content.php on line 54
2017-01-03 11:04:08
Do mojego debian Jessie box, dodałem również:
sudo apt-get build-dep libxml2-dev
Hint: Wyjście konsoli r-tool jest dość obszerne, więc sprawdziłbym inne zależności.
W końcu to dostałem:
> find_rtools()
[1] TRUE
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/doraprojects.net/template/agent.layouts/content.php on line 54
2015-06-10 17:26:34
Najlepsze rozwiązanie, aby to rozwiązać. Szukałem tego samego problemu. Spędziłem 1 dzień, a potem dostałem rozwiązanie. Teraz jest dobrze.
Sprawdź swoją wersję R w terminalu bash, jeśli używasz Ubuntu lub Linuksa.
R --version
Następnie użyj tych poleceń
sudo apt-get update
sudo apt-get upgrade
Teraz sprawdź nową wersję R. Użyj tego polecenia
sudo apt-cache showpkg r-base
Teraz zaktualizuj tylko R.
sudo apt-get install r-base
Teraz R zostanie zaktualizowany, a błąd zostanie usunięty. Upewnij się, że cd
ścieżka biblioteki, w której chcesz zainstalować nowy pakiet. W ten sposób w terminalu bash. Spróbuj utworzyć katalog R w folderze domowym lub będzie on domyślnie ustawiony. Zlokalizuj tę lokalizację dla pakietu ~/R/ lib/.
R
.libPaths("~/R/lib")
install.packages("devtools")
Lub
install.packages("devtools", lib="~/R/lib")
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/doraprojects.net/template/agent.layouts/content.php on line 54
2017-07-09 19:20:44
CentOS 7: Miałem już zainstalowane pakiety programistyczne libcurl i gnutls, ale nadal mam "nie można załadować git2r.so" błąd podczas instalacji devtools w R. musiałem "ponownie zainstalować" je, aby działało:
sudo yum reinstall gnutls-devel.x86_64
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/doraprojects.net/template/agent.layouts/content.php on line 54
2016-08-05 19:43:40