44
55
66class FFMpegRecipe (Recipe ):
7- version = 'n3.4.5 '
7+ version = '007e03348dbd8d3de3eb09022d72c734a8608144 '
88 # Moved to github.com instead of ffmpeg.org to improve download speed
99 url = 'https://github.com/FFmpeg/FFmpeg/archive/{version}.zip'
1010 depends = ['sdl2' ] # Need this to build correct recipe order
@@ -37,22 +37,31 @@ def build_arch(self, arch):
3737 '--enable-nonfree' ,
3838 '--enable-protocol=https,tls_openssl' ,
3939 ]
40- build_dir = Recipe .get_recipe ('openssl' , self .ctx ).get_build_dir (arch .arch )
41- cflags += ['-I' + build_dir + '/include/' ]
40+ build_dir = Recipe .get_recipe (
41+ 'openssl' , self .ctx ).get_build_dir (arch .arch )
42+ cflags += ['-I' + build_dir + '/include/' ,
43+ '-DOPENSSL_API_COMPAT=0x10002000L' ]
4244 ldflags += ['-L' + build_dir ]
4345
4446 if 'ffpyplayer_codecs' in self .ctx .recipe_build_order :
4547 # libx264
4648 flags += ['--enable-libx264' ]
47- build_dir = Recipe .get_recipe ('libx264' , self .ctx ).get_build_dir (arch .arch )
49+ build_dir = Recipe .get_recipe (
50+ 'libx264' , self .ctx ).get_build_dir (arch .arch )
4851 cflags += ['-I' + build_dir + '/include/' ]
4952 ldflags += ['-lx264' , '-L' + build_dir + '/lib/' ]
5053
54+ """
55+ WARNING: DISABLED during migration to ndk19, cause We're
56+ getting a runtime error for a missing symbol.
57+
5158 # libshine
5259 flags += ['--enable-libshine']
5360 build_dir = Recipe.get_recipe('libshine', self.ctx).get_build_dir(arch.arch)
5461 cflags += ['-I' + build_dir + '/include/']
5562 ldflags += ['-lshine', '-L' + build_dir + '/lib/']
63+ ldflags += ['-lm']
64+ """
5665
5766 # Enable all codecs:
5867 flags += [
@@ -79,22 +88,20 @@ def build_arch(self, arch):
7988
8089 # disable binaries / doc
8190 flags += [
82- '--disable-ffmpeg' ,
83- '--disable-ffplay' ,
84- '--disable-ffprobe' ,
85- '--disable-ffserver' ,
91+ '--disable-programs' ,
8692 '--disable-doc' ,
8793 ]
8894
8995 # other flags:
9096 flags += [
9197 '--enable-filter=aresample,resample,crop,adelay,volume,scale' ,
92- '--enable-protocol=file,http' ,
98+ '--enable-protocol=file,http,hls ' ,
9399 '--enable-small' ,
94100 '--enable-hwaccels' ,
95101 '--enable-gpl' ,
96102 '--enable-pic' ,
97103 '--disable-static' ,
104+ '--disable-debug' ,
98105 '--enable-shared' ,
99106 ]
100107
@@ -108,9 +115,13 @@ def build_arch(self, arch):
108115 # android:
109116 flags += [
110117 '--target-os=android' ,
111- '--cross-prefix={}' .format (cross_prefix ),
118+ '--enable-cross-compile' ,
119+ '--cross-prefix={}-' .format (arch .target ),
112120 '--arch={}' .format (arch_flag ),
113- '--sysroot=' + self .ctx .ndk_platform ,
121+ '--strip={}strip' .format (cross_prefix ),
122+ '--sysroot={}' .format (join (self .ctx .ndk_dir , 'toolchains' ,
123+ 'llvm' , 'prebuilt' , 'linux-x86_64' ,
124+ 'sysroot' )),
114125 '--enable-neon' ,
115126 '--prefix={}' .format (realpath ('.' )),
116127 ]
0 commit comments