错误一

安装过程中遇到:

ERROR: Command errored out with exit status 1: /home/welkin/Desktop/AFL/epf/.env/bin/python3 -u -c ‘import sys, setuptools, tokenize; sys.argv[0] = ‘"’"’/tmp/pip-install-rwvrrmy9/matplotlib/setup.py’"’"’; file=’"’"’/tmp/pip-install-rwvrrmy9/matplotlib/setup.py’"’"’;f=getattr(tokenize, ‘"’"‘open’"’"’, open)(file);code=f.read().replace(’"’"’\r\n’"’"’, ‘"’"’\n’"’"’);f.close();exec(compile(code, file, ‘"’"‘exec’"’"’))’ install --record /tmp/pip-record-q37ze_jx/install-record.txt --single-version-externally-managed --compile --install-headers /home/welkin/Desktop/AFL/epf/.env/include/site/python3.9/matplotlib Check the logs for full command output.
WARNING: You are using pip version 20.1.1; however, version 22.0.3 is available.
You should consider upgrading via the ‘/home/Desktop/AFL/epf/.env/bin/python3 -m pip install --upgrade pip’ command.

这里只需要按照它的指示更新pip即可
输入:python3 -m pip install --upgrade pip' command
然后就会报第二个错误

错误二

setup script exited with error: command ‘x86_64-linux-gnu-gcc’ failed
with exit status 1

x86_64-linux-gnu-gcc -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -g -fwrapv -O2 -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DFREETYPE_BUILD_TYPE=system -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib_ft2font_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D__STDC_FORMAT_MACROS=1 -Iextern/agg24-svn/include -I/home/welkin/Desktop/AFL/epf/.env/lib/python3.9/site-packages/numpy/core/include -I/home/welkin/Desktop/AFL/epf/.env/include -I/usr/include/python3.9 -c src/checkdep_freetype2.c -o build/temp.linux-x86_64-3.9/src/checkdep_freetype2.o
src/checkdep_freetype2.c:3:6: error: #error “FreeType version 2.3 or higher is required. You may set the MPLLOCALFREETYPE environment variable to 1 to let Matplotlib download it.”
3 | #error "FreeType version 2.3 or higher is required.
| ^~~~~
src/checkdep_freetype2.c:10:10: error: #include expects “FILENAME” or
10 | #include FT_FREETYPE_H
| ^~~~~~~~~~~~~
src/checkdep_freetype2.c:15:9: note: ‘#pragma message: Compiling with FreeType version FREETYPE_MAJOR.FREETYPE_MINOR.FREETYPE_PATCH.’
15 | #pragma message("Compiling with FreeType version "
| ^~~~~~~
src/checkdep_freetype2.c:18:4: error: #error “FreeType version 2.3 or higher is required. You may set the MPLLOCALFREETYPE environment variable to 1 to let Matplotlib download it.”
18 | #error "FreeType version 2.3 or higher is required.
| ^~~~~
error: command ‘/usr/bin/x86_64-linux-gnu-gcc’ failed with exit code 1
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure

我的主机解决办法是:

sudo apt-get install libfreetype6-dev
sudo apt-get install pkg-config
sudo apt-get install libpng12-dev
sudo apt-get install pkg-config

解决页面如下:

