pip安装GeoIP时报fatal error: GeoIP.h: No such file or directory
CentOS 7下使用pip安装GeoIP包时报如下错误,提示缺少GeoIP.h头文件
[root@master-60-5 python]# pip3 install geoip
Looking in indexes: https://pypi.doubanio.com/simple/
Collecting geoipDownloading https://pypi.doubanio.com/packages/f2/7b/a463b7c3df8ef4b9c92906da29ddc9e464d4045f00c475ad31cdb9a97aae/GeoIP-1.3.2.tar.gz (20 kB)
Building wheels for collected packages: geoipBuilding wheel for geoip (setup.py) ... errorERROR: Command errored out with exit status 1:command: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-ej1hc8gn/geoip_a610de910634447f89f7f42ca2d53d17/setup.py'"'"'; __file__='"'"'/tmp/pip-install-ej1hc8gn/geoip_a610de910634447f89f7f42ca2d53d17/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-ksxvyvzpcwd: /tmp/pip-install-ej1hc8gn/geoip_a610de910634447f89f7f42ca2d53d17/Complete output (14 lines):/usr/lib64/python3.6/distutils/dist.py:261: UserWarning: Unknown distribution option: 'bugtrack_url'warnings.warn(msg)running bdist_wheelrunning buildrunning build_extbuilding 'GeoIP' extensioncreating buildcreating build/temp.linux-x86_64-3.6gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -I/usr/include/python3.6m -c py_GeoIP.c -o build/temp.linux-x86_64-3.6/py_GeoIP.opy_GeoIP.c:23:19: fatal error: GeoIP.h: No such file or directory#include "GeoIP.h"^compilation terminated.error: command 'gcc' failed with exit status 1----------------------------------------ERROR: Failed building wheel for geoipRunning setup.py clean for geoip
Failed to build geoip
Installing collected packages: geoipRunning setup.py install for geoip ... errorERROR: Command errored out with exit status 1:command: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-ej1hc8gn/geoip_a610de910634447f89f7f42ca2d53d17/setup.py'"'"'; __file__='"'"'/tmp/pip-install-ej1hc8gn/geoip_a610de910634447f89f7f42ca2d53d17/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-i0zjj460/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.6m/geoipcwd: /tmp/pip-install-ej1hc8gn/geoip_a610de910634447f89f7f42ca2d53d17/Complete output (14 lines):/usr/lib64/python3.6/distutils/dist.py:261: UserWarning: Unknown distribution option: 'bugtrack_url'warnings.warn(msg)running installrunning buildrunning build_extbuilding 'GeoIP' extensioncreating buildcreating build/temp.linux-x86_64-3.6gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -I/usr/include/python3.6m -c py_GeoIP.c -o build/temp.linux-x86_64-3.6/py_GeoIP.opy_GeoIP.c:23:19: fatal error: GeoIP.h: No such file or directory#include "GeoIP.h"^compilation terminated.error: command 'gcc' failed with exit status 1----------------------------------------
ERROR: Command errored out with exit status 1: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-ej1hc8gn/geoip_a610de910634447f89f7f42ca2d53d17/setup.py'"'"'; __file__='"'"'/tmp/pip-install-ej1hc8gn/geoip_a610de910634447f89f7f42ca2d53d17/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-i0zjj460/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.6m/geoip Check the logs for full command output.
- 解决方法,安装geoip-devel
yum install -y geoip-devel
- 安装GeoIP成功
[root@master-60-5 python]# pip3 install geoip
Looking in indexes: https://pypi.doubanio.com/simple/
Collecting geoipUsing cached https://pypi.doubanio.com/packages/f2/7b/a463b7c3df8ef4b9c92906da29ddc9e464d4045f00c475ad31cdb9a97aae/GeoIP-1.3.2.tar.gz (20 kB)
Building wheels for collected packages: geoipBuilding wheel for geoip (setup.py) ... doneCreated wheel for geoip: filename=GeoIP-1.3.2-cp36-cp36m-linux_x86_64.whl size=46113 sha256=4ede072ab7c175b13db58056d25028c7bec3dfd28a7fe163bd04a5ffea710b45Stored in directory: /root/.cache/pip/wheels/cc/88/79/80e1c0a90f10724b3bed4cd8df3fb5ed1a6c14889beb018ebc
Successfully built geoip
Installing collected packages: geoip
Successfully installed geoip-1.3.2
pip安装GeoIP时报fatal error: GeoIP.h: No such file or directory相关推荐
- 【scrapy】Ubuntu安装scrapy报错:fatal error: Python.h: No such file or directory
src/twisted/test/raiser.c:4:10: fatal error: Python.h: No such file or directory#include "Pytho ...
- backports/lzma/_lzmamodule.c:115:18: fatal error: lzma.h: No such file or directory serWarning: Coul
执行 /home/admin/env/acq-cluster-data-init/bin/pip install backports.lzma报错 服务器运行带有pandas的脚本报如下错误 /hom ...
- Install matplotlib Error: src/ft2font.h:16:22: fatal error: ft2build.h: No such file or directory
在ubuntu下从源码安装matplotlib的时候出现这样的错误: src/ft2font.h:16:22: fatal error: ft2build.h: No such file or dir ...
- 【错误记录】编译 ijkplayer 报错 (fatal error: libyuv.h: No such file or directory #include “libyuv.h“ )
文章目录 一.报错信息 二.解决方案 参考 https://github.com/bilibili/ijkplayer 项目的编译过程 ; 一.报错信息 在编译完 ffmpeg 之后 , 执行 ./c ...
- linux redis release.c:37:10: fatal error: release.h: No such file or directory
(1条消息) redis源码安装出现fatal error: jemalloc/jemalloc.h: No such file or directory_feinifi的博客-CSDN博 ...
- python mysql python.h_MySQLdb/_mysql.c:38:20: fatal error: Python.h: No such file or directory
一.描述 在centos7.5中执行pip3 install mysqlclient,报如下错误 [root@VM_0_10_centos data]# pip3 install mysqlclien ...
- fatal error: cusparse.h: No such file or directory compilation terminated. error: command ‘/usr/loca
写在前面: 我是用pycharm远程连接矩池云的GPU遇到了这个问题.前面安装包都很顺利,就是最后安装maskrcnn-benchmark的时候出问题了,一直在报错 fatal error: cusp ...
- Arduino编译Marlin1.1出现 fatal error: U8glib.h: No such file or directory如何解决
marlin固件发展至今已经形成了三个比较重大的版本:1.0版,1.1版,2.0版. 本文介绍的是Marlin1.1版本的,Arduino用到的版本1.6.7,Marlin1.0版,1.1版都能用Ar ...
- Arduino库报错Adafruit_I2CDevice.h找不到,fatal error: Adafruit_I2CDevice.h: No such file or directory
报错: fatal error: Adafruit_I2CDevice.h: No such file or directory #include <Adafruit_I2CDevice.h&g ...
- decode.c:38:18: fatal error: dnet.h: No such file or directory
根据文档(Snort 2.9.7.x on Ubuntu 12 LTS and 14 LTS)为snort安装barnyard2的时候遇到问题: 缺少dnet.h头文件 decode.c:38:18: ...
最新文章
- Python实用小工具了解一下,总有一款是你需要的
- 工具安装===Sublime Text-安装
- export ,export default 和 import 区别 以及用法
- WCF学习之旅—实现支持REST客户端应用(二十四)
- 携程运维自动化平台,上万服务器变更也可以很轻松
- 010 、JVM实战总结: 动手实验:亲自感受一下线上系统部署时如何设置JVM内存大小
- tcp_wrapper:简单的基于主机的访问控制工具
- MATLAB中SVM(支持向量机)的用法
- 基于QT的HLW8032电能芯片测试上位机开发
- 【工具】idea去掉UML类图的虚线箭头(依赖关系)
- 【Nape教程】Nape刚体碰撞检测
- 统计地铁一号线站点Python
- ffmpeg libx264 h264_nvenc 编码参数解析
- 如何做一个员工管理系统
- java实现踢下线用户_浅谈踢人下线的设计思路!(附代码实现方案)
- 安卓开发中必备的那些神器APP
- 每日一题(day5)
- android 手机usb 驱动安装
- mysql连接驱动_MySQL8.0数据库连接驱动问题
- 纤亿通对资本支出下降通信5G基站建设有哪些看点以及5G基站的方案?
热门文章
- AES128-CBC
- 掌上单片机实验室 — 编程环境(3)
- 什么是替换加密(凯撒密码)?原理是什么?
- 疫情数据分析平台(四):世界疫情地图绘制
- 传智播客html5案例,html5 传智播客
- 股票盯盘助手(才152KB),支持悬浮并置顶,支持拖到任务栏,支持更改刷新频率
- Django +python+bootstrap 开发web,app,接口测试平台(持续更新)
- springWebScoket聊天室
- QT (C++)安装5.14
- 计算机辅助设计与制造的应用,计算机辅助设计与制造(UG)