mpv: "whitelist" posix-spawn and strnlen subsitition (#2653)
Some of the Android "features" in mpv are useful (or at least, can be used) in Termux. Whitelist them while we build with --disable- android.
This commit is contained in:
parent
91316d7e79
commit
bc58aafe91
28
packages/mpv/android.patch
Normal file
28
packages/mpv/android.patch
Normal file
@ -0,0 +1,28 @@
|
||||
diff --git a/wscript b/wscript
|
||||
index 750ce3bd1f..d32c7bf645 100644
|
||||
--- a/wscript
|
||||
+++ b/wscript
|
||||
@@ -233,7 +233,7 @@ iconv support use --disable-iconv.",
|
||||
'name': 'posix-spawn-android',
|
||||
'desc': 'spawnp()/kill() Android replacement',
|
||||
'func': check_true,
|
||||
- 'deps': 'android && !posix-spawn-native',
|
||||
+ 'deps': '!posix-spawn-native',
|
||||
},{
|
||||
'name': 'posix-spawn',
|
||||
'desc': 'any spawnp()/kill() support',
|
||||
diff --git a/wscript_build.py b/wscript_build.py
|
||||
index bbe367963f..61bfe312bb 100644
|
||||
--- a/wscript_build.py
|
||||
+++ b/wscript_build.py
|
||||
@@ -495,8 +495,8 @@ def build(ctx):
|
||||
( "osdep/windows_utils.c", "os-cygwin" ),
|
||||
( "osdep/mpv.rc", "win32-executable" ),
|
||||
( "osdep/win32/pthread.c", "win32-internal-pthreads"),
|
||||
- ( "osdep/android/posix-spawn.c", "android"),
|
||||
- ( "osdep/android/strnlen.c", "android"),
|
||||
+ ( "osdep/android/posix-spawn.c" ),
|
||||
+ ( "osdep/android/strnlen.c" ),
|
||||
|
||||
## tree_allocator
|
||||
"ta/ta.c", "ta/ta_talloc.c", "ta/ta_utils.c"
|
@ -1,7 +1,7 @@
|
||||
TERMUX_PKG_HOMEPAGE=https://mpv.io/
|
||||
TERMUX_PKG_DESCRIPTION="Command-line media player"
|
||||
TERMUX_PKG_VERSION=0.28.2
|
||||
TERMUX_PKG_REVISION=1
|
||||
TERMUX_PKG_REVISION=2
|
||||
TERMUX_PKG_SHA256=aada14e025317b5b3e8e58ffaf7902e8b6e4ec347a93d25a7c10d3579426d795
|
||||
TERMUX_PKG_SRCURL=https://github.com/mpv-player/mpv/archive/v${TERMUX_PKG_VERSION}.tar.gz
|
||||
TERMUX_PKG_DEPENDS="ffmpeg, openal-soft, libandroid-glob"
|
||||
|
@ -1,16 +0,0 @@
|
||||
diff --git a/osdep/strnlen.h b/osdep/strnlen.h
|
||||
index 0a971d0ab0..9a8b2a104d 100644
|
||||
--- a/osdep/strnlen.h
|
||||
+++ b/osdep/strnlen.h
|
||||
@@ -19,11 +19,4 @@
|
||||
|
||||
#ifndef MP_OSDEP_STRNLEN
|
||||
#define MP_OSDEP_STRNLEN
|
||||
-
|
||||
-#ifdef __ANDROID__
|
||||
-// strnlen is broken on current android ndk, see https://code.google.com/p/android/issues/detail?id=74741
|
||||
-#include "osdep/android/strnlen.h"
|
||||
-#define strnlen freebsd_strnlen
|
||||
-#endif
|
||||
-
|
||||
#endif
|
Loading…
Reference in New Issue
Block a user