Skip to content

Commit eeebb8b

Browse files
committed
Enable Android and iOS
1 parent f722323 commit eeebb8b

File tree

3 files changed

+18
-1
lines changed

3 files changed

+18
-1
lines changed

ports/libvmaf/android-off_t.patch

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
--- a/libvmaf/src/meson.build
2+
+++ b/libvmaf/src/meson.build
3+
@@ -13,6 +13,13 @@ if cc.get_id() != 'msvc'
4+
'-pedantic',
5+
'-DOC_NEW_STYLE_INCLUDES',
6+
]
7+
+ # If the target is Android, define _LIBCPP_HAS_NO_OFF_T_FUNCTIONS unconditionally
8+
+ # to work around the fact that meson always defines _FILE_OFFSET_BITS=64, which
9+
+ # causes issues for API levels below 24 in 32-bit architectures.
10+
+ # See https://github.com/mesonbuild/meson/issues/3049 for more details.
11+
+ if target_machine.system() == 'android'
12+
+ vmaf_cflags_common += '-D_LIBCPP_HAS_NO_OFF_T_FUNCTIONS'
13+
+ endif
14+
else
15+
vmaf_cflags_common = [
16+
'-wd4028', # parameter different from declaration

ports/libvmaf/portfile.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ vcpkg_from_github(
66
HEAD_REF master
77
PATCHES
88
no-tools.patch
9+
android-off_t.patch
910
)
1011

1112
vcpkg_find_acquire_program(NASM)

ports/libvmaf/vcpkg.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"description": "libvmaf is a library developed by Netflix to compute the VMAF (Video Multi-Method Assessment Fusion) metric.",
55
"homepage": "https://github.com/Netflix/vmaf",
66
"license": "BSD-2-Clause-Patent",
7-
"supports": "!windows & !android & !ios",
7+
"supports": "!windows",
88
"dependencies": [
99
{
1010
"name": "vcpkg-tool-meson",

0 commit comments

Comments
 (0)