本文介绍了无法在R 3.0.2和Debian wheezy 7.3上安装RJSONIO的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 限时删除!! 我是R新手。 我刚成功安装R,根据 http://cran.r-project.org/bin/linux/debian/README.html 目标操作系统是Debian wheezy 7.3。 然后我成功安装了RStudio。 然后我尝试按照以下页面安装RHadoop所需的软件包。 http:/ /bighadoop.wordpress.com/2013/02/25/r-and-hadoop-data-analysis-rhadoop/ 唯一的区别是我使用较新的版本号来安装软件包。详细步骤如下: $ b R CMD INSTALL Rcpp_0.10.6.tar.gz R CMD INSTALL stringr_0.6.2.tar.gz R CMD INSTALL plyr_1。 8.tar.gz R CMD INSTALL functional_0.4.tar.gz R CMD INSTALL digest_0.6.4.tar.gz 但在下面的步骤失败: R CMD check RJSONIO_1.0-3.tar.gz rlibjson.c:在函数'R_json_stream_parse'中: rlibjson.c:449:5:warning:从不兼容的指针类型[默认启用]传递'json_new_stream'的参数1 在Rlibjson.h包含的文件中:1:0,r中的 libjson.c:1: ./libjson/libjson.h:68:18:note:expected'json_stream_callback_t'but argument is of type'void(*)(void *)' rlibjson.c :449:5:错误:函数'json_new_stream'的参数太少 我的gcc版本是gcc 4.7.2版本(Debian 4.7。 2-5)。是否有任何建议? 谢谢。 解决方案我解决了这个问题: #locate libjson.h /usr/include/libjson/libjson.h /usr/local/include/libjson/libjson.h #tar zcvf libjson.h.tar.gz /usr/include/libjson/libjson.h /usr/local/include/libjson/libjson.h #rm /usr/include/libjson/libjson.h /usr/local/include/libjson/libjson.h #R CMD check RJSONIO_1.0-3.tar.gz 完成 然后将libjson.h替换为它应该在的位置。 似乎libjson.h已经与RJSONIO存在冲突。 谢谢。 I'm newbie to R.I just successfully installed R according tohttp://cran.r-project.org/bin/linux/debian/README.htmlThe target OS is Debian wheezy 7.3.Then I successfully installed RStudio.Then I tried to install packages needed for RHadoop according to following page.http://bighadoop.wordpress.com/2013/02/25/r-and-hadoop-data-analysis-rhadoop/The only difference is that I installed packages with newer version numbers.The detail steps are:R CMD INSTALL Rcpp_0.10.6.tar.gzR CMD INSTALL stringr_0.6.2.tar.gzR CMD INSTALL plyr_1.8.tar.gzR CMD INSTALL functional_0.4.tar.gzR CMD INSTALL digest_0.6.4.tar.gzBut failed at the following step:R CMD check RJSONIO_1.0-3.tar.gzrlibjson.c: In function 'R_json_stream_parse':rlibjson.c:449:5: warning: passing argument 1 of 'json_new_stream' from incompatible pointer type [enabled by default]In file included from Rlibjson.h:1:0, from rlibjson.c:1:./libjson/libjson.h:68:18: note: expected 'json_stream_callback_t' but argument is of type 'void (*)(void *)'rlibjson.c:449:5: error: too few arguments to function 'json_new_stream'My gcc version is gcc version 4.7.2 (Debian 4.7.2-5).Is there any suggestions?Thanks. 解决方案 I solved this problem:# locate libjson.h/usr/include/libjson/libjson.h/usr/local/include/libjson/libjson.h# tar zcvf libjson.h.tar.gz /usr/include/libjson/libjson.h /usr/local/include/libjson/libjson.h# rm /usr/include/libjson/libjson.h /usr/local/include/libjson/libjson.h# R CMD check RJSONIO_1.0-3.tar.gzDoneThen replace libjson.h to where it should be.It seems that libjson.h that already exists conflicts with RJSONIO.Thanks. 这篇关于无法在R 3.0.2和Debian wheezy 7.3上安装RJSONIO的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 1403页,肝出来的..
09-09 02:05