analitics

Pages

Showing posts with label wheel. Show all posts
Showing posts with label wheel. Show all posts

Tuesday, February 1, 2022

Python 3.10.0 : How to using wheels.

Wheels are the last component of the Python ecosystem that helps to make package installs easy.
Wheel and Egg are both packaging formats.
The Egg format was introduced by setuptools in 2004, whereas the Wheel format was introduced by PEP 427 in 2012.
You can use it easy with these commands:
C:\Python310>python.exe -m pip install wheel
Collecting wheel
  Downloading wheel-0.37.1-py2.py3-none-any.whl (35 kB)
Installing collected packages: wheel
  WARNING: The script wheel.exe is installed in 'C:\Python310\Scripts' which is not on PATH.
  Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
Successfully installed wheel-0.37.1

C:\Python310>python.exe -m pip install --upgrade pip setuptools wheel
Requirement already satisfied: pip in c:\python310\lib\site-packages (21.3.1)
Collecting pip
  Downloading pip-22.0.2-py3-none-any.whl (2.1 MB)
     |████████████████████████████████| 2.1 MB 2.2 MB/s
Requirement already satisfied: setuptools in c:\python310\lib\site-packages (57.4.0)
Collecting setuptools
  Downloading setuptools-60.6.0-py3-none-any.whl (953 kB)
     |████████████████████████████████| 953 kB 6.8 MB/s
Requirement already satisfied: wheel in c:\python310\lib\site-packages (0.37.1)
Installing collected packages: setuptools, pip
  Attempting uninstall: setuptools
    Found existing installation: setuptools 57.4.0
    Uninstalling setuptools-57.4.0:
      Successfully uninstalled setuptools-57.4.0
  Attempting uninstall: pip
    Found existing installation: pip 21.3.1
    Uninstalling pip-21.3.1:
      Successfully uninstalled pip-21.3.1
  WARNING: The scripts pip.exe, pip3.10.exe and pip3.exe are installed in 'C:\Python310\Scripts' which is not on PATH.
  Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
Successfully installed pip-22.0.2 setuptools-60.6.0

Saturday, February 7, 2015

Install PyOpenGL with pip with wheel and WHL file .

This is a old tutorial I wrote about how to install python on windows 8.1 with distribute, pip, virtualenv and virtualenvwrapper-powershell.
Now I will show you how to deal with WHL files and pip wheel.
First you need to install pip under your python folder.
I used in this case Python 2.7 version.
The WHL file and wheel is a ZIP-format archive with a specially formatted filename and the .whl extension.
You can use this :
C:\Python27\Scripts>pip2.7 install wheel
Collecting wheel
  Downloading wheel-0.24.0-py2.py3-none-any.whl (63kB)
    100% |################################| 65kB 682kB/s ta 0:00:011
Installing collected packages: wheel

Successfully installed wheel-0.24.0

C:\Python27\Scripts>pip2.7 install --upgrade pip
Collecting pip from https://pypi.python.org/packages/py2.py3/p/pip/pip-6.0.8-py2
.py3-none-any.whl#md5=41e73fae2c86ba2270ff51c1d86f7e09
  Downloading pip-6.0.8-py2.py3-none-any.whl (1.3MB)
    100% |################################| 1.3MB 952kB/s ta 0:00:01
This will install wheel and update the pip2.7 .
For example, just use next command to install OpenGL python module.
C:\Python27\Scripts>pip2.7 install PyOpenGL
Collecting PyOpenGL
  Downloading PyOpenGL-3.1.0.tar.gz (1.2MB)
    100% |################################| 1.2MB 2.2MB/s ta 0:00:01
Installing collected packages: PyOpenGL
  Running setup.py install for PyOpenGL
Successfully installed PyOpenGL-3.1.0
Also pygame whl working with pip2.7.
I download it from pygame website, from here. Download your version of WHL file ( amd64 is for CPU 64 bits) and your python version (cpxx). Now use this command:
C:\Python27\Scripts>pip2.7.exe install "C:\Downloads\pygame-1.9.2a
0-cp27-none-win_amd64.whl"
...
Installing collected packages: pygame
  Found existing installation: pygame 1.9.1
    DEPRECATION: Uninstalling a distutils installed project (pygame) has been de
precated and will be removed in a future version. This is due to the fact that u
ninstalling a distutils project will only partially uninstall the project.
    Uninstalling pygame-1.9.1:
      Successfully uninstalled pygame-1.9.1

Successfully installed pygame-1.9.2a0