Reputation: 843
I am trying to create an executable from a python script, using pyinstaller, and am getting the error seen in the subject line. The particulars:
I evoke pyinstaller as:
pyinstaller --onefile pythonfile.py
When I looked to see what libpython*.so
files were resident, I see libpython3.7*.so
, and the error shows I need to install libpython3.9*so
files.
I have tried:
pip3 install PyInstaller (to load on pyinstaller)
apt-get install python3-dev (as recommended in the pyinstaller error msg)
apt-get install python-dev (as recommended in the pyinstaller error msg)
apt-get upgrade
apt-get update
but still get the error. How can I get the correct libpython*.so
files loaded (i.e., 3.9)? TIA.
Upvotes: 4
Views: 11926
Reputation: 285
Or try this: sudo apt-get install libpython3.7-dev it worked for me
Upvotes: 8