Skip to content

Commit c1bb4d2

Browse files
authored
Update README.md
1 parent 40d36e4 commit c1bb4d2

File tree

1 file changed

+21
-10
lines changed

1 file changed

+21
-10
lines changed

README.md

Lines changed: 21 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
| Platform| Status |
22
| :---: | :---: |
33
| Windows | [![buildstatus](https://ci.appveyor.com/api/projects/status/5kjqpmvll5dwj5jd?svg=true)](https://ci.appveyor.com/project/skvark/opencv-python) |
4-
| Ubuntu| [![Build Status](https://travis-ci.org/skvark/opencv-python.svg?branch=master)](https://travis-ci.org/skvark/opencv-python) |
4+
| Manylinux| [![Build Status](https://travis-ci.org/skvark/opencv-python.svg?branch=master)](https://travis-ci.org/skvark/opencv-python) |
55

66
# OpenCV on wheels
77

88
Work in progress!
99

1010
The aim of this repository is to provide means to package each new [OpenCV release](https://github.com/Itseez/opencv/releases) for the most used Python versions and platforms.
1111

12-
At the same time it allows anyone to build a custom version of OpenCV for any Python version: just fork this repo and modify the ``appveyor.yml`` (I'll add Travis later for OS X and GNU/Linux) to fit your needs.
12+
At the same time it allows anyone to build a custom version of OpenCV for any Python version: just fork this repo and modify the build files and scripts to fit your needs.
1313

1414
## Why?
1515

@@ -31,26 +31,37 @@ The project is structured like a normal Python package with a standard ``setup.p
3131
2. Upgrade pip and install numpy for each Python version
3232
3. Build OpenCV
3333
- tests are disabled, otherwise build time increases too much
34-
- build runs twice, once for 32bit and once for 64bit
35-
- both of these builds produce two ``.pyd`` files, one for py2 and one for py3
36-
4. Copy each ``.pyd`` file one by one to cv2 folder of this project and generate wheel
34+
4. Copy each ``.pyd/.so`` file to cv2 folder of this project and generate wheel
3735
5. Install the generated wheels for each Python version
3836
6. Test that the Python versions can import them
3937
7. TO DO: upload the wheels to PyPi
4038

4139
Currently the ``setup.py`` file parses OpenCV version information from the OpenCV sources. OpenCV depends on numpy, so ``setup.py`` checks the numpy version also with the help of pip.
4240

43-
As described earlier, the ``.pyd`` file is normally copied to site-packages. I don't want to pollute the root folder, so the ``__init__.py`` file in cv2 folder handles the import logic correctly by importing the actual ``.pyd`` module and replacing the imported cv2 package in ``sys.modudes`` with the ``.pyd`` module.
41+
As described earlier, for example the ``.pyd`` file on Windows is normally copied to site-packages. I don't want to pollute the root folder, so the ``__init__.py`` file in cv2 folder handles the import logic correctly by importing the actual ``.pyd`` module and replacing the imported cv2 package in ``sys.modudes`` with the cv2 module to retain backward compatibility.
4442

45-
## Many linux wheels
46-
Linux wheels are built using [manylinux](https://github.com/pypa/python-manylinux-demo)
43+
## Manylinux wheels
44+
45+
Linux wheels are built using [manylinux](https://github.com/pypa/python-manylinux-demo). These wheels should work out of the box for most of the distros out there since they are built against an old version of glibc.
4746

4847
## Versioning
4948

5049
Currently the ``find_version.py`` script searches for the version information from OpenCV sources. The CI build number is then added after the actual OpenCV version to differentiate packages (this repo might have modifications but OpenCV version stays same).
5150

5251
## Supported Python versions
5352

54-
As Python's 2.x releases are slowly approaching legacy state, 2.7.x releases will be the only supported Python 2 versions. On Python 3 side, builds will be run only for the latest release which is at the moment 3.5.1.
53+
#### Windows:
54+
55+
There's a build time limitation (AppVeyor open source builds may take max. 1 hour) which restricts the supported Python versions to two. As Python's 2.x releases are slowly approaching legacy state, 2.7.x releases will be the only supported Python 2 versions on Windows. On Python 3 side, builds will be run only for the latest release.
56+
57+
However, if you wan't to get some other versions, just fork this repo and change the dependencies.
58+
59+
#### Linux
60+
61+
Manylinux wheels are built for all the Python versions which are supported by the manylinux containers.
62+
63+
#### OS X
64+
65+
TODO
66+
5567

56-
There's also a build time limitation (AppVeyor open source builds may take max. 1 hour) which restricts the supported Python versions to two. However, if you wan't to get some other versions, just fork this repo and change the dependencies.

0 commit comments

Comments
 (0)