Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
pyinstaller
#21
okay, when i do the first step, which is typing: curl -L https://raw.githubusercontent.com/pyenv/pyenv-installer/master/bin/pyenv-installer | bash

it says the same thing:

Output:
tal@tal-HP-Notebook:~$ curl -L https://raw.githubusercontent.com/pyenv/pyenv-installer/master/bin/pyenv-installer | bash % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 2454 100 2454 0 0 3007 0 --:--:-- --:--:-- --:--:-- 3007 WARNING: Can not proceed with installation. Kindly remove the '/home/tal/.pyenv' directory first. tal@tal-HP-Notebook:~$
Reply
#22
astral_travel Wrote:path '/home/tal/.pyenv' already exists and is not an empty directory.
It may mean that it has been installed before.
If you type pyenv and it say command not found,then it not working now.
Delete folder .pyenv.
All info is here pyenv Simple Python Version Management,there 1-4 steps can not skip any or this will not work.
Reply
#23
i don't succeed in deleting the folder,
i don't have access to it for some reason

Output:
tal@tal-HP-Notebook:~$ cd /home/tal/.pynev bash: cd: /home/tal/.pynev: No such file or directory tal@tal-HP-Notebook:~$

ah okay, sorry, my mistake...didn't write it correctly

i will try to delete it and install it again

okay i succeeded in installing pyenv, and also i installed python 3.8.3 through it

now when i try to make an exe with pyinstaller - it writes th following:

Output:
root@tal-HP-Notebook:~# apt-get install python3-dev Reading package lists... Done Building dependency tree Reading state information... Done python3-dev is already the newest version (3.5.1-3). 0 upgraded, 0 newly installed, 0 to remove and 25 not upgraded. root@tal-HP-Notebook:~# apt-get install python3.8.3-dev Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package python3.8.3-dev E: Couldn't find any package by glob 'python3.8.3-dev' E: Couldn't find any package by regex 'python3.8.3-dev' root@tal-HP-Notebook:~#
(same thing)

but it also doesn't recognize the python 3.8.3 installation:

Output:
tal@tal-HP-Notebook:~$ python Python 2.7.12 (default, Apr 15 2020, 17:07:12) [GCC 5.4.0 20160609] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> exit Use exit() or Ctrl-D (i.e. EOF) to exit >>> KeyboardInterrupt >>> tal@tal-HP-Notebook:~$ python3 Python 3.5.2 (default, Apr 16 2020, 17:47:17) [GCC 5.4.0 20160609] on linux Type "help", "copyright", "credits" or "license" for more information. >>> tal@tal-HP-Notebook:~$ python3.7 Python 3.7.2 (default, Apr 24 2020, 21:52:53) [GCC 5.4.0 20160609] on linux Type "help", "copyright", "credits" or "license" for more information. >>> tal@tal-HP-Notebook:~$ python3.8 No command 'python3.8' found, did you mean: Command 'python3.5' from package 'python3.5-minimal' (main) python3.8: command not found tal@tal-HP-Notebook:~$
Reply
#24
am i going in circles here ?

(at least i got the pyenv installed)
Reply
#25
(May-24-2020, 06:10 PM)astral_travel Wrote: okay i succeeded in installing pyenv, and also i installed python 3.8.3 through it

now when i try to make an exe with pyinstaller - it writes th following:
What are doing,that's not using pyenv.
You do not need this at all now,this is done first under 1. Install building tools in my tutorial.
apt-get install python3-dev
#apt-get install python3.8.3-dev #no
You most follow post #10,more info here.
So it's like this:
# Update pyenv to get new versions list
tom@tom:~$ pyenv update
 
# Look at available versions 
tom@tom:~$ pyenv install --list
...
3.8.3
3.9-dev 

# Install with --enable-shared so pyinstaller will work
tom@tom-VirtualBox:~$ PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.8.3
Downloading Python-3.8.3.tar.xz...
-> https://www.python.org/ftp/python/3.8.3/Python-3.8.3.tar.xz
Installing Python-3.8.3...
Installed Python-3.8.3 to /home/tom/.pyenv/versions/3.8.3

# Set as system wide version,test pip -V after
tom@tom-VirtualBox:~$ pyenv global 3.8.3

