Skip to content
Snippets Groups Projects
Commit 13cceb78 authored by André Anjos's avatar André Anjos :speech_balloon:
Browse files

Depend on PIL, if installed, or fall-back to Pillow otherwise

parent 3f168e1f
No related branches found
No related tags found
No related merge requests found
...@@ -15,6 +15,15 @@ include_dirs = [package_dir] ...@@ -15,6 +15,15 @@ include_dirs = [package_dir]
packages = ['bob-io >= 1.2.2'] packages = ['bob-io >= 1.2.2']
version = '2.0.0a0' version = '2.0.0a0'
# Check if python-imaging means pil or pillow
pil_or_pillow = []
try:
import pkg_resources
pkg_resources.require('pil')
pil_or_pillow.append('pil')
except pkg_resources.DistributionNotFound as e:
pil_or_pillow.append('pillow')
setup( setup(
name='xbob.io', name='xbob.io',
...@@ -33,8 +42,7 @@ setup( ...@@ -33,8 +42,7 @@ setup(
install_requires=[ install_requires=[
'setuptools', 'setuptools',
'xbob.blitz', 'xbob.blitz',
'pillow', ] + pil_or_pillow,
],
namespace_packages=[ namespace_packages=[
"xbob", "xbob",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment