Skip to content
Snippets Groups Projects
Commit 43f2a2f3 authored by Vittorio Giovara's avatar Vittorio Giovara Committed by Tristan Matthews
Browse files

configure: check if we are compiling for android

Enable relevant portions of code if we are.

Change-Id: I59753a42dce1ba4fad23f6bdf1895146da92fa0e
Refs: #46972
parent 5d4dfda8
No related branches found
No related tags found
No related merge requests found
...@@ -74,6 +74,19 @@ AC_COMPILE_IFELSE( ...@@ -74,6 +74,19 @@ AC_COMPILE_IFELSE(
AC_MSG_RESULT([$CLANG]) AC_MSG_RESULT([$CLANG])
dnl Check if we are compiling for android
AC_MSG_CHECKING([if compiling for android])
AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM([], [[
#ifndef __ANDROID__
not android
#endif
]])],
[ANDROID=yes], [ANDROID=no])
AC_MSG_RESULT([$ANDROID])
AM_CONDITIONAL([USE_ANDROID], test "x$ANDROID" = "xyes")
dnl dnl
dnl Check for the contrib directory dnl Check for the contrib directory
dnl dnl
...@@ -475,6 +488,7 @@ AS_IF([test "x$enable_debug" = "xyes"], ...@@ -475,6 +488,7 @@ AS_IF([test "x$enable_debug" = "xyes"],
dnl What Makefiles to generate dnl What Makefiles to generate
#TODO: split this list across where the relevant check is performed
AC_CONFIG_FILES([Makefile \ AC_CONFIG_FILES([Makefile \
src/Makefile \ src/Makefile \
src/sip/Makefile \ src/sip/Makefile \
...@@ -489,6 +503,7 @@ AC_CONFIG_FILES([Makefile \ ...@@ -489,6 +503,7 @@ AC_CONFIG_FILES([Makefile \
src/audio/codecs/Makefile \ src/audio/codecs/Makefile \
src/config/Makefile \ src/config/Makefile \
src/client/Makefile \ src/client/Makefile \
src/client/android/Makefile \
src/hooks/Makefile \ src/hooks/Makefile \
src/history/Makefile \ src/history/Makefile \
src/video/Makefile \ src/video/Makefile \
......
...@@ -18,6 +18,11 @@ VIDEO_STUB = videomanager_stub.cpp ...@@ -18,6 +18,11 @@ VIDEO_STUB = videomanager_stub.cpp
noinst_HEADERS += videomanager.h noinst_HEADERS += videomanager.h
endif endif
if USE_ANDROID
SUBDIRS=android
libclient_la_LIBADD = android/libclient_android.la
else
if USE_DBUS if USE_DBUS
SUBDIRS=dbus SUBDIRS=dbus
...@@ -29,6 +34,7 @@ STUB_SRC = client.cpp \ ...@@ -29,6 +34,7 @@ STUB_SRC = client.cpp \
$(PRESENCE_STUB) \ $(PRESENCE_STUB) \
$(VIDEO_STUB) $(VIDEO_STUB)
endif endif
endif # USE_ANDROID
libclient_la_SOURCES = callmanager.cpp \ libclient_la_SOURCES = callmanager.cpp \
configurationmanager.cpp \ configurationmanager.cpp \
......
include $(top_srcdir)/globals.mak
noinst_LTLIBRARIES = libclient_android.la
libclient_android_la_SOURCES = callmanager_jni.cpp \
configurationmanager_jni.cpp
if SFL_PRESENCE
libclient_android_la_SOURCES += presencemanager_jni.cpp
endif
noinst_HEADERS = jni_callbacks.h
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment