mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-02-07 14:18:25 +00:00
Add libupnp dependency for Android
Fix some issues related to uPnP
This commit is contained in:
parent
3610297d37
commit
04fef5fcca
6 changed files with 246 additions and 10 deletions
|
|
@ -55,13 +55,10 @@ LOCAL_CFLAGS += \
|
|||
-DORTP_INET6 \
|
||||
-DINET6 \
|
||||
-DOSIP_MT \
|
||||
-DHAVE_EXOSIP_GET_VERSION \
|
||||
-DHAVE_EXOSIP_RESET_TRANSPORTS \
|
||||
-DENABLE_TRACE \
|
||||
-DHAVE_CONFIG_H \
|
||||
-DLINPHONE_VERSION=\"$(LINPHONE_VERSION)\" \
|
||||
-DLINPHONE_PLUGINS_DIR=\"\\tmp\" \
|
||||
-DHAVE_EXOSIP_TRYLOCK=1 \
|
||||
-DHAVE_EXOSIP_TLS_VERIFY_CERTIFICATE=1
|
||||
|
||||
LOCAL_CFLAGS += -DIN_LINPHONE
|
||||
|
||||
|
|
@ -79,6 +76,7 @@ endif
|
|||
LOCAL_C_INCLUDES += \
|
||||
$(LOCAL_PATH) \
|
||||
$(LOCAL_PATH)/include \
|
||||
$(LOCAL_PATH)/../build/android \
|
||||
$(LOCAL_PATH)/../oRTP/include \
|
||||
$(LOCAL_PATH)/../mediastreamer2/include \
|
||||
$(LOCAL_PATH)/../../externals/exosip/include \
|
||||
|
|
@ -154,6 +152,11 @@ LOCAL_STATIC_LIBRARIES += \
|
|||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(BUILD_UPNP),1)
|
||||
LOCAL_CFLAGS += -DBUILD_UPNP
|
||||
LOCAL_SRC_FILES += upnp.c
|
||||
endif
|
||||
|
||||
LOCAL_STATIC_LIBRARIES += libspeex
|
||||
|
||||
ifeq ($(BUILD_SRTP), 1)
|
||||
|
|
|
|||
232
build/android/config.h
Normal file
232
build/android/config.h
Normal file
|
|
@ -0,0 +1,232 @@
|
|||
/* config.h. Generated from config.h.in by configure. */
|
||||
/* config.h.in. Generated from configure.ac by autoheader. */
|
||||
|
||||
/* Define if building universal (internal helper macro) */
|
||||
/* #undef AC_APPLE_UNIVERSAL_BUILD */
|
||||
|
||||
/* Define if tools enabled */
|
||||
/* #undef BUILD_TOOLS */
|
||||
|
||||
/* Define if wizard enabled */
|
||||
/* #undef BUILD_WIZARD */
|
||||
|
||||
/* Tells whether localisation is possible */
|
||||
/* #undef ENABLE_NLS */
|
||||
|
||||
/* Defined when using gsm at nonstandard rates */
|
||||
/* #undef ENABLE_NONSTANDARD_GSM */
|
||||
|
||||
/* The name of the gettext package name */
|
||||
/* #undef GETTEXT_PACKAGE */
|
||||
|
||||
/* Define to 1 if you have the MacOS X function CFLocaleCopyCurrent in the
|
||||
CoreFoundation framework. */
|
||||
/* #undef HAVE_CFLOCALECOPYCURRENT */
|
||||
|
||||
/* Define to 1 if you have the MacOS X function CFPreferencesCopyAppValue in
|
||||
the CoreFoundation framework. */
|
||||
/* #undef HAVE_CFPREFERENCESCOPYAPPVALUE */
|
||||
|
||||
/* Define if the GNU dcgettext() function is already present or preinstalled.
|
||||
*/
|
||||
/* #undef HAVE_DCGETTEXT */
|
||||
|
||||
/* Define to 1 if you have the <dlfcn.h> header file. */
|
||||
/* #undef HAVE_DLFCN_H */
|
||||
|
||||
/* Define if exosip dscp available */
|
||||
/* #def HAVE_EXOSIP_DSCP */
|
||||
|
||||
/* Defined when eXosip_get_version is available */
|
||||
#define HAVE_EXOSIP_GET_VERSION
|
||||
|
||||
/* Defined when eXosip_reset_transports is available */
|
||||
#define HAVE_EXOSIP_RESET_TRANSPORTS
|
||||
|
||||
/* Defined when eXosip_tls_verify_certificate is available */
|
||||
#define HAVE_EXOSIP_TLS_VERIFY_CERTIFICATE
|
||||
|
||||
/* Defined when eXosip_tls_verify_certificate is available */
|
||||
/* #undef HAVE_EXOSIP_TLS_VERIFY_CN */
|
||||
|
||||
/* Defined when eXosip_get_socket is available */
|
||||
#define HAVE_EXOSIP_TRYLOCK
|
||||
|
||||
/* If present, the getenv function allows fim to read environment variables.
|
||||
*/
|
||||
#define HAVE_GETENV 1
|
||||
|
||||
/* Define to 1 if you have the `getifaddrs' function. */
|
||||
/* #undef HAVE_GETIFADDRS */
|
||||
|
||||
/* Tells wheter localisation is possible */
|
||||
/* #undef HAVE_GETTEXT */
|
||||
|
||||
/* Define to 1 if you have the `get_current_dir_name' function. */
|
||||
#define HAVE_GET_CURRENT_DIR_NAME 1
|
||||
|
||||
/* Defined when gtk osx is used */
|
||||
/* #undef HAVE_GTK_OSX */
|
||||
|
||||
/* Define to 1 if you have the <history.h> header file. */
|
||||
/* #undef HAVE_HISTORY_H */
|
||||
|
||||
/* Define if you have the iconv() function. */
|
||||
/* #undef HAVE_ICONV */
|
||||
|
||||
/* Define to 1 if you have the <inttypes.h> header file. */
|
||||
#define HAVE_INTTYPES_H 1
|
||||
|
||||
/* Define to 1 if you have the `eXosip2' library (-leXosip2). */
|
||||
/* #define HAVE_LIBEXOSIP2 */
|
||||
|
||||
/* Define to 1 if you have the `osip2' library (-losip2). */
|
||||
/* #undef HAVE_LIBOSIP2 */
|
||||
|
||||
/* Define to 1 if you have the `osipparser2' library (-losipparser2). */
|
||||
/* #undef HAVE_LIBOSIPPARSER2 */
|
||||
|
||||
/* Define to 1 if you have the `udev' library (-ludev). */
|
||||
/* #undef HAVE_LIBUDEV */
|
||||
|
||||
/* Define to 1 if you have the <libudev.h> header file. */
|
||||
/* #undef HAVE_LIBUDEV_H */
|
||||
|
||||
/* Define to 1 if you have the <memory.h> header file. */
|
||||
#define HAVE_MEMORY_H 1
|
||||
|
||||
/* NOTIFY1 support */
|
||||
/* #undef HAVE_NOTIFY1 */
|
||||
|
||||
/* NOTIFY4 support */
|
||||
/* #undef HAVE_NOTIFY4 */
|
||||
|
||||
/* defined when compiling with readline support */
|
||||
/* #undef HAVE_READLINE */
|
||||
|
||||
/* Define to 1 if you have the <readline.h> header file. */
|
||||
/* #undef HAVE_READLINE_H */
|
||||
|
||||
/* Define to 1 if you have the <readline/history.h> header file. */
|
||||
/* #undef HAVE_READLINE_HISTORY_H */
|
||||
|
||||
/* Define to 1 if you have the <readline/readline.h> header file. */
|
||||
/* #undef HAVE_READLINE_READLINE_H */
|
||||
|
||||
/* Define if sighandler_t available */
|
||||
/* #undef HAVE_SIGHANDLER_T */
|
||||
|
||||
/* Define to 1 if you have the <stdint.h> header file. */
|
||||
#define HAVE_STDINT_H 1
|
||||
|
||||
/* Define to 1 if you have the <stdlib.h> header file. */
|
||||
#define HAVE_STDLIB_H 1
|
||||
|
||||
/* Define to 1 if you have the `stpcpy' function. */
|
||||
#define HAVE_STPCPY 1
|
||||
|
||||
/* Define to 1 if you have the <strings.h> header file. */
|
||||
#define HAVE_STRINGS_H 1
|
||||
|
||||
/* Define to 1 if you have the <string.h> header file. */
|
||||
#define HAVE_STRING_H 1
|
||||
|
||||
/* Define to 1 if you have the `strndup' function. */
|
||||
#define HAVE_STRNDUP 1
|
||||
|
||||
/* Define to 1 if you have the <sys/stat.h> header file. */
|
||||
#define HAVE_SYS_STAT_H 1
|
||||
|
||||
/* Define to 1 if you have the <sys/types.h> header file. */
|
||||
#define HAVE_SYS_TYPES_H 1
|
||||
|
||||
/* Define to 1 if you have the <unistd.h> header file. */
|
||||
#define HAVE_UNISTD_H 1
|
||||
|
||||
/* Define to 1 if you have the <X11/Xlib.h> header file. */
|
||||
#define HAVE_X11_XLIB_H 1
|
||||
|
||||
/* All supported languages */
|
||||
/* #undef LINPHONE_ALL_LANGS */
|
||||
|
||||
/* Windows appdata subdir where linphonerc can be found */
|
||||
/* #undef LINPHONE_CONFIG_DIR */
|
||||
|
||||
/* path of liblinphone plugins, not mediastreamer2 plugins */
|
||||
/* #undef LINPHONE_PLUGINS_DIR */
|
||||
|
||||
/* Linphone's version number */
|
||||
/* #undef LINPHONE_VERSION */
|
||||
|
||||
/* Define to the sub-directory in which libtool stores uninstalled libraries.
|
||||
*/
|
||||
#define LT_OBJDIR ".libs/"
|
||||
|
||||
/* Define to 1 if your C compiler doesn't accept -c and -o together. */
|
||||
/* #undef NO_MINUS_C_MINUS_O */
|
||||
|
||||
/* Name of package */
|
||||
#define PACKAGE "linphone"
|
||||
|
||||
/* Define to the address where bug reports for this package should be sent. */
|
||||
/* #undef PACKAGE_BUGREPORT */
|
||||
|
||||
/* Defines the place where data are found */
|
||||
/* #undef PACKAGE_DATA_DIR */
|
||||
|
||||
/* Defines the place where locales can be found */
|
||||
/* #undef PACKAGE_LOCALE_DIR */
|
||||
|
||||
/* Define to the full name of this package. */
|
||||
#define PACKAGE_NAME "linphone"
|
||||
|
||||
/* Defines the place where linphone sounds are found */
|
||||
/* #undef PACKAGE_SOUND_DIR */
|
||||
|
||||
/* Define to the full name and version of this package. */
|
||||
/* #undef PACKAGE_STRING */
|
||||
|
||||
/* Define to the one symbol short name of this package. */
|
||||
/* #undef PACKAGE_TARNAME */
|
||||
|
||||
/* Define to the home page for this package. */
|
||||
/* #undef PACKAGE_URL */
|
||||
|
||||
/* Define to the version of this package. */
|
||||
/* #undef PACKAGE_VERSION */
|
||||
|
||||
/* Define to 1 if you have the ANSI C header files. */
|
||||
#define STDC_HEADERS 1
|
||||
|
||||
/* Tell whether date_version.h must be used */
|
||||
/* #undef USE_BUILDDATE_VERSION */
|
||||
|
||||
/* Version number of package */
|
||||
/* #undef VERSION */
|
||||
|
||||
/* defined if video support is available */
|
||||
/* #undef VIDEO_ENABLED */
|
||||
|
||||
/* Tell whether RSVP support should be compiled. */
|
||||
/* #undef VINCENT_MAURY_RSVP */
|
||||
|
||||
/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
|
||||
significant byte first (like Motorola and SPARC, unlike Intel). */
|
||||
#if defined AC_APPLE_UNIVERSAL_BUILD
|
||||
# if defined __BIG_ENDIAN__
|
||||
# define WORDS_BIGENDIAN 1
|
||||
# endif
|
||||
#else
|
||||
# ifndef WORDS_BIGENDIAN
|
||||
/* # undef WORDS_BIGENDIAN */
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/* Defined if we are compiling for arm processor */
|
||||
/* #undef __ARM__ */
|
||||
|
||||
/* Define to `__inline__' or `__inline' if that's what the C compiler
|
||||
calls it, or to nothing if 'inline' is not supported under any name. */
|
||||
#ifndef __cplusplus
|
||||
/* #undef inline */
|
||||
#endif
|
||||
1
build/android/liblinphone_gitversion.h
Normal file
1
build/android/liblinphone_gitversion.h
Normal file
|
|
@ -0,0 +1 @@
|
|||
#define LIBLINPHONE_GIT_VERSION "unknown"
|
||||
|
|
@ -1306,7 +1306,7 @@ static void linphone_core_init (LinphoneCore * lc, const LinphoneCoreVTable *vta
|
|||
#endif
|
||||
#ifdef BUILD_UPNP
|
||||
lc->upnp = linphone_upnp_context_new(lc);
|
||||
#endif //BUILD_UPNP
|
||||
#endif //BUILD_UPNP
|
||||
if (lc->vtable.display_status)
|
||||
lc->vtable.display_status(lc,_("Ready"));
|
||||
lc->auto_net_state_mon=lc->sip_conf.auto_net_state_mon;
|
||||
|
|
@ -1409,7 +1409,7 @@ void linphone_core_get_local_ip(LinphoneCore *lc, const char *dest, char *result
|
|||
strncpy(result,ip,LINPHONE_IPADDR_SIZE);
|
||||
return;
|
||||
}
|
||||
#endif //BUILD_UPNP
|
||||
#endif //BUILD_UPNP
|
||||
if (linphone_core_get_local_ip_for(lc->sip_conf.ipv6_enabled ? AF_INET6 : AF_INET,dest,result)==0)
|
||||
return;
|
||||
/*else fallback to SAL routine that will attempt to find the most realistic interface */
|
||||
|
|
@ -2990,7 +2990,7 @@ int linphone_core_accept_call_update(LinphoneCore *lc, LinphoneCall *call, const
|
|||
#endif //VIDEO_ENABLED
|
||||
}
|
||||
|
||||
#if BUILD_UPNP
|
||||
#ifdef BUILD_UPNP
|
||||
if(call->upnp_session != NULL) {
|
||||
linphone_core_update_upnp_from_remote_media_description(call, sal_call_get_remote_media_description(call->op));
|
||||
#ifdef VIDEO_ENABLED
|
||||
|
|
@ -5172,7 +5172,7 @@ static void linphone_core_uninit(LinphoneCore *lc)
|
|||
#ifdef BUILD_UPNP
|
||||
linphone_upnp_context_destroy(lc->upnp);
|
||||
lc->upnp = NULL;
|
||||
#endif //BUILD_UPNP
|
||||
#endif //BUILD_UPNP
|
||||
|
||||
if (lc->friends)
|
||||
ms_list_for_each(lc->friends,(void (*)(void *))linphone_friend_close_subscriptions);
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ extern "C" {
|
|||
#include "mediastreamer2/msconference.h"
|
||||
#ifdef BUILD_UPNP
|
||||
#include "upnp.h"
|
||||
#endif //BUILD_UPNP
|
||||
#endif //BUILD_UPNP
|
||||
|
||||
#ifndef LIBLINPHONE_VERSION
|
||||
#define LIBLINPHONE_VERSION LINPHONE_VERSION
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
Subproject commit a964bf24c47febe55276a8b5ef3e323503c08668
|
||||
Subproject commit eeaab2239d6545f18d5219b62adda8d1dda3b104
|
||||
Loading…
Add table
Reference in a new issue