aboutsummaryrefslogtreecommitdiff
path: root/contrib/depends/patches
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/depends/patches')
-rw-r--r--contrib/depends/patches/android_ndk/api_definition.patch15
-rw-r--r--contrib/depends/patches/libusb/fix_osx_avail.patch12
2 files changed, 15 insertions, 12 deletions
diff --git a/contrib/depends/patches/android_ndk/api_definition.patch b/contrib/depends/patches/android_ndk/api_definition.patch
new file mode 100644
index 000000000..82ef9bad3
--- /dev/null
+++ b/contrib/depends/patches/android_ndk/api_definition.patch
@@ -0,0 +1,15 @@
+CMake 3.10.2 compatibility, see:
+https://github.com/Kitware/CMake/blob/c1e087a9d3af74299d7681c9f9de59e5977a1539/Modules/Platform/Android-Determine.cmake#L105
+
+diff --git a/build/tools/make_standalone_toolchain.py b/build/tools/make_standalone_toolchain.py
+index b8172b2..1984595 100755
+--- a/build/tools/make_standalone_toolchain.py
++++ b/build/tools/make_standalone_toolchain.py
+@@ -208,6 +208,7 @@ def make_clang_scripts(install_dir, triple, api, windows):
+
+ target = '-'.join([arch, 'none', os_name, env])
+ common_flags = '-target {}{}'.format(target, api)
++ common_flags += ' -D__ANDROID_API__={}'.format(api)
+
+ # We only need mstackrealign to fix issues on 32-bit x86 pre-24. After 24,
+ # this consumes an extra register unnecessarily, which can cause issues for
diff --git a/contrib/depends/patches/libusb/fix_osx_avail.patch b/contrib/depends/patches/libusb/fix_osx_avail.patch
deleted file mode 100644
index 2474993f5..000000000
--- a/contrib/depends/patches/libusb/fix_osx_avail.patch
+++ /dev/null
@@ -1,12 +0,0 @@
---- a/libusb/os/darwin_usb.h 2023-03-19 12:07:53
-+++ b/libusb/os/darwin_usb.h 2023-03-19 12:07:47
-@@ -165,7 +165,8 @@
- #define __has_builtin(x) 0 // Compatibility with non-clang compilers.
- #endif
- #if __has_builtin(__builtin_available)
-- #define HAS_CAPTURE_DEVICE() __builtin_available(macOS 10.10, *)
-+// #define HAS_CAPTURE_DEVICE() __builtin_available(macOS 10.10, *)
-+ #define HAS_CAPTURE_DEVICE() 0
- #else
- #define HAS_CAPTURE_DEVICE() 0
- #endif