Frida: Installation fails on Ubuntu 16.04

Created on 1 Feb 2017  路  4Comments  路  Source: frida/frida

This problem occurs when I install frida both with pip and pip3

Successfully installed frida-9.1.1

If I try to import frida in python2

$ python
Python 2.7.12 (default, Nov 19 2016, 06:48:10) 
...
>>> import frida
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: No module named frida

and that's correct, as I read. But with python3:

$ python3
Python 3.5.2 (default, Nov 17 2016, 17:05:23) 
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import frida

***
Failed to load the Frida native extension: libpython3.6m.so.1.0: cannot open shared object file: No such file or directory
Please ensure that the extension was compiled for Python 3.x.
***

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.5/dist-packages/frida/__init__.py", line 26, in <module>
    raise ex
  File "/usr/local/lib/python3.5/dist-packages/frida/__init__.py", line 6, in <module>
    import _frida
ImportError: libpython3.6m.so.1.0: cannot open shared object file: No such file or directory
>>>

The same occurs when I run it:

$ frida-ps -U

***
Failed to load the Frida native extension: libpython3.6m.so.1.0: cannot open shared object file: No such file or directory
Please ensure that the extension was compiled for Python 3.x.
***
...

Most helpful comment

Solved, I missed python3.6

sudo add-apt-repository ppa:jonathonf/python-3.6
sudo apt-get update
sudo apt-get install python3.6 libpython3.6

All 4 comments

Solved, I missed python3.6

sudo add-apt-repository ppa:jonathonf/python-3.6
sudo apt-get update
sudo apt-get install python3.6 libpython3.6

馃憤

i have the same problem, when i run sudo apt-get install python3.6 libpython3.6 i get
root@Kali:/tmp/frida-9.1.6# sudo apt-get install python3.6 libpython3.6
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package python3.6
E: Couldn't find any package by glob 'python3.6'
E: Couldn't find any package by regex 'python3.6'
E: Unable to locate package libpython3.6
E: Couldn't find any package by glob 'libpython3.6'
E: Couldn't find any package by regex 'libpython3.6'
root@Kali:/tmp/frida-9.1.6#

wget https://bootstrap.pypa.io/get-pip.py
sudo python3.6 get-pip.py
sudo ln -s /usr/bin/python3.6 /usr/local/bin/python3
sudo ln -s /usr/local/bin/pip /usr/local/bin/pip3


Was this page helpful?
0 / 5 - 0 ratings