Skip to content

Commit a9bc663

Browse files
committed
Indigo changes
1 parent 3ecbe4d commit a9bc663

File tree

10 files changed

+25
-65
lines changed

10 files changed

+25
-65
lines changed

pythonforandroid/bootstraps/common/build/build.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def get_bootstrap_name():
7575
]
7676
# pyc/py
7777
if PYTHON is not None:
78-
BLACKLIST_PATTERNS.append('*.py')
78+
#BLACKLIST_PATTERNS.append('*.py')
7979
if PYTHON_VERSION and int(PYTHON_VERSION[0]) == 2:
8080
# we only blacklist `.pyc` for python2 because in python3 the compiled
8181
# extension is `.pyc` (.pyo files not exists for python >= 3.6)

pythonforandroid/python.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -310,6 +310,7 @@ def create_python_bundle(self, dirn, arch):
310310
c_ext = self.compiled_extension
311311
ensure_dir(modules_dir)
312312
module_filens = (glob.glob(join(modules_build_dir, '*.so')) +
313+
glob.glob(join(modules_build_dir, '*.py')) +
313314
glob.glob(join(modules_build_dir, '*' + c_ext)))
314315
info("Copy {} files into the bundle".format(len(module_filens)))
315316
for filen in module_filens:

pythonforandroid/recipe.py

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,8 @@ class Recipe(with_metaclass(RecipeMeta)):
102102

103103
archs = ['armeabi'] # Not currently implemented properly
104104

105+
download_filename = None
106+
105107
@property
106108
def version(self):
107109
key = 'VERSION_' + self.name
@@ -311,7 +313,10 @@ def download(self):
311313
shprint(sh.mkdir, '-p', join(self.ctx.packages_path, self.name))
312314

313315
with current_directory(join(self.ctx.packages_path, self.name)):
314-
filename = shprint(sh.basename, url).stdout[:-1].decode('utf-8')
316+
if self.download_filename:
317+
filename = self.download_filename
318+
else:
319+
filename = shprint(sh.basename, url).stdout[:-1].decode('utf-8')
315320

316321
do_download = True
317322
marker_filename = '.mark-{}'.format(filename)
@@ -371,12 +376,14 @@ def unpack(self, arch):
371376
if self.url is None:
372377
info('Skipping {} unpack as no URL is set'.format(self.name))
373378
return
374-
375-
filename = shprint(
376-
sh.basename, self.versioned_url).stdout[:-1].decode('utf-8')
377-
ma = match(u'^(.+)#md5=([0-9a-f]{32})$', filename)
378-
if ma: # fragmented URL?
379-
filename = ma.group(1)
379+
if self.download_filename:
380+
filename = self.download_filename
381+
else:
382+
filename = shprint(
383+
sh.basename, self.versioned_url).stdout[:-1].decode('utf-8')
384+
ma = match(u'^(.+)#md5=([0-9a-f]{32})$', filename)
385+
if ma: # fragmented URL?
386+
filename = ma.group(1)
380387

381388
with current_directory(build_dir):
382389
directory_name = self.get_build_dir(arch)
@@ -889,6 +896,9 @@ def build_arch(self, arch):
889896
self.build_compiled_components(arch)
890897
self.install_python_package(arch)
891898

899+
def _get_build_dir(self):
900+
return glob.glob('build/lib.*')[0]
901+
892902
def build_compiled_components(self, arch):
893903
info('Building compiled components in {}'.format(self.name))
894904

@@ -899,7 +909,7 @@ def build_compiled_components(self, arch):
899909
shprint(hostpython, 'setup.py', 'clean', '--all', _env=env)
900910
shprint(hostpython, 'setup.py', self.build_cmd, '-v',
901911
_env=env, *self.setup_extra_args)
902-
build_dir = glob.glob('build/lib.*')[0]
912+
build_dir = self._get_build_dir()
903913
shprint(sh.find, build_dir, '-name', '"*.o"', '-exec',
904914
env['STRIP'], '{}', ';', _env=env)
905915

pythonforandroid/recipes/android/src/setup.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
library_dirs = ['libs/' + os.environ['ARCH']]
55
lib_dict = {
66
'pygame': ['sdl'],
7-
'sdl2': ['SDL2', 'SDL2_image', 'SDL2_mixer', 'SDL2_ttf']
7+
'sdl2': ['SDL2', 'SDL2_image', 'SDL2_mixer', 'SDL2_ttf'],
8+
'webview': ['SDL2', 'SDL2_image', 'SDL2_mixer', 'SDL2_ttf'],
89
}
910
sdl_libs = lib_dict[os.environ['BOOTSTRAP']]
1011

pythonforandroid/recipes/decorator/__init__.py

Lines changed: 0 additions & 13 deletions
This file was deleted.

pythonforandroid/recipes/pytz/__init__.py

Lines changed: 0 additions & 15 deletions
This file was deleted.

pythonforandroid/recipes/ruamel.yaml/__init__.py

Lines changed: 0 additions & 13 deletions
This file was deleted.

pythonforandroid/recipes/ruamel.yaml/disable-pip-req.patch

Lines changed: 0 additions & 11 deletions
This file was deleted.

pythonforandroid/recipes/six/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44

55
class SixRecipe(PythonRecipe):
6-
version = '1.9.0'
6+
version = '1.12.0'
77
url = 'https://pypi.python.org/packages/source/s/six/six-{version}.tar.gz'
88
depends = [('python2', 'python2legacy', 'python3', 'python3crystax')]
99
# this recipe seems to control the dependency graph in some way, because

pythonforandroid/recipes/sqlite3/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55

66

77
class Sqlite3Recipe(NDKRecipe):
8-
version = '3.15.1'
8+
version = '3.26.0'
99
# Don't forget to change the URL when changing the version
10-
url = 'https://www.sqlite.org/2016/sqlite-amalgamation-3150100.zip'
10+
url = "https://sqlite.org/2018/sqlite-autoconf-3260000.tar.gz"
1111
generated_libraries = ['sqlite3']
1212

1313
def should_build(self, arch):

0 commit comments

Comments
 (0)