From b41e0910b0fb0b0dcc0c398313ce7697964b695e Mon Sep 17 00:00:00 2001 From: Grant Limberg Date: Wed, 9 Nov 2022 11:11:10 -0800 Subject: [PATCH] Fun times in ~~cleveland~~ NDK-land --- java/jni/Application.mk | 2 +- java/jni/ZT_jniarray.cpp | 1 + osdep/Binder.hpp | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/java/jni/Application.mk b/java/jni/Application.mk index 8613c15ee..7980d8c27 100644 --- a/java/jni/Application.mk +++ b/java/jni/Application.mk @@ -1,5 +1,5 @@ # NDK_TOOLCHAIN_VERSION := clang3.5 APP_STL := c++_static -APP_CPPFLAGS := -Wall -fstack-protector -fexceptions -fno-strict-aliasing -frtti -Wno-deprecated-register -DZT_NO_TYPE_PUNNING=1 +APP_CPPFLAGS := -Wall -fstack-protector -fexceptions -fno-strict-aliasing -frtti -Wno-deprecated-register -DZT_NO_TYPE_PUNNING=1 -DZT_SSO_SUPPORTED=0 -DOMIT_JSON_SUPPORT=1 APP_PLATFORM := android-21 APP_ABI := all diff --git a/java/jni/ZT_jniarray.cpp b/java/jni/ZT_jniarray.cpp index 24ae97c71..a1cae76ed 100644 --- a/java/jni/ZT_jniarray.cpp +++ b/java/jni/ZT_jniarray.cpp @@ -5,6 +5,7 @@ #include "ZT_jniarray.h" #include #include +#include jclass java_util_ArrayList; jmethodID java_util_ArrayList_; diff --git a/osdep/Binder.hpp b/osdep/Binder.hpp index 8ce4e20e2..3236d30b7 100644 --- a/osdep/Binder.hpp +++ b/osdep/Binder.hpp @@ -311,7 +311,7 @@ class Binder { #else const bool gotViaProc = false; #endif -#if ! defined(ZT_SDK) || ! defined(__ANDROID__) // getifaddrs() freeifaddrs() not available on Android +#if ! (defined(ZT_SDK) || defined(__ANDROID__)) // getifaddrs() freeifaddrs() not available on Android if (! gotViaProc) { struct ifaddrs* ifatbl = (struct ifaddrs*)0; struct ifaddrs* ifa;