summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Holesovsky <kendy@collabora.com>2019-02-12 10:15:51 +0100
committerJan Holesovsky <kendy@collabora.com>2019-02-12 10:50:40 +0100
commitd15fc93f312882037f9991335b945f8c3676a43d (patch)
tree5dac187d0b063c35ae43968fb619f4f55ab1d65c
parentdf5565674e94fa6c2dc201c665bf013c4b75e552 (diff)
android: Define MOBILEAPP via config.h.
-rw-r--r--configure.ac3
-rw-r--r--wsd/LOOLWSD.cpp4
2 files changed, 6 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 3e4c919f6..d0d330212 100644
--- a/configure.ac
+++ b/configure.ac
@@ -461,13 +461,16 @@ AS_IF([test "$ENABLE_GTKAPP" = true],
AM_CONDITIONAL([ENABLE_DEBUG], [test "$ENABLE_DEBUG" = "true"])
mobile_app=
+MOBILEAPP=
AC_MSG_CHECKING([Is this a mobile app])
if test "$enable_gtkapp" = "yes" -o "$enable_iosapp" = "yes" -o "$enable_androidapp"; then
AC_MSG_RESULT([Yes])
mobile_app=true;
+ MOBILEAPP=1
else
AC_MSG_RESULT([No])
fi
+AC_DEFINE_UNQUOTED([MOBILEAPP],[$MOBILEAPP],[Define to 1 if this is a mobileapp (eg. Android) build.])
ENABLE_SSL=true
if test "$enable_ssl" != "no" -a "$mobile_app" != "true"; then
diff --git a/wsd/LOOLWSD.cpp b/wsd/LOOLWSD.cpp
index 30beb7b28..a26fb31bb 100644
--- a/wsd/LOOLWSD.cpp
+++ b/wsd/LOOLWSD.cpp
@@ -138,8 +138,10 @@ using Poco::Net::PartHandler;
#ifdef MOBILEAPP
#ifdef IOS
#include "ios.h"
-#else
+#elif GTKAPP
#include "gtk.hpp"
+#elif defined(__ANDROID__)
+#include "androidapp.h"
#endif
#endif