TamerPlatform / frida-push

Wrapper tool to identify the remote device and push device specific frida-server binary.
GNU General Public License v3.0
43 stars 32 forks source link

GCC compile error on Fedora 32 #14

Open rugk opened 4 years ago

rugk commented 4 years ago

I get this error when trying to install this lib on Fedora 32. Note Fedora 32 e.g. has removed Python2, but that should not be a problem…

pip3 install --user frida-push
Collecting frida-push
  Using cached https://files.pythonhosted.org/packages/4f/49/7cbf4b840ba67a9697322e99800d81b74a49cd42554765eea4bc87313c83/frida-push-1.0.8.tar.gz
Requirement already satisfied: requests in /usr/lib/python3.8/site-packages (from frida-push) (2.22.0)
Requirement already satisfied: frida in /usr/local/lib64/python3.8/site-packages (from frida-push) (12.11.6)
Collecting backports.lzma
  Using cached https://files.pythonhosted.org/packages/21/0f/1a9990233076d48aa2084100ba289ca162975e73a688f3a56c0ee2bb441a/backports.lzma-0.0.14.tar.gz
Collecting future
  Using cached https://files.pythonhosted.org/packages/45/0b/38b06fd9b92dc2b68d58b75f900e97884c45bedd2ff83203d933cf5851c9/future-0.18.2.tar.gz
Requirement already satisfied: chardet<3.1.0,>=3.0.2 in /usr/lib/python3.8/site-packages (from requests->frida-push) (3.0.4)
Requirement already satisfied: idna<2.9,>=2.5 in /usr/lib/python3.8/site-packages (from requests->frida-push) (2.8)
Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1 in /usr/lib/python3.8/site-packages (from requests->frida-push) (1.25.7)
Installing collected packages: backports.lzma, future, frida-push
    Running setup.py install for backports.lzma ... error
    ERROR: Command errored out with exit status 1:
     command: /usr/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-raba59mq/backports.lzma/setup.py'"'"'; __file__='"'"'/tmp/pip-install-raba59mq/backports.lzma/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-vb2qu191/install-record.txt --single-version-externally-managed --compile --user --prefix=
         cwd: /tmp/pip-install-raba59mq/backports.lzma/
    Complete output (21 lines):
    This is backports.lzma version 0.0.14
    running install
    running build
    running build_py
    creating build
    creating build/lib.linux-x86_64-3.8
    creating build/lib.linux-x86_64-3.8/backports
    copying backports/__init__.py -> build/lib.linux-x86_64-3.8/backports
    creating build/lib.linux-x86_64-3.8/backports/lzma
    copying backports/lzma/__init__.py -> build/lib.linux-x86_64-3.8/backports/lzma
    running build_ext
    building 'backports.lzma._lzma' extension
    creating build/temp.linux-x86_64-3.8
    creating build/temp.linux-x86_64-3.8/backports
    creating build/temp.linux-x86_64-3.8/backports/lzma
    gcc -pthread -Wno-unused-result -Wsign-compare -DDYNAMIC_ANNOTATIONS_ENABLED=1 -DNDEBUG -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -D_GNU_SOURCE -fPIC -fwrapv -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -D_GNU_SOURCE -fPIC -fwrapv -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -D_GNU_SOURCE -fPIC -fwrapv -fPIC -I/usr/include -I/home/rugk/include -I/opt/local/include -I/usr/local/include -I/usr/include/python3.8 -c backports/lzma/_lzmamodule.c -o build/temp.linux-x86_64-3.8/backports/lzma/_lzmamodule.o
    backports/lzma/_lzmamodule.c:12:10: schwerwiegender Fehler: Python.h: Datei oder Verzeichnis nicht gefunden
       12 | #include "Python.h"
          |          ^~~~~~~~~~
    Kompilierung beendet.
    error: command 'gcc' failed with exit status 1
    ----------------------------------------
ERROR: Command errored out with exit status 1: /usr/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-raba59mq/backports.lzma/setup.py'"'"'; __file__='"'"'/tmp/pip-install-raba59mq/backports.lzma/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-vb2qu191/install-record.txt --single-version-externally-managed --compile --user --prefix= Check the logs for full command output.

It seems lzma cannot find Python.h, so maybe it can be solved by #13.