pycharm使用错误排查

摘要:
命令“x86_64 linux gnu gcc”在exitstatus1安装扩展包中失败kamil@vm-ubuntu:~$sudoapt-getinstallpython3-dev[sudo]passwordforkamil:~$sudoppinstall--upgradepip[sudo]passwordforkamil:

1.pip安装扩展包报错

pycharm使用错误排查第1张pycharm使用错误排查第2张
    creating build/temp.linux-x86_64-3.4
    x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -fPIC -I/usr/local/include -I/usr/include/python3.4m -c _mssql.c -o build/temp.linux-x86_64-3.4/_mssql.o -DMSDBLIB
    _mssql.c:8:22: fatal error: pyconfig.h: No such file or directory
     #include "pyconfig.h"
                          ^
    compilation terminated.
    error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
View Code

error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

 安装扩展包

kamil@vm-ubuntu:~$ sudo apt-get install python3-dev
[sudo] password for kamil: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  libexpat1-dev libpython3-dev libpython3.4 libpython3.4-dev python3.4-dev
The following NEW packages will be installed:
  libexpat1-dev libpython3-dev libpython3.4 libpython3.4-dev python3-dev
  python3.4-dev
0 upgraded, 6 newly installed, 0 to remove and 64 not upgraded.
Need to get 19.6 MB of archives.
After this operation, 36.1 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://us.archive.ubuntu.com/ubuntu/ trusty-updates/main libpython3.4 amd64 3.4.3-1ubuntu1~14.04.3 [1,308 kB]

 2.pip升级

kamil@vm-ubuntu:~$ sudo pip install --upgrade pip
[sudo] password for kamil: 
The directory '/home/kamil/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
You are using pip version 7.1.0, however version 8.1.2 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
The directory '/home/kamil/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting pip
  Downloading pip-8.1.2-py2.py3-none-any.whl (1.2MB)
    100% |████████████████████████████████| 1.2MB 90kB/s 
Installing collected packages: pip
  Found existing installation: pip 7.1.0
    Uninstalling pip-7.1.0:
      Successfully uninstalled pip-7.1.0
Successfully installed pip-8.1.1
kamil@vm-ubuntu:~$ 

3.Command "python setup.py egg_info" failed with error code 1 in

请问

4.error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

You need to install the FreeTDS development package (freetds-dev) before trying to install pymssql with pip:
$ sudo apt-get install freetds-dev
sudo apt-get install -y libxml2-dev libxslt1-dev zlib1g-dev python3-pip
and then, in your virtualenv or wherever you wish to install it:
$ pip install pymssql
kamil@vm-ubuntu:~$ sudo pip install pymssql
The directory '/home/kamil/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/kamil/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting pymssql
  Downloading pymssql-2.1.2.tar.gz (898kB)
    100% |████████████████████████████████| 901kB 59kB/s 
Installing collected packages: pymssql
  Running setup.py install for pymssql ... done
Successfully installed pymssql-2.1.2
kamil@vm-ubuntu:~$ 

 5.error: Microsoft Visual C++ 10.0 is required (Unable to find vcvarsall.bat).

请问

 6.lxml安装报错

pycharm使用错误排查第3张pycharm使用错误排查第4张
    compilation terminated.
    *********************************************************************************
    Could not find function xmlCheckVersion in library libxml2. Is libxml2 installed?
    *********************************************************************************
    error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
    
    ----------------------------------------
  Rolling back uninstall of lxml
Command "/usr/bin/python3.5 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-j1bywhpx/lxml/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('
', '
'), __file__, 'exec'))" install --record /tmp/pip-vz905g9u-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-j1bywhpx/lxml/
View Code

解决:

1 apt-get install libxml2-dev;
2 apt-get install libxslt1-dev;
3 sudo pip install lxml --upgrade

 7.MySQL-Python模块

sudo apt-get install libmysqlclient-dev
yum install python-devel mysql-devel

免责声明:文章转载自《pycharm使用错误排查》仅用于学习参考。如对内容有疑问,请及时联系本站处理。

上篇解决winform中mdi子窗体加载时显示最大化最小化按钮的方法WinXP、Win7脚本自动加域及用户资料迁移下篇

宿迁高防,2C2G15M,22元/月;香港BGP,2C5G5M,25元/月 雨云优惠码:MjYwNzM=

相关文章

android 录制

引用:http://www.jtben.com/document/919575 出自ATHZ-SEC1-WIKI   跳转到: 导航, 搜索 Android 事件录制脚本的生成 Software R&D Center-SW R&D Dept.-Sec.1HZSWTL2011008Prepared by: Andy3 LiuJan. 2...

查看linux硬盘使用率

df -h df命令是Linux系统以磁盘分区为单位查看文件系统,可以加上参数查看磁盘剩余空间信息,命令格式: df -hl 显示格式为:  文件系统 容量 已用 可用 已用% 挂载点  filesystem Size Used Avail Use% Mounted on /dev/hda2 45G 19G 24G 44% / /dev/hda1 4...

XFS文件系统的备份与恢复

永久修改主机名:hostnamectl set-hostname oldboy临时修改主机名:hostname xfsdump备份xfsdump -f 备份的文件位置 要备份的分区或者磁盘 免交互备份做定时备份:xfsdump -f /opt/dump_sdb_01 /sdb -L dump_sdb_1 -M passwd 备份/boot分区下grub2进...

FreeBSD查看带宽占用情况,CPU,硬盘IO 虚拟内存等命令

FreeBSD查看带宽占用情况,CPU,硬盘IO 虚拟内存等命令 来源 https://www.liurongxing.com/freebsd-tips.html 来源 http://blog.51cto.com/wjcaiyf/1597030 1.查看CPU型号:sysctl -a |grep hw.model 2.查看CPU核心数sysctl -a |...

(转)tune2fs命令详解

tune2fs命令详解(原创) 原文:http://czmmiao.iteye.com/blog/1749232 tune2fs简介 tune2fs是调整和查看ext2/ext3文件系统的文件系统参数,Windows下面如果出现意外断电死机情况,下次开机一般都会出现系统自检。Linux系统下面也有文件系统自检,而且是可以通过tune2fs命令,自行定义自检...

PostMan Setting Proxy 设置 代理

postman的代理使用篇(四) - codingstudy - SegmentFault 思否https://segmentfault.com/a/1190000012024844 postman 设置代理 - 凯宾斯基 - 博客园https://www.cnblogs.com/kaibindirver/p/8916278.html Postman 入门...