pcapdumper.cc:11:18: fatal error: pcap.h: No such file or directory #include <pcap.h>

图数据库猫 发布于 06/18 18:05
阅读 165
收藏 0

[root@localhost bin]# ./pip install pcapy
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
Collecting pcapy
  Downloading https://files.pythonhosted.org/packages/b0/68/b49e008f9e2b5ab727fb4b820c2e7d0914bd8dacb3c2d668a36b6e5d8991/pcapy-0.11.4.tar.gz
Building wheels for collected packages: pcapy
  Building wheel for pcapy (setup.py) ... error
  Complete output from command /data/anaconda2/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-h3y0so/pcapy/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/pip-wheel-hEsMth --python-tag cp27:
  running bdist_wheel
  running build
  running build_ext
  building 'pcapy' extension
  creating build
  creating build/temp.linux-x86_64-2.7
  gcc -pthread -B /data/anaconda2/compiler_compat -Wl,--sysroot=/ -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/data/anaconda2/include/python2.7 -c pcapdumper.cc -o build/temp.linux-x86_64-2.7/pcapdumper.o
  cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ [enabled by default]
  pcapdumper.cc:11:18: fatal error: pcap.h: No such file or directory
   #include <pcap.h>
                    ^
  compilation terminated.
  error: command 'gcc' failed with exit status 1
  
  ----------------------------------------
  Failed building wheel for pcapy
  Running setup.py clean for pcapy
Failed to build pcapy
Installing collected packages: pcapy
  Running setup.py install for pcapy ... error
    Complete output from command /data/anaconda2/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-h3y0so/pcapy/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-1BVaGn/install-record.txt --single-version-externally-managed --compile:
    running install
    running build
    running build_ext
    building 'pcapy' extension
    creating build
    creating build/temp.linux-x86_64-2.7
    gcc -pthread -B /data/anaconda2/compiler_compat -Wl,--sysroot=/ -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/data/anaconda2/include/python2.7 -c pcapdumper.cc -o build/temp.linux-x86_64-2.7/pcapdumper.o
    cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ [enabled by default]
    pcapdumper.cc:11:18: fatal error: pcap.h: No such file or directory
     #include <pcap.h>
                      ^
    compilation terminated.
    error: command 'gcc' failed with exit status 1
    
    ----------------------------------------
Command "/data/anaconda2/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-h3y0so/pcapy/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-1BVaGn/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-h3y0so/pcapy/
 

加载中
返回顶部
顶部