Skip to content

FFpyplayer fix for NDK 15+ #1201

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 19, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions pythonforandroid/recipes/ffmpeg/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,13 @@
import os
import shutil

# TODO
# Recipe doesn't work with NDK r15c+ yet,
# see: https://github.com/android-ndk/ndk/issues/477


class FFMpegRecipe(Recipe):
version = '3.3.3'
version = '3.4.1'
url = 'http://ffmpeg.org/releases/ffmpeg-{version}.tar.bz2'
depends = ['sdl2'] # Need this to build correct recipe order
opts_depends = ['openssl', 'ffpyplayer_codecs']
patches = ['patches/fix-libshine-configure.patch']
patches = ['patches/configure.patch']

def should_build(self, arch):
build_dir = self.get_build_dir(arch.arch)
Expand Down
21 changes: 21 additions & 0 deletions pythonforandroid/recipes/ffmpeg/patches/configure.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
--- ./configure.orig 2017-12-11 00:35:18.000000000 +0300
+++ ./configure 2017-12-19 09:47:54.104914600 +0300
@@ -4841,9 +4841,6 @@
add_cflags -std=c11 ||
check_cflags -std=c99

-check_cppflags -D_FILE_OFFSET_BITS=64
-check_cppflags -D_LARGEFILE_SOURCE
-
add_host_cppflags -D_ISOC99_SOURCE
check_host_cflags -std=c99
check_host_cflags -Wall
@@ -5979,7 +5976,7 @@
enabled librsvg && require_pkg_config librsvg librsvg-2.0 librsvg-2.0/librsvg/rsvg.h rsvg_handle_render_cairo
enabled librtmp && require_pkg_config librtmp librtmp librtmp/rtmp.h RTMP_Socket
enabled librubberband && require_pkg_config librubberband "rubberband >= 1.8.1" rubberband/rubberband-c.h rubberband_new
-enabled libshine && require_pkg_config libshine shine shine/layer3.h shine_encode_buffer
+enabled libshine && require "shine" shine/layer3.h shine_encode_buffer -lshine
enabled libsmbclient && { use_pkg_config libsmbclient smbclient libsmbclient.h smbc_init ||
require smbclient libsmbclient.h smbc_init -lsmbclient; }
enabled libsnappy && require libsnappy snappy-c.h snappy_compress -lsnappy

This file was deleted.

2 changes: 1 addition & 1 deletion pythonforandroid/recipes/ffpyplayer/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@


class FFPyPlayerRecipe(CythonRecipe):
version = 'master'
version = '6f7568b498715c2da88f061ebad082a042514923'
url = 'https://github.com/matham/ffpyplayer/archive/{version}.zip'
depends = [('python2', 'python3crystax'), 'sdl2', 'ffmpeg']
opt_depends = ['openssl', 'ffpyplayer_codecs']
Expand Down
2 changes: 1 addition & 1 deletion pythonforandroid/recipes/libx264/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@


class LibX264Recipe(Recipe):
version = 'x264-snapshot-20170826-2245-stable' # using mirror url since can't use ftp
version = 'x264-snapshot-20171218-2245-stable' # using mirror url since can't use ftp
url = 'http://mirror.yandex.ru/mirrors/ftp.videolan.org/x264/snapshots/{version}.tar.bz2'

def should_build(self, arch):
Expand Down