# Install pyinstaller
tom@tom-VirtualBox:~$ pip install pyinstaller
Reply
#26
Output:
PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 3.8.3 pyenv: /home/tal/.pyenv/versions/3.8.3 already exists continue with installation? (y/N) n tal@tal-HP-Notebook:~$
Output:
tal@tal-HP-Notebook:~$ pip install pyinstaller Defaulting to user installation because normal site-packages is not writeable Requirement already satisfied: pyinstaller in ./.local/lib/python3.7/site-packages (3.6) Requirement already satisfied: setuptools in /usr/local/lib/python3.7/site-packages (from pyinstaller) (40.6.2) Requirement already satisfied: altgraph in ./.local/lib/python3.7/site-packages (from pyinstaller) (0.17) tal@tal-HP-Notebook:~$
Reply
#27
Now is installation of Python 3.8.3 okay.
You most set Python 3.8.3 global(System wide usage),then can test with python -V and pip -V
When pip point to 3.8.3 then do pip install pyinstaller.
Example,now you see i use Python 3.7.3.
tom@tom-VirtualBox:~$ python -V
Python 3.7.3

tom@tom-VirtualBox:~$ pip -V
pip 19.1.1 from /home/tom/.pyenv/versions/3.7.3/lib/python3.7/site-packages/pip (python 3.7)

tom@tom-VirtualBox:~$ pyenv versions
  system
  2.4
  3.7.2
* 3.7.3 (set by /home/tom/.pyenv/version)
  3.8.0
  3.8.1
  3.8.3
  3.8-dev
  3.9-dev
No switch to 3.8.3,which i have build so pyinstaller work.
# Switch and test python and pip
tom@tom-VirtualBox:~$ pyenv global 3.8.3
tom@tom-VirtualBox:~$ python -V
Python 3.8.3
tom@tom-VirtualBox:~$ pip -V
pip 19.2.3 from /home/tom/.pyenv/versions/3.8.3/lib/python3.8/site-packages/pip (python 3.8)

# Use pyinstaller 
tom@tom-VirtualBox:~$ pyinstaller --onefile hello.py
197 INFO: PyInstaller: 3.6
197 INFO: Python: 3.8.3
202 INFO: Platform: Linux-4.15.0-32-generic-x86_64-with-glibc2.2.5
203 INFO: wrote /home/tom/hello.spec
204 INFO: UPX is not available.
219 INFO: Extending PYTHONPATH with paths
['/home/tom', '/home/tom']
219 INFO: checking Analysis
549 INFO: checking PYZ
568 INFO: checking PKG
576 INFO: Bootloader /home/tom/.pyenv/versions/3.8.3/lib/python3.8/site-packages/PyInstaller/bootloader/Linux-64bit/run
576 INFO: checking EXE
tom@tom-VirtualBox:~$ cd dist
tom@tom-VirtualBox:~/dist$ ls
hello
tom@tom-VirtualBox:~/dist$ ./hello
hello world
Press Entert to quit
Reply
#28
when i type in pyenv install --list it gives me the following:

