La Configuration a échoué car libcurl n'a pas été trouvé
Je suis en train d'essayer de tirer quelques données json à partir d'un serveur distant à l'aide de fromJSON
:
> server <- 'http://111.111.000.00:3000'
> streams <- fromJSON(paste(server, '/output/streams', sep=""), flatten=TRUE)
Résultat:
Error: Required package curl not found.
Please run: install.packages('curl')
J'ai donc essayé de l'installer:
> install.packages("curl")
Installing package into ‘/home/lauxxx/R/x86_64-pc-linux-gnu-library/3.3’
(as ‘lib’ is unspecified)
trying URL 'https://cran.rstudio.com/src/contrib/curl_2.3.tar.gz'
Content type 'application/x-gzip' length 400460 bytes (391 KB)
==================================================
downloaded 391 KB
* installing *source* package ‘curl’ ...
** package ‘curl’ successfully unpacked and MD5 sums checked
Using PKG_CFLAGS=
Using PKG_LIBS=-lcurl
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because libcurl was not found. Try installing:
* deb: libcurl4-openssl-dev (Debian, Ubuntu, etc)
* rpm: libcurl-devel (Fedora, CentOS, RHEL)
* csw: libcurl_dev (Solaris)
If libcurl is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a libcurl.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘curl’
* removing ‘/home/lauxxx/R/x86_64-pc-linux-gnu-library/3.3/curl’
Warning in install.packages :
installation of package ‘curl’ had non-zero exit status
The downloaded source packages are in
‘/tmp/RtmpdoavNf/downloaded_packages’
Puis j'ai essayé d'installer libcurl4-openssl-dev
:
> install.packages("libcurl4-openssl-dev")
Installing package into ‘/home/lau/R/x86_64-pc-linux-gnu-library/3.3’
(as ‘lib’ is unspecified)
Warning in install.packages :
package ‘libcurl4-openssl-dev’ is not available (for R version 3.3.1)
Pourquoi? Ce qui ne va pas? Comment puis-je résoudre ce problème?
C'était ok quand j'étais sur Xubuntu 16.04. Mais maintenant, je suis sur Kubuntu 16.10.
Des idées?
OriginalL'auteur laukok | 2017-02-08
Vous devez vous connecter pour publier un commentaire.
libcurl4-openssl-dev
n'est pas un package R, mais plutôt un linux bibliothèque.Dans un type de console:
Remarque: vous avez besoin sudo pouvoirs.
OriginalL'auteur GGamba
La version de Linux: CentOS Linux 7.3.1611 (Core)
Dans mon cas, j'ai tenté d'installer le package R: devtools
J'ai vérifié
$PATH
, 'pkg-config" a été dans la CHEMIN. Mais il n'y a pas de libcurl.pc fichier dans PKG_CONFIG_PATH (/usr/local/lib/pkgconfig/)
.Voici comment j'ai résolu le problème.
Après cela, j'ai vu libcurl.pc fichier dans PKG_CONFIG_PATH (
/usr/local/lib/pkgconfig/
).OriginalL'auteur user3327344