mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-08-26 15:14:45 +03:00
Fallback to default paths linux paths if no dpkg-architecture exists
This commit is contained in:
parent
4407cb6507
commit
303220cafe
4
setup.py
4
setup.py
|
@ -336,7 +336,7 @@ class pil_build_ext(build_ext):
|
||||||
elif sys.platform.startswith("linux"):
|
elif sys.platform.startswith("linux"):
|
||||||
arch_tp = (plat.processor(), plat.architecture()[0])
|
arch_tp = (plat.processor(), plat.architecture()[0])
|
||||||
# This should be correct on debian derivatives.
|
# This should be correct on debian derivatives.
|
||||||
if os.path.exists('/etc/debian_version'):
|
if os.path.exists('/etc/debian_version') and _cmd_exists('dpkg-architecture'):
|
||||||
# If this doesn't work, don't just silently patch
|
# If this doesn't work, don't just silently patch
|
||||||
# downstream because it's going to break when people
|
# downstream because it's going to break when people
|
||||||
# try to build pillow from source instead of
|
# try to build pillow from source instead of
|
||||||
|
@ -389,7 +389,7 @@ class pil_build_ext(build_ext):
|
||||||
os.path.join(os.environ['ANDROID_ROOT'],
|
os.path.join(os.environ['ANDROID_ROOT'],
|
||||||
'lib'))
|
'lib'))
|
||||||
|
|
||||||
elif sys.platform.startswith("gnu"):
|
elif sys.platform.startswith("gnu") and _cmd_exists('dpkg-architecture'):
|
||||||
self.add_multiarch_paths()
|
self.add_multiarch_paths()
|
||||||
|
|
||||||
elif sys.platform.startswith("freebsd"):
|
elif sys.platform.startswith("freebsd"):
|
||||||
|
|
Loading…
Reference in New Issue
Block a user