Skip to content

Commit c06cf52

Browse files
authored
Merge pull request kivy#1495 from misl6/master
Fixes audiostream recipe on Python3
2 parents 1636748 + 6610a44 commit c06cf52

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

pythonforandroid/recipes/audiostream/__init__.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ class AudiostreamRecipe(CythonRecipe):
77
version = 'master'
88
url = 'https://github.com/kivy/audiostream/archive/{version}.zip'
99
name = 'audiostream'
10-
depends = ['python2', ('sdl', 'sdl2'), 'pyjnius']
10+
depends = [('python2', 'python3'), ('sdl', 'sdl2'), 'pyjnius']
1111

1212
def get_recipe_env(self, arch):
1313
env = super(AudiostreamRecipe, self).get_recipe_env(arch)
@@ -18,12 +18,14 @@ def get_recipe_env(self, arch):
1818
sdl_include = 'SDL2'
1919
sdl_mixer_include = 'SDL2_mixer'
2020
env['USE_SDL2'] = 'True'
21-
env['SDL2_INCLUDE_DIR'] = '/home/kivy/.buildozer/android/platform/android-ndk-r9c/sources/android/support/include'
21+
env['SDL2_INCLUDE_DIR'] = join(self.ctx.bootstrap.build_dir, 'jni', 'SDL', 'include')
2222

2323
env['CFLAGS'] += ' -I{jni_path}/{sdl_include}/include -I{jni_path}/{sdl_mixer_include}'.format(
2424
jni_path=join(self.ctx.bootstrap.build_dir, 'jni'),
2525
sdl_include=sdl_include,
2626
sdl_mixer_include=sdl_mixer_include)
27+
env['NDKPLATFORM'] = self.ctx.ndk_platform
28+
env['LIBLINK'] = 'NOTNONE' # Hacky fix. Needed by audiostream setup.py
2729
return env
2830

2931

0 commit comments

Comments
 (0)