Pyrit
Pyrit copied to clipboard
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
idoctor@kali:~/Downloads/Pyrit-v0.5.0$ sudo python setup.py install
[sudo] password for idoctor:
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-2.7
copying pyrit_cli.py -> build/lib.linux-x86_64-2.7
creating build/lib.linux-x86_64-2.7/cpyrit
copying cpyrit/__init__.py -> build/lib.linux-x86_64-2.7/cpyrit
copying cpyrit/cpyrit.py -> build/lib.linux-x86_64-2.7/cpyrit
copying cpyrit/util.py -> build/lib.linux-x86_64-2.7/cpyrit
copying cpyrit/pckttools.py -> build/lib.linux-x86_64-2.7/cpyrit
copying cpyrit/config.py -> build/lib.linux-x86_64-2.7/cpyrit
copying cpyrit/network.py -> build/lib.linux-x86_64-2.7/cpyrit
copying cpyrit/storage.py -> build/lib.linux-x86_64-2.7/cpyrit
running build_ext
building 'cpyrit._cpyrit_cpu' extension
creating build/temp.linux-x86_64-2.7
creating build/temp.linux-x86_64-2.7/cpyrit
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fdebug-prefix-map=/build/python2.7-07FOaN/python2.7-2.7.17=. -fstack-protector-strong -Wformat -Werror=format-security -fPIC -I/usr/include/python2.7 -c cpyrit/_cpyrit_cpu.c -o build/temp.linux-x86_64-2.7/cpyrit/_cpyrit_cpu.o -Wall -fno-strict-aliasing -DVERSION="0.5.0" -maes -mpclmul
cpyrit/_cpyrit_cpu.c:32:10: fatal error: Python.h: No such file or directory
32 | #include <Python.h>
| ^~~~~~~~~~
compilation terminated.
Failed to build; Compiling without AES-NI
building 'cpyrit._cpyrit_cpu' extension
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fdebug-prefix-map=/build/python2.7-07FOaN/python2.7-2.7.17=. -fstack-protector-strong -Wformat -Werror=format-security -fPIC -I/usr/include/python2.7 -c cpyrit/_cpyrit_cpu.c -o build/temp.linux-x86_64-2.7/cpyrit/_cpyrit_cpu.o -Wall -fno-strict-aliasing -DVERSION="0.5.0"
cpyrit/_cpyrit_cpu.c:32:10: fatal error: Python.h: No such file or directory
32 | #include <Python.h>
| ^~~~~~~~~~
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
same here also when try to install it from kali with: apt install pyrit it give Package 'pyrit' has no installation candidate:
same here
sudo apt-get install python3 python-dev python3-dev build-essential libssl-dev libffi-dev libxml2-dev libxslt1-dev zlib1g-dev
sudo ./setup.py build install
this should work
Make sure to use Python2, as Pyrit has not been updated to Python3 yet sudo apt-get install python2.7
or python2 clean build install
if you already have Python2
Make sure to use Python2, as Pyrit has not been updated to Python3 yet
sudo apt-get install python2.7
orpython2 clean build install
if you already have Python2
I Have tried every mentioned solution above and yours too... Still i'm getting same error but with a diiference. instead of python.h fatal error, it says pcap.h.... Please help
Whats your O.S? Try : sudo apt-get install libpcap-dev
Generally when you see a header file missing {NAME}.h, Google the header name followed by "missing", 99% of the time you'll find your problem. :)
Make sure to use Python2, as Pyrit has not been updated to Python3 yet
sudo apt-get install python2.7
orpython2 clean build install
if you already have Python2
Bingo. Thank you kindly!
This is the only way it worked for me. Completely uninstalled and reinstalled everything needed. Hope it helps someone. https://github.com/hacker3983/pyrit-installer