(错误记录)python3.9安装matplotlib3.2.2版本失败解决相关推荐

  1. VC2008 Redist依赖安装 win10下报1935失败解决

    VC2008 Redist依赖安装 win10下报1935失败解决 最近有一个老项目在windows下进行安装,遇到一台Win10的机器,安装VC2008依赖的时候报错了,很苦恼,VC高版本的依赖库安 ...

  2. 因为计算机安装了更新i,电脑安装iTunes时提示这台电脑已安装了更高版本的解决方法图文教程...

    最近有用户在电脑中安装iTunes软件时,出现了提示"这台电脑已安装了更高版本的Apple Software Update",如果遇到了这样的问题,这该怎么办呢?下面脚本之家的小编 ...

  3. 【错误记录】未安装该应用 ( 在 Android 12 之后 组件设置 android:exported=“false“ 属性 )

    文章目录 一.报错信息 二.解决方案 一.报错信息 报错信息 : 点击应用图标后 , 应用并未启动 , 并弹出 " 未安装该应用 " 提示信息 ; 二.解决方案 排查了一下相关地方 ...

  4. Arcgis10.2安装及LicensenManager10.2启动失败解决方法

    arcgis10.2安装步骤: https://jingyan.baidu.com/article/fc07f98911b66912ffe5199b.html LicensenManager10.2启 ...

  5. 重装MAC系统 “安装器有效负载签名检查失败” 解决方法

    部分朋友反应安装macOS Sierra的时候会提示: "安装器有效负载签名检查失败" 其实这是系统时间不对的原因,把系统时间修改正确就好了. 1,如果电脑正常运行,那么进系统偏好 ...

  6. 该计算机已安装了更高版本的,电脑安装iTunes时提示这台电脑已安装了更高版本怎么解决...

    最近有用户在电脑中安装iTunes软件时,出现了提示"这台电脑已安装了更高版本的Apple Software Update",如果遇到了这样的问题,那么应该怎么解决?对此,不妨根据 ...

  7. 已经在此计算机安装版本的,电脑安装iTunes时提示这台电脑已安装了更高版本怎么解决...

    最近有用户在电脑中安装iTunes软件时,出现了提示"这台电脑已安装了更高版本的Apple Software Update",如果遇到了这样的问题,那么应该怎么解决?对此,不妨根据 ...

  8. Tensorflow-gpu+Cuda+cuDNN安装(详细且包含失败解决教程)

    WINDOWS系统查看nvidia显卡和CUDA的版本号 Win+r+cmd后输入nvidia-smi 主要是看Driver Version 462.31这个值. 2.根据Driver Version ...

  9. 【错误记录】Ubuntu 安装软件报错 ( Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource tempora )

    文章目录 一.报错信息 二.解决方案 一.报错信息 在 VMware Workstation 中的 Ubuntu 操作系统中 , 使用 sudo apt-get install gparted 命令 ...

最新文章

  1. golang socket读写同时_epoll在Golang的应用
  2. RISV-V未来将面临怎样的挑战?
  3. Py之pywin32:Python库之pywin32的简介、安装、使用方法之详细攻略
  4. 关于JQUery.parseJSON()函数的知识札记
  5. js实现日期转换方法
  6. Windows Phone笔记索引(总)
  7. 导出Android手机应用apk
  8. 代理模式coding-动态代理
  9. Spring JPA 中的Repository体系
  10. 竞赛发布|100万奖金寻DT时代“最强大脑”!
  11. hiveserver2启动不起来_汽车一键启动只能用来打火吗 车主必须知道的几个“隐藏”技巧!...
  12. android 仿ofo页面,GitHub - AndroidProject1212/react-native-ofo: React Native 仿 ofo 共享单车 App...
  13. 成为优秀交互设计师的六个必备技能
  14. eclipse 64位 免安装_超详细:64位Linux下安装PS模拟器ePSxe
  15. 最新获得淘宝app商品详情原数据 的API
  16. 强智教务系统验证码识别 Tensorflow CNN
  17. 不规则四边形填充平面 - Townscaper 网格生成算法复现
  18. H5兼容问题及解决方法
  19. AI时代的追星逐浪,中国科技的奋发自强
  20. JSF学习笔记超详细,从入门到精通,持续更新中~

热门文章

  1. 凭什么要“答而不辩,疯狂道歉”?
  2. java.beans包概述
  3. 周杰伦推荐 万魔新降噪豆 1MORE EVO 全新发布
  4. 职场IT老手教你3步教你玩转可视化大屏设计,让领导眼前一亮!
  5. 42个著名搜索引擎免费登陆入口大全
  6. 下代Macbook会用什么处理器?
  7. 一张图看懂 SQL 的各种 join 用法!
  8. keilc51下载安装
  9. c#输入三个数升序排列,如何在C#中按升序对数组进行排序?
  10. 【BZOJ3309】DZY Loves Math(线性筛)