From 90ddfc61b70cea97dacf33bcd981fb72e27c8da8 Mon Sep 17 00:00:00 2001 From: Fredrik Fornwall Date: Thu, 12 Dec 2019 01:54:06 +0100 Subject: [PATCH] Fix build when targetting Android 7 or later Support for pthread_barrier was introduced in Android 7, so trying to build a custom implementation of that clashes with the system headers. --- libusb/hid.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libusb/hid.c b/libusb/hid.c index 3d2e47a..49ba619 100644 --- a/libusb/hid.c +++ b/libusb/hid.c @@ -51,7 +51,7 @@ #include "hidapi.h" -#ifdef __ANDROID__ +#if defined(__ANDROID__) && __ANDROID_API__ < __ANDROID_API_N__ /* Barrier implementation because Android/Bionic don't have pthread_barrier. This implementation came from Brent Priddy and was posted on