mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-26 01:46:18 +03:00
flake8
This commit is contained in:
parent
951923f755
commit
eb73fe3bdb
|
@ -13,8 +13,8 @@ def setup_vms():
|
||||||
ret = []
|
ret = []
|
||||||
for py in pythons.keys():
|
for py in pythons.keys():
|
||||||
for arch in ('', X64_EXT):
|
for arch in ('', X64_EXT):
|
||||||
ret.append("virtualenv -p c:/Python%s%s/python.exe --clear %s%s%s" %
|
ret.append("virtualenv -p c:/Python%s%s/python.exe --clear %s%s%s"
|
||||||
(py, arch, VIRT_BASE, py, arch))
|
% (py, arch, VIRT_BASE, py, arch))
|
||||||
ret.append("%s%s%s\Scripts\pip.exe install nose" %
|
ret.append("%s%s%s\Scripts\pip.exe install nose" %
|
||||||
(VIRT_BASE, py, arch))
|
(VIRT_BASE, py, arch))
|
||||||
if py == '26':
|
if py == '26':
|
||||||
|
@ -109,13 +109,15 @@ def main(op):
|
||||||
scripts.append((py_version,
|
scripts.append((py_version,
|
||||||
"\n".join([header(op),
|
"\n".join([header(op),
|
||||||
build_one(py_version,
|
build_one(py_version,
|
||||||
compilers[(compiler_version, 32)]),
|
compilers[(compiler_version,
|
||||||
|
32)]),
|
||||||
footer()])))
|
footer()])))
|
||||||
|
|
||||||
scripts.append(("%s%s" % (py_version, X64_EXT),
|
scripts.append(("%s%s" % (py_version, X64_EXT),
|
||||||
"\n".join([header(op),
|
"\n".join([header(op),
|
||||||
build_one("%sx64" % py_version,
|
build_one("%sx64" % py_version,
|
||||||
compilers[(compiler_version, 64)]),
|
compilers[(compiler_version,
|
||||||
|
64)]),
|
||||||
footer()])))
|
footer()])))
|
||||||
|
|
||||||
results = map(run_script, scripts)
|
results = map(run_script, scripts)
|
||||||
|
|
|
@ -4,7 +4,7 @@ from untar import untar
|
||||||
import os
|
import os
|
||||||
import hashlib
|
import hashlib
|
||||||
|
|
||||||
from config import *
|
from config import bin_libs, compilers, compiler_fromEnv, libs
|
||||||
|
|
||||||
|
|
||||||
def _relpath(*args):
|
def _relpath(*args):
|
||||||
|
@ -64,10 +64,12 @@ def fetch_libs():
|
||||||
if name == 'openjpeg':
|
if name == 'openjpeg':
|
||||||
filename = check_hash(fetch(lib['url']), lib['hash'])
|
filename = check_hash(fetch(lib['url']), lib['hash'])
|
||||||
for compiler in compilers.values():
|
for compiler in compilers.values():
|
||||||
if not os.path.exists(os.path.join(build_dir, lib['dir']+compiler['inc_dir'])):
|
if not os.path.exists(os.path.join(
|
||||||
|
build_dir, lib['dir']+compiler['inc_dir'])):
|
||||||
extract(filename, build_dir)
|
extract(filename, build_dir)
|
||||||
os.rename(os.path.join(build_dir, lib['dir']),
|
os.rename(os.path.join(build_dir, lib['dir']),
|
||||||
os.path.join(build_dir, lib['dir']+compiler['inc_dir']))
|
os.path.join(
|
||||||
|
build_dir, lib['dir']+compiler['inc_dir']))
|
||||||
else:
|
else:
|
||||||
extract(check_hash(fetch(lib['url']), lib['hash']), build_dir)
|
extract(check_hash(fetch(lib['url']), lib['hash']), build_dir)
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,8 @@ pythons = {#'26': 7,
|
||||||
VIRT_BASE = "c:/vp/"
|
VIRT_BASE = "c:/vp/"
|
||||||
X64_EXT = os.environ.get('X64_EXT', "x64")
|
X64_EXT = os.environ.get('X64_EXT', "x64")
|
||||||
|
|
||||||
libs = {'zlib': {
|
libs = {
|
||||||
|
'zlib': {
|
||||||
'url': 'http://zlib.net/zlib128.zip',
|
'url': 'http://zlib.net/zlib128.zip',
|
||||||
'hash': 'md5:126f8676442ffbd97884eb4d6f32afb4',
|
'hash': 'md5:126f8676442ffbd97884eb4d6f32afb4',
|
||||||
'dir': 'zlib-1.2.8',
|
'dir': 'zlib-1.2.8',
|
||||||
|
@ -60,14 +61,12 @@ libs = {'zlib': {
|
||||||
'url': 'http://downloads.webmproject.org/releases/webp/libwebp-0.4.3.tar.gz',
|
'url': 'http://downloads.webmproject.org/releases/webp/libwebp-0.4.3.tar.gz',
|
||||||
'hash': 'sha1:1c307a61c4d0018620b4ba9a58e8f48a8d6640ef',
|
'hash': 'sha1:1c307a61c4d0018620b4ba9a58e8f48a8d6640ef',
|
||||||
'dir': 'libwebp-0.4.3',
|
'dir': 'libwebp-0.4.3',
|
||||||
|
|
||||||
},
|
},
|
||||||
'openjpeg': {
|
'openjpeg': {
|
||||||
'url': SF_MIRROR+'/project/openjpeg/openjpeg/2.1.0/openjpeg-2.1.0.tar.gz',
|
'url': SF_MIRROR+'/project/openjpeg/openjpeg/2.1.0/openjpeg-2.1.0.tar.gz',
|
||||||
'hash': 'md5:f6419fcc233df84f9a81eb36633c6db6',
|
'hash': 'md5:f6419fcc233df84f9a81eb36633c6db6',
|
||||||
'dir': 'openjpeg-2.1.0',
|
'dir': 'openjpeg-2.1.0',
|
||||||
},
|
},
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bin_libs = {
|
bin_libs = {
|
||||||
|
@ -78,7 +77,8 @@ bin_libs = {
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
compilers = {(7, 64): {
|
compilers = {
|
||||||
|
(7, 64): {
|
||||||
'env_version': 'v7.0',
|
'env_version': 'v7.0',
|
||||||
'vc_version': '2008',
|
'vc_version': '2008',
|
||||||
'env_flags': '/x64 /xp',
|
'env_flags': '/x64 /xp',
|
||||||
|
@ -94,7 +94,6 @@ compilers = {(7, 64): {
|
||||||
'platform': 'Win32',
|
'platform': 'Win32',
|
||||||
'webp_platform': 'x86',
|
'webp_platform': 'x86',
|
||||||
},
|
},
|
||||||
|
|
||||||
(7.1, 64): {
|
(7.1, 64): {
|
||||||
'env_version': 'v7.1',
|
'env_version': 'v7.1',
|
||||||
'vc_version': '2010',
|
'vc_version': '2010',
|
||||||
|
@ -111,7 +110,6 @@ compilers = {(7, 64): {
|
||||||
'platform': 'Win32',
|
'platform': 'Win32',
|
||||||
'webp_platform': 'x86',
|
'webp_platform': 'x86',
|
||||||
},
|
},
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -5,8 +5,8 @@ if __name__ == '__main__':
|
||||||
for version in ['2.6.5', '2.7.6', '3.2.5', '3.3.5', '3.4.3']:
|
for version in ['2.6.5', '2.7.6', '3.2.5', '3.3.5', '3.4.3']:
|
||||||
for platform in ['', '.amd64']:
|
for platform in ['', '.amd64']:
|
||||||
for extension in ['', '.asc']:
|
for extension in ['', '.asc']:
|
||||||
fetch('https://www.python.org/ftp/python/%s/python-%s%s.msi%s' % (
|
fetch('https://www.python.org/ftp/python/%s/python-%s%s.msi%s'
|
||||||
version, version, platform, extension))
|
% (version, version, platform, extension))
|
||||||
|
|
||||||
# find pip, if it's not in the path!
|
# find pip, if it's not in the path!
|
||||||
os.system('pip install virtualenv')
|
os.system('pip install virtualenv')
|
||||||
|
|
|
@ -5,14 +5,15 @@ import os
|
||||||
import glob
|
import glob
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
from config import *
|
from config import pythons, VIRT_BASE, X64_EXT
|
||||||
|
|
||||||
|
|
||||||
def test_one(params):
|
def test_one(params):
|
||||||
python, architecture = params
|
python, architecture = params
|
||||||
try:
|
try:
|
||||||
print("Running: %s, %s" % params)
|
print("Running: %s, %s" % params)
|
||||||
command = [r'%s\%s%s\Scripts\python.exe' % (VIRT_BASE, python, architecture),
|
command = [r'%s\%s%s\Scripts\python.exe' %
|
||||||
|
(VIRT_BASE, python, architecture),
|
||||||
'test-installed.py',
|
'test-installed.py',
|
||||||
'--processes=-0',
|
'--processes=-0',
|
||||||
'--process-timeout=30',
|
'--process-timeout=30',
|
||||||
|
|
Loading…
Reference in New Issue
Block a user