mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-24 17:06:16 +03:00
update winbuild documentation
This commit is contained in:
parent
5d0e37e255
commit
466aa7e6c4
|
@ -18,12 +18,12 @@ The following is a simplified version of the script used on AppVeyor:
|
||||||
```
|
```
|
||||||
set PYTHON=C:\Python38\bin
|
set PYTHON=C:\Python38\bin
|
||||||
cd /D C:\Pillow\winbuild
|
cd /D C:\Pillow\winbuild
|
||||||
C:\Python39\bin\python.exe build_prepare.py -v --depends=C:\pillow-depends
|
%PYTHON%\python.exe build_prepare.py -v --depends=C:\pillow-depends
|
||||||
build\build_dep_all.cmd
|
build\build_dep_all.cmd
|
||||||
build\build_pillow.cmd install
|
|
||||||
cd ..
|
cd ..
|
||||||
|
%PYTHON%\python.exe -m pip install -v -C raqm=vendor -C fribidi=vendor .
|
||||||
path C:\Pillow\winbuild\build\bin;%PATH%
|
path C:\Pillow\winbuild\build\bin;%PATH%
|
||||||
%PYTHON%\python.exe selftest.py
|
%PYTHON%\python.exe selftest.py
|
||||||
%PYTHON%\python.exe -m pytest -vx --cov PIL --cov Tests --cov-report term --cov-report xml Tests
|
%PYTHON%\python.exe -m pytest -vx --cov PIL --cov Tests --cov-report term --cov-report xml Tests
|
||||||
build\build_pillow.cmd bdist_wheel
|
%PYTHON%\python.exe -m pip wheel -v -C raqm=vendor -C fribidi=vendor .
|
||||||
```
|
```
|
||||||
|
|
|
@ -42,11 +42,10 @@ Run ``build_prepare.py`` to configure the build::
|
||||||
|
|
||||||
usage: winbuild\build_prepare.py [-h] [-v] [-d PILLOW_BUILD]
|
usage: winbuild\build_prepare.py [-h] [-v] [-d PILLOW_BUILD]
|
||||||
[--depends PILLOW_DEPS]
|
[--depends PILLOW_DEPS]
|
||||||
[--architecture {x86,x64,ARM64}]
|
[--architecture {x86,x64,ARM64}] [--nmake]
|
||||||
[--python PYTHON] [--executable EXECUTABLE]
|
[--no-imagequant] [--no-fribidi]
|
||||||
[--nmake] [--no-imagequant] [--no-fribidi]
|
|
||||||
|
|
||||||
Download dependencies and generate build scripts for Pillow.
|
Download and generate build scripts for Pillow dependencies.
|
||||||
|
|
||||||
options:
|
options:
|
||||||
-h, --help show this help message and exit
|
-h, --help show this help message and exit
|
||||||
|
@ -58,17 +57,13 @@ Run ``build_prepare.py`` to configure the build::
|
||||||
'winbuild\depends')
|
'winbuild\depends')
|
||||||
--architecture {x86,x64,ARM64}
|
--architecture {x86,x64,ARM64}
|
||||||
build architecture (default: same as host Python)
|
build architecture (default: same as host Python)
|
||||||
--python PYTHON Python install directory (default: use host Python)
|
|
||||||
--executable EXECUTABLE
|
|
||||||
Python executable (default: use host Python)
|
|
||||||
--nmake build dependencies using NMake instead of Ninja
|
--nmake build dependencies using NMake instead of Ninja
|
||||||
--no-imagequant skip GPL-licensed optional dependency libimagequant
|
--no-imagequant skip GPL-licensed optional dependency libimagequant
|
||||||
--no-fribidi, --no-raqm
|
--no-fribidi, --no-raqm
|
||||||
skip LGPL-licensed optional dependency FriBiDi
|
skip LGPL-licensed optional dependency FriBiDi
|
||||||
|
|
||||||
Arguments can also be supplied using the environment variables PILLOW_BUILD,
|
Arguments can also be supplied using the environment variables PILLOW_BUILD,
|
||||||
PILLOW_DEPS, ARCHITECTURE, PYTHON, EXECUTABLE. See winbuild\build.rst for more
|
PILLOW_DEPS, ARCHITECTURE. See winbuild\build.rst for more information.
|
||||||
information.
|
|
||||||
|
|
||||||
**Warning:** The build directory is wiped when ``build_prepare.py`` is run.
|
**Warning:** The build directory is wiped when ``build_prepare.py`` is run.
|
||||||
|
|
||||||
|
@ -86,14 +81,16 @@ or run the individual scripts in order to build each dependency separately.
|
||||||
Building Pillow
|
Building Pillow
|
||||||
---------------
|
---------------
|
||||||
|
|
||||||
Once the dependencies are built, run
|
Once the dependencies are built, make sure the required environment variables
|
||||||
``winbuild\build\build_pillow.cmd install`` to build and install
|
are set by running ``winbuild\build\build_env.cmd`` and install Pillow with pip::
|
||||||
Pillow for the selected version of Python.
|
|
||||||
``winbuild\build\build_pillow.cmd bdist_wheel`` will build wheels
|
|
||||||
instead of installing Pillow.
|
|
||||||
|
|
||||||
You can also use ``winbuild\build\build_pillow.cmd --inplace develop`` to build
|
winbuild\build\build_env.cmd
|
||||||
and install Pillow in develop mode (instead of ``python3 -m pip install --editable``).
|
python.exe -m pip install -v -C raqm=vendor -C fribidi=vendor .
|
||||||
|
|
||||||
|
To build a wheel instead, run::
|
||||||
|
|
||||||
|
winbuild\build\build_env.cmd
|
||||||
|
python.exe -m pip wheel -v -C raqm=vendor -C fribidi=vendor .
|
||||||
|
|
||||||
Testing Pillow
|
Testing Pillow
|
||||||
--------------
|
--------------
|
||||||
|
@ -112,11 +109,12 @@ The following is a simplified version of the script used on AppVeyor::
|
||||||
|
|
||||||
set PYTHON=C:\Python38\bin
|
set PYTHON=C:\Python38\bin
|
||||||
cd /D C:\Pillow\winbuild
|
cd /D C:\Pillow\winbuild
|
||||||
C:\Python39\bin\python.exe build_prepare.py -v --depends C:\pillow-depends
|
%PYTHON%\python.exe build_prepare.py -v --depends C:\pillow-depends
|
||||||
build\build_dep_all.cmd
|
build\build_dep_all.cmd
|
||||||
build\build_pillow.cmd install
|
build\build_env.cmd
|
||||||
cd ..
|
cd ..
|
||||||
|
%PYTHON%\python.exe -m pip install -v -C raqm=vendor -C fribidi=vendor .
|
||||||
path C:\Pillow\winbuild\build\bin;%PATH%
|
path C:\Pillow\winbuild\build\bin;%PATH%
|
||||||
%PYTHON%\python.exe selftest.py
|
%PYTHON%\python.exe selftest.py
|
||||||
%PYTHON%\python.exe -m pytest -vx --cov PIL --cov Tests --cov-report term --cov-report xml Tests
|
%PYTHON%\python.exe -m pytest -vx --cov PIL --cov Tests --cov-report term --cov-report xml Tests
|
||||||
build\build_pillow.cmd bdist_wheel
|
%PYTHON%\python.exe -m pip wheel -v -C raqm=vendor -C fribidi=vendor .
|
||||||
|
|
Loading…
Reference in New Issue
Block a user