Skip to content

Commit e205ba1

Browse files
committed
fix jpeg build by merging libjpeg.a and libsimd.a
1 parent 333666d commit e205ba1

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

pythonforandroid/recipes/jpeg/__init__.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
from pythonforandroid.recipe import NDKRecipe
22
from pythonforandroid.logger import shprint
3+
from pythonforandroid.util import current_directory
34
from os.path import join, exists
45
import sh
56

@@ -24,5 +25,11 @@ def prebuild_arch(self, arch):
2425
if not exists(jni_ln):
2526
shprint(sh.ln, '-s', build_dir, jni_ln)
2627

28+
def build_arch(self, arch):
29+
super(JpegRecipe, self).build_arch(arch)
30+
with current_directory(self.get_lib_dir(arch)):
31+
shprint(sh.mv, 'libjpeg.a', 'libjpeg-orig.a')
32+
shprint(sh.ar, '-rcT', 'libjpeg.a', 'libjpeg-orig.a', 'libsimd.a')
33+
2734

2835
recipe = JpegRecipe()

0 commit comments

Comments
 (0)