diff options
author | Christoph Reiter <reiter.christoph@gmail.com> | 2018-11-13 22:20:15 +0100 |
---|---|---|
committer | Christoph Reiter <reiter.christoph@gmail.com> | 2018-11-13 22:20:15 +0100 |
commit | eade7e9f7a88175c14023696591c125cc6fd105a (patch) | |
tree | edabb59ec2417d584c1ec6453ee8a1afe57458f7 /setup.py | |
parent | fe33c56b60ae88ea3ad1632ef8193176a9b1906f (diff) | |
download | pygobject-eade7e9f7a88175c14023696591c125cc6fd105a.tar.gz |
setup.py: Make it possible to build without cairo through an env var. See #250
PYGOBJECT_WITHOUT_PYCAIRO=1 python3 setup.py install
or with a recent pip:
PYGOBJECT_WITHOUT_PYCAIRO=1 pip3 install --no-build-isolation pygobject
I don't see a nice way for telling pip not to require pycairo, so this will
have to do for now.
Diffstat (limited to 'setup.py')
-rwxr-xr-x | setup.py | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -47,8 +47,10 @@ GI_VERSION_REQUIRED = "1.46.0" PYCAIRO_VERSION_REQUIRED = "1.11.1" LIBFFI_VERSION_REQUIRED = "3.0" -WITH_CAIRO = True -"""Set to false if you don't want to build with cairo/pycairo support""" +WITH_CAIRO = not bool(os.environ.get("PYGOBJECT_WITHOUT_PYCAIRO")) +"""Set PYGOBJECT_WITHOUT_PYCAIRO if you don't want to build with +cairo/pycairo support. Note that this option might get removed in the future. +""" def is_dev_version(): |