Output:
tal@tal-HP-Notebook:~$ pyenv install --list Available versions: 2.1.3 2.2.3 2.3.7 2.4.0 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 2.4.6 2.5.0 2.5.1 2.5.2 2.5.3 2.5.4 2.5.5 2.5.6 2.6.6 2.6.7 2.6.8 2.6.9 2.7.0 2.7-dev 2.7.1 2.7.2 2.7.3 2.7.4 2.7.5 2.7.6 2.7.7 2.7.8 2.7.9 2.7.10 2.7.11 2.7.12 2.7.13 2.7.14 2.7.15 2.7.16 2.7.17 2.7.18 3.0.1 3.1.0 3.1.1 3.1.2 3.1.3 3.1.4 3.1.5 3.2.0 3.2.1 3.2.2 3.2.3 3.2.4 3.2.5 3.2.6 3.3.0 3.3.1 3.3.2 3.3.3 3.3.4 3.3.5 3.3.6 3.3.7 3.4.0 3.4-dev 3.4.1 3.4.2 3.4.3 3.4.4 3.4.5 3.4.6 3.4.7 3.4.8 3.4.9 3.4.10 3.5.0 3.5-dev 3.5.1 3.5.2 3.5.3 3.5.4 3.5.5 3.5.6 3.5.7 3.5.8 3.5.9 3.6.0 3.6-dev 3.6.1 3.6.2 3.6.3 3.6.4 3.6.5 3.6.6 3.6.7 3.6.8 3.6.9 3.6.10 3.7.0 3.7-dev 3.7.1 3.7.2 3.7.3 3.7.4 3.7.5 3.7.6 3.7.7 3.8.0 3.8-dev 3.8.1 3.8.2 3.8.3 3.9.0a6 3.9-dev 3.10-dev activepython-2.7.14 activepython-3.5.4 activepython-3.6.0 anaconda-1.4.0 anaconda-1.5.0 anaconda-1.5.1 anaconda-1.6.0 anaconda-1.6.1 anaconda-1.7.0 anaconda-1.8.0 anaconda-1.9.0 anaconda-1.9.1 anaconda-1.9.2 anaconda-2.0.0 anaconda-2.0.1 anaconda-2.1.0 anaconda-2.2.0 anaconda-2.3.0 anaconda-2.4.0 anaconda-4.0.0 anaconda2-2.4.0 anaconda2-2.4.1 anaconda2-2.5.0 anaconda2-4.0.0 anaconda2-4.1.0 anaconda2-4.1.1 anaconda2-4.2.0 anaconda2-4.3.0 anaconda2-4.3.1 anaconda2-4.4.0 anaconda2-5.0.0 anaconda2-5.0.1 anaconda2-5.1.0 anaconda2-5.2.0 anaconda2-5.3.0 anaconda2-5.3.1 anaconda2-2018.12 anaconda2-2019.03 anaconda2-2019.07 anaconda3-2.0.0 anaconda3-2.0.1 anaconda3-2.1.0 anaconda3-2.2.0 anaconda3-2.3.0 anaconda3-2.4.0 anaconda3-2.4.1 anaconda3-2.5.0 anaconda3-4.0.0 anaconda3-4.1.0 anaconda3-4.1.1 anaconda3-4.2.0 anaconda3-4.3.0 anaconda3-4.3.1 anaconda3-4.4.0 anaconda3-5.0.0 anaconda3-5.0.1 anaconda3-5.1.0 anaconda3-5.2.0 anaconda3-5.3.0 anaconda3-5.3.1 anaconda3-2018.12 anaconda3-2019.03 anaconda3-2019.07 anaconda3-2019.10 anaconda3-2020.02 ironpython-dev ironpython-2.7.4 ironpython-2.7.5 ironpython-2.7.6.3 ironpython-2.7.7 jython-dev jython-2.5.0 jython-2.5-dev jython-2.5.1 jython-2.5.2 jython-2.5.3 jython-2.5.4-rc1 jython-2.7.0 jython-2.7.1 micropython-dev micropython-1.9.3 micropython-1.9.4 micropython-1.10 micropython-1.11 micropython-1.12 miniconda-latest miniconda-2.2.2 miniconda-3.0.0 miniconda-3.0.4 miniconda-3.0.5 miniconda-3.3.0 miniconda-3.4.2 miniconda-3.7.0 miniconda-3.8.3 miniconda-3.9.1 miniconda-3.10.1 miniconda-3.16.0 miniconda-3.18.3 miniconda2-latest miniconda2-3.18.3 miniconda2-3.19.0 miniconda2-4.0.5 miniconda2-4.1.11 miniconda2-4.3.14 miniconda2-4.3.21 miniconda2-4.3.27 miniconda2-4.3.30 miniconda2-4.3.31 miniconda2-4.4.10 miniconda2-4.5.1 miniconda2-4.5.4 miniconda2-4.5.11 miniconda2-4.5.12 miniconda2-4.6.14 miniconda2-4.7.10 miniconda2-4.7.12 miniconda3-latest miniconda3-2.2.2 miniconda3-3.0.0 miniconda3-3.0.4 miniconda3-3.0.5 miniconda3-3.3.0 miniconda3-3.4.2 miniconda3-3.7.0 miniconda3-3.8.3 miniconda3-3.9.1 miniconda3-3.10.1 miniconda3-3.16.0 miniconda3-3.18.3 miniconda3-3.19.0 miniconda3-4.0.5 miniconda3-4.1.11 miniconda3-4.2.12 miniconda3-4.3.11 miniconda3-4.3.14 miniconda3-4.3.21 miniconda3-4.3.27 miniconda3-4.3.30 miniconda3-4.3.31 miniconda3-4.4.10 miniconda3-4.5.1 miniconda3-4.5.4 miniconda3-4.5.11 miniconda3-4.5.12 miniconda3-4.6.14 miniconda3-4.7.10 miniconda3-4.7.12 pypy-c-jit-latest pypy-c-nojit-latest pypy-dev pypy-stm-2.3 pypy-stm-2.5.1 pypy-1.5-src pypy-1.5 pypy-1.6 pypy-1.7 pypy-1.8 pypy-1.9 pypy-2.0-src pypy-2.0 pypy-2.0.1-src pypy-2.0.1 pypy-2.0.2-src pypy-2.0.2 pypy-2.1-src pypy-2.1 pypy-2.2-src pypy-2.2 pypy-2.2.1-src pypy-2.2.1 pypy-2.3-src pypy-2.3 pypy-2.3.1-src pypy-2.3.1 pypy-2.4.0-src pypy-2.4.0 pypy-2.5.0-src pypy-2.5.0 pypy-2.5.1-src pypy-2.5.1 pypy-2.6.0-src pypy-2.6.0 pypy-2.6.1-src pypy-2.6.1 pypy-4.0.0-src pypy-4.0.0 pypy-4.0.1-src pypy-4.0.1 pypy-5.0.0-src pypy-5.0.0 pypy-5.0.1-src pypy-5.0.1 pypy-5.1-src pypy-5.1 pypy-5.1.1-src pypy-5.1.1 pypy-5.3-src pypy-5.3 pypy-5.3.1-src pypy-5.3.1 pypy-5.4-src pypy-5.4 pypy-5.4.1-src pypy-5.4.1 pypy-5.6.0-src pypy-5.6.0 pypy-5.7.0-src pypy-5.7.0 pypy-5.7.1-src pypy-5.7.1 pypy2-5.3-src pypy2-5.3 pypy2-5.3.1-src pypy2-5.3.1 pypy2-5.4-src pypy2-5.4 pypy2-5.4.1-src pypy2-5.4.1 pypy2-5.6.0-src pypy2-5.6.0 pypy2-5.7.0-src pypy2-5.7.0 pypy2-5.7.1-src pypy2-5.7.1 pypy2.7-5.8.0-src pypy2.7-5.8.0 pypy2.7-5.9.0-src pypy2.7-5.9.0 pypy2.7-5.10.0-src pypy2.7-5.10.0 pypy2.7-6.0.0-src pypy2.7-6.0.0 pypy2.7-7.0.0-src pypy2.7-7.0.0 pypy2.7-7.1.0-src pypy2.7-7.1.0 pypy2.7-7.1.1-src pypy2.7-7.1.1 pypy2.7-7.2.0-src pypy2.7-7.2.0 pypy2.7-7.3.0-src pypy2.7-7.3.0 pypy2.7-7.3.1-src pypy2.7-7.3.1 pypy3-dev pypy3-2.3.1-src pypy3-2.3.1 pypy3-2.4.0-src pypy3-2.4.0 pypy3.3-5.2-alpha1-src pypy3.3-5.2-alpha1 pypy3.3-5.5-alpha-src pypy3.3-5.5-alpha pypy3.5-c-jit-latest pypy3.5-5.7-beta-src pypy3.5-5.7-beta pypy3.5-5.7.1-beta-src pypy3.5-5.7.1-beta pypy3.5-5.8.0-src pypy3.5-5.8.0 pypy3.5-5.9.0-src pypy3.5-5.9.0 pypy3.5-5.10.0-src pypy3.5-5.10.0 pypy3.5-5.10.1-src pypy3.5-5.10.1 pypy3.5-6.0.0-src pypy3.5-6.0.0 pypy3.5-7.0.0-src pypy3.5-7.0.0 pypy3.6-7.0.0-src pypy3.6-7.0.0 pypy3.6-7.1.0-src pypy3.6-7.1.0 pypy3.6-7.1.1-src pypy3.6-7.1.1 pypy3.6-7.2.0-src pypy3.6-7.2.0 pypy3.6-7.3.0-src pypy3.6-7.3.0 pypy3.6-7.3.1-src pypy3.6-7.3.1 pyston-0.5.1 pyston-0.6.0 pyston-0.6.1 stackless-dev stackless-2.7-dev stackless-2.7.2 stackless-2.7.3 stackless-2.7.4 stackless-2.7.5 stackless-2.7.6 stackless-2.7.7 stackless-2.7.8 stackless-2.7.9 stackless-2.7.10 stackless-2.7.11 stackless-2.7.12 stackless-2.7.14 stackless-3.2.2 stackless-3.2.5 stackless-3.3.5 stackless-3.3.7 stackless-3.4-dev stackless-3.4.1 stackless-3.4.2 stackless-3.4.7 stackless-3.5.4 stackless-3.7.5 tal@tal-HP-Notebook:~$
when i type in pyenv versions it gives me:

Output:
tal@tal-HP-Notebook:~$ pyenv versions system * 3.8.3 (set by /home/tal/.pyenv/version) tal@tal-HP-Notebook:~$
and pip -V gives:

Output:
tal@tal-HP-Notebook:~$ pip -V pip 20.1.1 from /home/tal/.local/lib/python3.7/site-packages/pip (python 3.7) tal@tal-HP-Notebook:~$
Reply
#29
Have you done what i posted?
Also you shall use this command.
pyenv global 3.8.3
Then test pip -V after.
Reply
#30
i did,
i typed in pyenv global 3.8.3
it simply returned the next command line...

when i typed pip -V afterwards, it gave me the same output as before
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020