  
  dnl generate java bindings or not
  AC_MSG_CHECKING([whether to generate java bindings or not])
-@@ -111,6 +117,9 @@ AC_HELP_STRING(
+@@ -111,6 +135,9 @@ AC_HELP_STRING(
  esac],[enable_owr_java=no])
  AC_MSG_RESULT([$enable_owr_java])
  if test "x$enable_owr_java" = xyes; then

Detect and subst all needed Android and iOS INCLUDES/LIBS in configure.ac, and
do Android-specific quirks
---
 configure.ac    | 47 ++++++++++++++++++++++++++++++++++++++++-------
 owr/Makefile.am |  3 ++-
 2 files changed, 42 insertions(+), 8 deletions(-)

diff --git a/configure.ac b/configure.ac
index 992540e..a603ce6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -84,9 +84,15 @@ dnl pick dependencies and build flags based on OS
 case "$host_os" in
   darwin*)
     is_apple=yes
-    OWR_DEVICE_LIST_EXT_LIBS="-framework AVFoundation"
+    OWR_DEVICE_LIST_EXT_LIBS="-framework AssetsLibrary -framework CoreMedia
+      -framework CoreVideo -framework AVFoundation -framework Foundation
+      -framework OpenGLES -framework CoreAudio -framework AudioToolbox
+      -weak_framework VideoToolbox -lc++ "
     ;;
   linux-android*)
+    is_android=yes

From f0314a43b00b5380391641a1963b794d5c2f9920 Mon Sep 17 00:00:00 2001
From: Nirbheek Chauhan <nirbheek@centricular.com>
Date: Tue, 17 Feb 2015 05:15:04 +0530
Subject: [PATCH 6/6] Fix build on Android and iOS when not using build.sh
