码迷,mamicode.com
首页 > 编程语言 > 详细

CentOS 6 安装R-3.3.2语言支持

时间:2020-07-10 09:33:07      阅读:96      评论:0      收藏:0      [点我收藏+]

标签:libs   https   info   bin   stat   lin   pat   libjpeg   bz2   

###环境变量放前面统一配置

zlib 1.2.5 version

export C_INCLUDE_PATH=/data/zlib/zlib-1.2.5/include:$C_INCLUDE_PATH
export LD_LIBRARY_PATH=/data/zlib/zlib-1.2.5/lib:$LD_LIBRARY_PATH

    # bzip2 1.0.6 version
export C_INCLUDE_PATH=/data/bzip2/bzip2-1.0.6/include:$C_INCLUDE_PATH
export LD_LIBRARY_PATH=/data/bzip2/bzip2-1.0.6/lib:$LD_LIBRARY_PATH
export PATH=/data/bzip2/bzip2-1.0.6/bin:$PATH

    # xz 5.2.4 version
export C_INCLUDE_PATH=/data/xz/xz-5.2.4/include:$C_INCLUDE_PATH
export LD_LIBRARY_PATH=/data/xz/xz-5.2.4/lib:$LD_LIBRARY_PATH
export PATH=/data/xz/xz-5.2.4/bin:$PATH

    # PCRE 8.44 version
export C_INCLUDE_PATH=/data/pcre/pcre-8.44/include:$C_INCLUDE_PATH
export LD_LIBRARY_PATH=/data/pcre/pcre-8.44/lib:$LD_LIBRARY_PATH
export PATH=/data/pcre/pcre-8.44/bin:$PATH

    # curl 7.28.0 version
export C_INCLUDE_PATH=/data/curl/curl-7.28.0/include:$C_INCLUDE_PATH
export LD_LIBRARY_PATH=/data/curl/curl-7.28.0/lib:$LD_LIBRARY_PATH
export PATH=/data/curl/curl-7.28.0/bin:$PATH

export CFLAGS="-fPIC -I/data/bzip2/bzip2-1.0.6/include -I/data/zlib/zlib-1.2.5/include -I/data/xz/xz-5.2.4/include -I/data/pcre/pcre-8.44/include -I/data/curl/curl-7.28.0/include"
export LDFLAGS="-fPIC -L/data/bzip2/bzip2-1.0.6/lib -L/data/zlib/zlib-1.2.5/lib -L/data/xz/xz-5.2.4/lib -L/data/pcre/pcre-8.44/lib -L/data/curl/curl-7.28.0/lib"

安装R语言系统依赖包

yum install gcc-gfortran readline-devel libXt-devel glibc-headers cairo-devel libpng-devel libtiff libjpeg-turbo -y

Install jdk

Configure JAVA_HOME

Error Info: configure: error: No F77 compiler found

yum install gcc-gfortran -y

Error Info: configure: error: --with-readline=yes (default) and headers/libs are not available

yum install readline-devel -y

Error Info: configure: error: --with-x=yes (default) and X11 headers/libs are not available

yum install libXt-devel -y

Error Info:

checking if zlib version >= 1.2.5... no

checking whether zlib support suffices... configure: error: zlib library and headers are required

zlib version >= 1.2.5 required. Compile install zlib-1.2.11

tar xf zlib-1.2.5.tar.gz
cd zlib-1.2.5
./configure --prefix=/data/zlib/zlib-1.2.5
make
make install

Error Info:

checking for BZ2_bzlibVersion in -lbz2... no

checking whether bzip2 support suffices... configure: error: bzip2 library and headers are required

bzip2 version >= 1.0.6 required. Compile install bzip2-1.0.6

tar xf bzip2-1.0.6.tar.gz
cd bzip2-1.0.6
sed -i ‘s#CC=gcc#CC=gcc -fPIC#‘ Makefile
make -f Makefile-libbz2_so 
make
make install PREFIX=/data/bzip2/bzip2-1.0.6
mv libbz2.so.1.0 libbz2.so.1.0.6 /data/bzip2/bzip2-1.0.6/lib/

Error Info:

checking if lzma version >= 5.0.3... no

configure: error: "liblzma library and headers are required"

xz version >= 5.0.3 required. Compile install xz-5.2.4

The offical statement no longer maintains version 5.0

tar xf xz-5.2.4.tar.gz 
cd xz-5.2.4
./configure --prefix=/data/xz/xz-5.2.4
make
make install

Error Info:

checking for pcre_fullinfo in -lpcre... no

checking whether PCRE support suffices... configure: error: pcre >= 8.10 library and headers are required

PCRE version >= 8.10 required. Compile install PCRE-8.44

tar xf pcre-8.44.tar.gz
cd pcre-8.44
./configure --prefix=/data/pcre/pcre-8.44 --enable-utf8
make 
make install

Error Info:

checking for curl/curl.h... no

configure: error: libcurl >= 7.28.0 library and headers are required with support for https

curl version >= 7.28.0 required. Compile install curl-7.28.0

tar xf curl-7.28.0.tar.gz
cd curl-7.28.0
./configure --prefix=/data/curl/curl-7.28.0
make
make install

Install R-3.3.2

tar xf R-3.3.2.tar.gz
cd R-3.3.2
./configure --prefix=/data/R/R-3.3.2 --bindir=/data/R/R-3.3.2/bin --sbindir=/data/R/R-3.3.2/sbin --libdir=/data/R/R-3.3.2/lib --enable-R-shlib
make
make install

Configure environment:
echo "export PATH=/data/R/R-3.3.2/bin:$PATH" >>/etc/profile
echo "/data/R/R-3.3.2/lib" >>/etc/ld.so.conf.d/R.conf
source /etc/profile
ldconfig

CentOS 6 安装R-3.3.2语言支持

标签:libs   https   info   bin   stat   lin   pat   libjpeg   bz2   

原文地址:https://blog.51cto.com/784687488/2509811

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!