GEOquery数据包安装失败,求大神解救

各位大神,我租用的一个服务器,使用ananconda,在安装GEOquery包时出错,求大神支招(曾经安装好并使用过了的,但是重启后就失效了。)

source("http://bioconductor.org/biocLite.R")
Bioconductor version 3.6 (BiocInstaller 1.28.0), ?biocLite for help
A new version of Bioconductor is available after installing the most recent version of R;
see http://bioconductor.org/install
biocLite('GEOquery')
BioC_mirror: https://bioconductor.org
Using Bioconductor 3.6 (BiocInstaller 1.28.0), R 3.4.1 (2017-06-30).
Installing package(s) ‘GEOquery’
also installing the dependency ‘xml2’

trying URL 'https://cran.rstudio.com/src/contrib/xml2_1.2.0.tar.gz'

Content type 'application/x-gzip' length 251614 bytes (245 KB)

downloaded 245 KB

trying URL 'https://bioconductor.org/packages/3.6/bioc/src/contrib/GEOquery_2.46.15.tar.gz'

Content type 'application/x-gzip' length 13717934 bytes (13.1 MB)

downloaded 13.1 MB

  • installing source package ‘xml2’ ... ** package ‘xml2’ successfully unpacked and MD5 sums checked Package libxml-2.0 was not found in the pkg-config search path. Perhaps you should add the directory containing libxml-2.0.pc' to the PKG_CONFIG_PATH environment variable No package 'libxml-2.0' found Package libxml-2.0 was not found in the pkg-config search path. Perhaps you should add the directory containinglibxml-2.0.pc' to the PKG_CONFIG_PATH environment variable No package 'libxml-2.0' found Using PKG_CFLAGS= Using PKG_LIBS=-lxml2 ------------------------- ANTICONF ERROR --------------------------- Configuration failed because libxml-2.0 was not found. Try installing:
    • deb: libxml2-dev (Debian, Ubuntu, etc)
    • rpm: libxml2-devel (Fedora, CentOS, RHEL)
    • csw: libxml2_dev (Solaris) If libxml-2.0 is already installed, check that 'pkg-config' is in your PATH and PKG_CONFIG_PATH contains a libxml-2.0.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 ‘xml2’
  • removing ‘/home/u1366/R/x86_64-pc-linux-gnu-library/3.4/xml2’ ERROR: dependency ‘xml2’ is not available for package ‘GEOquery’
  • removing ‘/home/u1366/R/x86_64-pc-linux-gnu-library/3.4/GEOquery’

https://blog.csdn.net/Joshua_HIT/article/details/57404996

给你两种解决办法仅供参考: 前提是安装libxml***.tar.gz
具体如下:
1、解压:$tar zxvf libxml2-2.9.1.tar.gz
2、进入解压后的安装目录:$cd libxml2-2.9.1
3、安装三部曲:
     1)$./configure
2)$make
3)$make install
如果还不可以,第一种方式:
我们在上面其实已经安装上 libxml2 了的,这里只是一个 环境变量没有设置好而已。

                    解决办法: 确定 /usr/local/libxml2/lib/pkgconfig 目录下有 libxml-2.0.pc

                                export PKG_CONFIG_PATH=/usr/local/libxml2/lib/pkgconfig:$PKG_CONFIG_PATH

                                再次生成 makefile , 这样就成功了

            还不可以试试第二种方式(添加软连接):
                    查找libxml-2.0
                    find / -name libxml-2.0*
                    发现libxml-2.0.pc 在下列位置
                    /usr/local/libxml2/lib/pkgconfig/libxml-2.0.pc

                    找到默认pkgconfig路径
                    find / -name pkgconfig
                    cd /usr/lib64/pkgconfig  发现里面确实没有libxml-2.0.pc

                    增加一个软连接:
                    ln -s   /usr/local/libxml2/lib/pkgconfig/libxml-2.0.pc /usr/lib64/pkgconfig/libxml-2.0.pc