zoukankan      html  css  js  c++  java
  • configure: error: Cannot find cairo.h! Please install cairo (http://www.cairographics.org/) and/or set CAIRO_CFLAGS/LIBS correspondingly

    1、问题

    install.packages('Cairo', repos='https://mirror.lzu.edu.cn/CRAN/')
    …………
    …………
    configure: error: Cannot find cairo.h! Please install cairo (http://www.cairographics.org/) and/or set CAIRO_CFLAGS/LIBS correspondingly.
    ERROR: configuration failed for package ‘Cairo’
    * removing ‘/home/software/R/lib64/R/library/Cairo’
    
    The downloaded source packages are in/tmp/RtmpaXjXEm/downloaded_packages’
    Updating HTML index of packages in '.Library'
    Making 'packages.html' ... done
    Warning message:
    In install.packages("Cairo", repos = "https://mirror.lzu.edu.cn/CRAN/") :
      installation of package ‘Cairo’ had non-zero exit status

    2、解决方法

    > quit()
    Save workspace image? [y/n/c]: n

    3、

    [root@centos8 ~]# yum  install cairo* libxt*
    …………
    …………
    Upgraded:
      freetype-2.9.1-4.el8_3.1.x86_64             iptables-1.8.4-15.el8_3.3.x86_64       iptables-ebtables-1.8.4-15.el8_3.3.x86_64
      iptables-libs-1.8.4-15.el8_3.3.x86_64
    
    Installed:
      cairo-devel-1.15.12-3.el8.x86_64           cairo-gobject-devel-1.15.12-3.el8.x86_64       expat-devel-2.2.5-4.el8.x86_64
      fontconfig-devel-2.13.1-3.el8.x86_64       freetype-devel-2.9.1-4.el8_3.1.x86_64          glib2-devel-2.56.4-8.el8.x86_64
      libXext-devel-1.3.4-1.el8.x86_64           libXrender-devel-0.9.10-7.el8.x86_64           libpng-devel-2:1.6.34-5.el8.x86_64
      libuuid-devel-2.32.1-24.el8.x86_64         pcre-cpp-8.42-4.el8.x86_64                     pcre-devel-8.42-4.el8.x86_64
      pcre-utf16-8.42-4.el8.x86_64               pcre-utf32-8.42-4.el8.x86_64                   pixman-devel-0.38.4-1.el8.x86_64
    
    Complete!

    4、

    [root@centos8 ~]# R
    
    R version 4.0.3 (2020-10-10) -- "Bunny-Wunnies Freak Out"
    Copyright (C) 2020 The R Foundation for Statistical Computing
    Platform: x86_64-pc-linux-gnu (64-bit)
    
    R is free software and comes with ABSOLUTELY NO WARRANTY.
    You are welcome to redistribute it under certain conditions.
    Type 'license()' or 'licence()' for distribution details.
    
      Natural language support but running in an English locale
    
    R is a collaborative project with many contributors.
    Type 'contributors()' for more information and
    'citation()' on how to cite R or R packages in publications.
    
    Type 'demo()' for some demos, 'help()' for on-line help, or
    'help.start()' for an HTML browser interface to help.
    Type 'q()' to quit R.
    
    >

    5、

    > install.packages('Cairo', repos='https://mirror.lzu.edu.cn/CRAN/')
    …………
    …………
    ** testing if installed package keeps a record of temporary installation path
    * DONE (Cairo)
    
    The downloaded source packages are in/tmp/RtmpM2ctTJ/downloaded_packages’
    Updating HTML index of packages in '.Library'
    Making 'packages.html' ... done

    6、测试

    > library(Cairo)
    >
  • 相关阅读:
    Python --链接MYSQL数据库与简单操作 含SSH链接
    Jmeter 后置处理器--jp@gc
    Jmeter 接口测试 响应结果中文是Unicode转为中文
    Jmeter JDBC请求---把数据库结果参数化传递到其他请求
    MySQL根据某字段部分内容分组计数
    Linux 服务器命令,持续更新……
    APP网络测试要点和弱网模拟
    Jmeter JDBC Request 查询语句中有汉字查询结果为空的解决方法
    Jmeter连接Redis,获取Redis数据集
    Jmeter获取接口返回数组的长度
  • 原文地址:https://www.cnblogs.com/liujiaxin2018/p/14361394.html
Copyright © 2011-2022 走看看