Commit 3b9bc6e5 authored by Simon Morlat's avatar Simon Morlat

Merge remote-tracking branch 'linphone/master' into daemon

Conflicts:
	configure.ac
parents ff052dee 88a7287b
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
<?fileVersion 4.0.0?> <?fileVersion 4.0.0?><cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
<cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
<storageModule moduleId="org.eclipse.cdt.core.settings"> <storageModule moduleId="org.eclipse.cdt.core.settings">
<cconfiguration id="0.2079208171"> <cconfiguration id="0.2079208171">
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="0.2079208171" moduleId="org.eclipse.cdt.core.settings" name="Default"> <storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="0.2079208171" moduleId="org.eclipse.cdt.core.settings" name="Default">
...@@ -45,6 +43,7 @@ ...@@ -45,6 +43,7 @@
<entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="gtk"/> <entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="gtk"/>
<entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="include"/> <entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="include"/>
<entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="tester"/> <entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="tester"/>
<entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="tools"/>
</sourceEntries> </sourceEntries>
</configuration> </configuration>
</storageModule> </storageModule>
......
...@@ -20,12 +20,12 @@ ...@@ -20,12 +20,12 @@
# #
############################################################################ ############################################################################
cmake_minimum_required(VERSION 2.8.12) cmake_minimum_required(VERSION 3.0)
project(LINPHONE C CXX) project(LINPHONE C CXX)
set(LINPHONE_MAJOR_VERSION "3") set(LINPHONE_MAJOR_VERSION "3")
set(LINPHONE_MINOR_VERSION "7") set(LINPHONE_MINOR_VERSION "8")
set(LINPHONE_MICRO_VERSION "0") set(LINPHONE_MICRO_VERSION "0")
set(LINPHONE_VERSION "${LINPHONE_MAJOR_VERSION}.${LINPHONE_MINOR_VERSION}.${LINPHONE_MICRO_VERSION}") set(LINPHONE_VERSION "${LINPHONE_MAJOR_VERSION}.${LINPHONE_MINOR_VERSION}.${LINPHONE_MICRO_VERSION}")
set(LINPHONE_SO_VERSION "6") set(LINPHONE_SO_VERSION "6")
...@@ -53,17 +53,46 @@ cmake_dependent_option(ENABLE_ASSISTANT "Turn on assistant compiling." YES "ENAB ...@@ -53,17 +53,46 @@ cmake_dependent_option(ENABLE_ASSISTANT "Turn on assistant compiling." YES "ENAB
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
list(APPEND CMAKE_MODULE_PATH "${CMAKE_PREFIX_PATH}/share/cmake/Modules")
include(CheckIncludeFile)
include(CheckSymbolExists) include(CheckSymbolExists)
include(CMakePushCheckState)
set(MSVC_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/include/MSVC")
if(MSVC) if(MSVC)
list(APPEND CMAKE_REQUIRED_INCLUDES "${CMAKE_PREFIX_PATH}/include/MSVC") list(APPEND CMAKE_REQUIRED_INCLUDES "${MSVC_INCLUDE_DIR}")
if(ENABLE_GTK_UI)
if(NOT EXISTS "${CMAKE_CURRENT_BINARY_DIR}/intltool_win32.zip")
message(STATUS "Installing intltool")
file(DOWNLOAD http://ftp.acc.umu.se/pub/GNOME/binaries/win32/intltool/0.40/intltool_0.40.4-1_win32.zip "${CMAKE_CURRENT_BINARY_DIR}/intltool_win32.zip" SHOW_PROGRESS)
execute_process(
COMMAND "${CMAKE_COMMAND}" "-E" "tar" "x" "${CMAKE_CURRENT_BINARY_DIR}/intltool_win32.zip"
WORKING_DIRECTORY "${CMAKE_INSTALL_PREFIX}"
)
endif()
if(NOT EXISTS "${CMAKE_CURRENT_BINARY_DIR}/gtk+-bundle_win32.zip")
message(STATUS "Installing GTK")
file(DOWNLOAD http://ftp.gnome.org/pub/gnome/binaries/win32/gtk+/2.24/gtk+-bundle_2.24.10-20120208_win32.zip "${CMAKE_CURRENT_BINARY_DIR}/gtk+-bundle_win32.zip" SHOW_PROGRESS)
execute_process(
COMMAND "${CMAKE_COMMAND}" "-E" "tar" "x" "${CMAKE_CURRENT_BINARY_DIR}/gtk+-bundle_win32.zip"
WORKING_DIRECTORY "${CMAKE_INSTALL_PREFIX}"
)
endif()
endif()
if(ENABLE_ASSISTANT)
if(NOT EXISTS "${CMAKE_CURRENT_BINARY_DIR}/libsoup.zip")
message(STATUS "Installing libsoup")
file(DOWNLOAD http://www.linphone.org/files/libsoup_2.24.0-1_win32.zip "${CMAKE_CURRENT_BINARY_DIR}/libsoup.zip" SHOW_PROGRESS)
execute_process(
COMMAND "${CMAKE_COMMAND}" "-E" "tar" "x" "${CMAKE_CURRENT_BINARY_DIR}/libsoup.zip"
WORKING_DIRECTORY "${CMAKE_INSTALL_PREFIX}"
)
endif()
endif()
endif() endif()
find_package(BelleSIP REQUIRED) find_package(BelleSIP REQUIRED)
find_package(MS2 REQUIRED) find_package(Mediastreamer2 REQUIRED)
find_package(XML2 REQUIRED) find_package(XML2 REQUIRED)
if(ENABLE_UNIT_TESTS) if(ENABLE_UNIT_TESTS)
find_package(CUnit) find_package(CUnit)
...@@ -87,10 +116,7 @@ if(ENABLE_TUNNEL) ...@@ -87,10 +116,7 @@ if(ENABLE_TUNNEL)
endif() endif()
endif() endif()
if(ENABLE_MSG_STORAGE) if(ENABLE_MSG_STORAGE)
find_package(Sqlite3) find_package(Sqlite3 REQUIRED)
if(NOT SQLITE3_FOUND)
message(FATAL_ERROR "Could not find the sqlite3 library!")
endif()
endif() endif()
if(ENABLE_NOTIFY) if(ENABLE_NOTIFY)
find_package(Notify) find_package(Notify)
...@@ -119,7 +145,7 @@ include_directories( ...@@ -119,7 +145,7 @@ include_directories(
${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_BINARY_DIR}
${CMAKE_CURRENT_BINARY_DIR}/coreapi/ ${CMAKE_CURRENT_BINARY_DIR}/coreapi/
${BELLESIP_INCLUDE_DIRS} ${BELLESIP_INCLUDE_DIRS}
${MS2_INCLUDE_DIRS} ${MEDIASTREAMER2_INCLUDE_DIRS}
${XML2_INCLUDE_DIRS} ${XML2_INCLUDE_DIRS}
) )
if(SQLITE3_FOUND) if(SQLITE3_FOUND)
...@@ -132,9 +158,8 @@ endif() ...@@ -132,9 +158,8 @@ endif()
if(ENABLE_ASSISTANT) if(ENABLE_ASSISTANT)
include_directories(${SOUP_INCLUDE_DIRS}) include_directories(${SOUP_INCLUDE_DIRS})
endif() endif()
if(MSVC) if(MSVC)
include_directories(${CMAKE_PREFIX_PATH}/include/MSVC) include_directories(${MSVC_INCLUDE_DIR})
endif() endif()
add_definitions("-DIN_LINPHONE") add_definitions("-DIN_LINPHONE")
...@@ -166,6 +191,9 @@ else() ...@@ -166,6 +191,9 @@ else()
set(LINPHONE_DATA_DIR "${CMAKE_INSTALL_PREFIX}") set(LINPHONE_DATA_DIR "${CMAKE_INSTALL_PREFIX}")
endif() endif()
set(LINPHONE_PLUGINS_DIR "${LINPHONE_DATA_DIR}/lib/liblinphone/plugins") set(LINPHONE_PLUGINS_DIR "${LINPHONE_DATA_DIR}/lib/liblinphone/plugins")
if(WIN32)
set(LINPHONE_CONFIG_DIR "Linphone")
endif()
set(PACKAGE_LOCALE_DIR "${LINPHONE_DATA_DIR}/share/locale") set(PACKAGE_LOCALE_DIR "${LINPHONE_DATA_DIR}/share/locale")
set(PACKAGE_DATA_DIR "${LINPHONE_DATA_DIR}/share") set(PACKAGE_DATA_DIR "${LINPHONE_DATA_DIR}/share")
set(PACKAGE_SOUND_DIR "${LINPHONE_DATA_DIR}/share/sounds/linphone") set(PACKAGE_SOUND_DIR "${LINPHONE_DATA_DIR}/share/sounds/linphone")
...@@ -196,9 +224,29 @@ if(ENABLE_UNIT_TESTS) ...@@ -196,9 +224,29 @@ if(ENABLE_UNIT_TESTS)
endif() endif()
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/cmake/FindLinphone.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/FindLinphone.cmake) include(CMakePackageConfigHelpers)
write_basic_package_version_file(
"${CMAKE_CURRENT_BINARY_DIR}/LinphoneConfigVersion.cmake"
VERSION ${LINPHONE_VERSION}
COMPATIBILITY AnyNewerVersion
)
export(EXPORT LinphoneTargets
FILE "${CMAKE_CURRENT_BINARY_DIR}/LinphoneTargets.cmake"
NAMESPACE BelledonneCommunications::
)
configure_file(cmake/LinphoneConfig.cmake.in
"${CMAKE_CURRENT_BINARY_DIR}/LinphoneConfig.cmake"
@ONLY
)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/FindLinphone.cmake set(ConfigPackageLocation lib/cmake/Linphone)
DESTINATION share/cmake/Modules install(EXPORT LinphoneTargets
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ FILE LinphoneTargets.cmake
NAMESPACE BelledonneCommunications::
DESTINATION ${ConfigPackageLocation}
)
install(FILES
"${CMAKE_CURRENT_BINARY_DIR}/LinphoneConfig.cmake"
"${CMAKE_CURRENT_BINARY_DIR}/LinphoneConfigVersion.cmake"
DESTINATION ${ConfigPackageLocation}
) )
linphone-3.8.0 -- Date to be defined linphone-3.8.0 -- March 11th, 2015
Application level improvements: Application level improvements:
* The video window has now controls in order to switch fullscreen mode and terminate call. * The video window has now controls in order to switch fullscreen mode and terminate call.
* The out of call video preview feature (to test camera) is moved into the settings and is no longer linked to the in-call video preview feature. * The out of call video preview feature (to test camera) is moved into the settings and is no longer linked to the in-call video preview feature.
......
...@@ -63,10 +63,7 @@ The next pieces need to be compiled manually. ...@@ -63,10 +63,7 @@ The next pieces need to be compiled manually.
* To ensure compatibility with multiple MacOS versions it is recommended to do: * To ensure compatibility with multiple MacOS versions it is recommended to do:
export MACOSX_DEPLOYMENT_TARGET=10.6 export MACOSX_DEPLOYMENT_TARGET=10.6
export CFLAGS="-arch i386 -arch x86_64 -mmacosx-version-min=10.5" export LDFLAGS="-Wl,-headerpad_max_install_names -Wl,-read_only_relocs -Wl,suppress"
export OBJCFLAGS="-arch i386 -arch x86_64 -mmacosx-version-min=10.5"
export CXXFLAGS="-arch i386 -arch x86_64 -mmacosx-version-min=10.5"
export LDFLAGS="-arch i386 -arch x86_64 -mmacosx-version-min=10.5 -Wl,-headerpad_max_install_names -Wl,-read_only_relocs -Wl,suppress"
* (MacPorts only) Install libantlr3c (library used by belle-sip for parsing) * (MacPorts only) Install libantlr3c (library used by belle-sip for parsing)
......
...@@ -58,6 +58,7 @@ LOCAL_SRC_FILES := \ ...@@ -58,6 +58,7 @@ LOCAL_SRC_FILES := \
linphone_tunnel_config.c \ linphone_tunnel_config.c \
localplayer.c \ localplayer.c \
lpc2xml.c \ lpc2xml.c \
lime.c \
lpconfig.c \ lpconfig.c \
message_storage.c \ message_storage.c \
misc.c \ misc.c \
...@@ -71,7 +72,8 @@ LOCAL_SRC_FILES := \ ...@@ -71,7 +72,8 @@ LOCAL_SRC_FILES := \
siplogin.c \ siplogin.c \
sipsetup.c \ sipsetup.c \
xml2lpc.c \ xml2lpc.c \
xml.c xml.c \
vtables.c
ifndef LIBLINPHONE_VERSION ifndef LIBLINPHONE_VERSION
LIBLINPHONE_VERSION = "Devel" LIBLINPHONE_VERSION = "Devel"
...@@ -117,7 +119,8 @@ LOCAL_C_INCLUDES += \ ...@@ -117,7 +119,8 @@ LOCAL_C_INCLUDES += \
$(LOCAL_PATH)/../../belle-sip/include \ $(LOCAL_PATH)/../../belle-sip/include \
$(LOCAL_PATH)/../../../gen \ $(LOCAL_PATH)/../../../gen \
$(LOCAL_PATH)/../../externals/libxml2/include \ $(LOCAL_PATH)/../../externals/libxml2/include \
$(LOCAL_PATH)/../../externals/build/libxml2 $(LOCAL_PATH)/../../externals/build/libxml2 \
$(LOCAL_PATH)/../../externals/polarssl/include
LOCAL_LDLIBS += -llog -ldl -lz LOCAL_LDLIBS += -llog -ldl -lz
......
...@@ -20,7 +20,8 @@ common_SRC_FILES := \ ...@@ -20,7 +20,8 @@ common_SRC_FILES := \
dtmf_tester.c \ dtmf_tester.c \
accountmanager.c \ accountmanager.c \
offeranswer_tester.c \ offeranswer_tester.c \
multicast_call_tester.c multicast_call_tester.c \
multi_call.c
common_C_INCLUDES += \ common_C_INCLUDES += \
$(LOCAL_PATH) \ $(LOCAL_PATH) \
......
############################################################################
# FindCUnit.txt
# Copyright (C) 2015 Belledonne Communications, Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
############################################################################
#
# - Find the CUnit include file and library
#
# CUNIT_FOUND - system has CUnit
# CUNIT_INCLUDE_DIRS - the CUnit include directory
# CUNIT_LIBRARIES - The libraries needed to use CUnit
include(CheckIncludeFile)
include(CheckLibraryExists)
set(_CUNIT_ROOT_PATHS
${CMAKE_INSTALL_PREFIX}
)
find_path(CUNIT_INCLUDE_DIRS
NAMES CUnit/CUnit.h
HINTS _CUNIT_ROOT_PATHS
PATH_SUFFIXES include
)
if(CUNIT_INCLUDE_DIRS)
set(HAVE_CUNIT_CUNIT_H 1)
endif()
find_library(CUNIT_LIBRARIES
NAMES cunit
HINTS ${_CUNIT_ROOT_PATHS}
PATH_SUFFIXES bin lib
)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(CUnit
DEFAULT_MSG
CUNIT_INCLUDE_DIRS CUNIT_LIBRARIES
)
mark_as_advanced(CUNIT_INCLUDE_DIRS CUNIT_LIBRARIES)
############################################################################
# FindIconv.cmake
# Copyright (C) 2014 Belledonne Communications, Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
############################################################################
#
# - Find the iconv include file and library
#
# ICONV_FOUND - system has libiconv
# ICONV_INCLUDE_DIRS - the libiconv include directory
# ICONV_LIBRARIES - The libraries needed to use libiconv
set(_ICONV_ROOT_PATHS
${CMAKE_INSTALL_PREFIX}
)
find_path(ICONV_INCLUDE_DIRS
NAMES iconv.h
HINTS _ICONV_ROOT_PATHS
PATH_SUFFIXES include
)
if(ICONV_INCLUDE_DIRS)
set(HAVE_ICONV_H 1)
endif()
find_library(ICONV_LIBRARIES
NAMES iconv
HINTS ${_ICONV_ROOT_PATHS}
PATH_SUFFIXES bin lib
)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Iconv
DEFAULT_MSG
ICONV_INCLUDE_DIRS ICONV_LIBRARIES HAVE_ICONV_H
)
mark_as_advanced(ICONV_INCLUDE_DIRS ICONV_LIBRARIES HAVE_ICONV_H)
############################################################################
# FindIntl.cmake
# Copyright (C) 2014 Belledonne Communications, Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
############################################################################
#
# - Find the libintl include file and library
#
# INTL_FOUND - system has libintl
# INTL_INCLUDE_DIRS - the libintl include directory
# INTL_LIBRARIES - The libraries needed to use libintl
set(_INTL_ROOT_PATHS
${CMAKE_INSTALL_PREFIX}
)
find_path(INTL_INCLUDE_DIRS
NAMES libintl.h
HINTS _INTL_ROOT_PATHS
PATH_SUFFIXES include
)
if(INTL_INCLUDE_DIRS)
set(HAVE_LIBINTL_H 1)
endif()
set(INTL_ARGS INTL_INCLUDE_DIRS HAVE_LIBINTL_H)
if(NOT UNIX OR APPLE)
find_library(INTL_LIBRARIES
NAMES intl
HINTS ${_INTL_ROOT_PATHS}
PATH_SUFFIXES bin lib
)
list(APPEND INTL_ARGS INTL_LIBRARIES)
endif()
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Intl DEFAULT_MSG ${INTL_ARGS})
mark_as_advanced(${INTL_ARGS})
...@@ -27,7 +27,6 @@ ...@@ -27,7 +27,6 @@
# NOTIFY_LIBRARIES - The libraries needed to use libnotify # NOTIFY_LIBRARIES - The libraries needed to use libnotify
set(_NOTIFY_ROOT_PATHS set(_NOTIFY_ROOT_PATHS
${WITH_NOTIFY}
${CMAKE_INSTALL_PREFIX} ${CMAKE_INSTALL_PREFIX}
) )
......
...@@ -26,10 +26,12 @@ ...@@ -26,10 +26,12 @@
# SOUP_INCLUDE_DIRS - the libsoup include directory # SOUP_INCLUDE_DIRS - the libsoup include directory
# SOUP_LIBRARIES - The libraries needed to use libsoup # SOUP_LIBRARIES - The libraries needed to use libsoup
if(WIN32)
set(GTK2_ADDITIONAL_SUFFIXES "../lib/glib-2.0/include" "../lib/gtk-2.0/include")
endif()
find_package(GTK2 2.18 REQUIRED gtk) find_package(GTK2 2.18 REQUIRED gtk)
set(_SOUP_ROOT_PATHS set(_SOUP_ROOT_PATHS
${WITH_SOUP}
${CMAKE_INSTALL_PREFIX} ${CMAKE_INSTALL_PREFIX}
) )
......
############################################################################
# FindSqlite3.cmake
# Copyright (C) 2014 Belledonne Communications, Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
############################################################################
#
# - Find the sqlite3 include file and library
#
# SQLITE3_FOUND - system has sqlite3
# SQLITE3_INCLUDE_DIRS - the sqlite3 include directory
# SQLITE3_LIBRARIES - The libraries needed to use sqlite3
set(_SQLITE3_ROOT_PATHS
${CMAKE_INSTALL_PREFIX}
)
find_path(SQLITE3_INCLUDE_DIRS
NAMES sqlite3.h
HINTS _SQLITE3_ROOT_PATHS
PATH_SUFFIXES include
)
if(SQLITE3_INCLUDE_DIRS)
set(HAVE_SQLITE3_H 1)
endif()
find_library(SQLITE3_LIBRARIES
NAMES sqlite3
HINTS ${_SQLITE3_ROOT_PATHS}
PATH_SUFFIXES bin lib
)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Sqlite3
DEFAULT_MSG
SQLITE3_INCLUDE_DIRS SQLITE3_LIBRARIES HAVE_SQLITE3_H
)
mark_as_advanced(SQLITE3_INCLUDE_DIRS SQLITE3_LIBRARIES HAVE_SQLITE3_H)
############################################################################
# FindXML2.txt
# Copyright (C) 2015 Belledonne Communications, Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
############################################################################
#
# - Find the libxml2 include file and library
#
# XML2_FOUND - system has libxml2
# XML2_INCLUDE_DIRS - the libxml2 include directory
# XML2_LIBRARIES - The libraries needed to use libxml2
set(_XML2_ROOT_PATHS
${CMAKE_INSTALL_PREFIX}
)
find_path(XML2_INCLUDE_DIRS
NAMES libxml/xmlreader.h
HINTS _XML2_ROOT_PATHS
PATH_SUFFIXES include/libxml2
)
if(XML2_INCLUDE_DIRS)
set(HAVE_LIBXML_XMLREADER_H 1)
endif()
find_library(XML2_LIBRARIES
NAMES xml2
HINTS ${_XML2_ROOT_PATHS}
PATH_SUFFIXES bin lib
)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(XML2
DEFAULT_MSG
XML2_INCLUDE_DIRS XML2_LIBRARIES
)
mark_as_advanced(XML2_INCLUDE_DIRS XML2_LIBRARIES)
############################################################################ ############################################################################
# FindLinphone.cmake # LinphoneConfig.cmake
# Copyright (C) 2014 Belledonne Communications, Grenoble France # Copyright (C) 2015 Belledonne Communications, Grenoble France
# #
############################################################################ ############################################################################
# #
...@@ -20,7 +20,8 @@ ...@@ -20,7 +20,8 @@
# #
############################################################################ ############################################################################
# #
# - Find the linphone include file and library # Config file for the belle-sip package.
# It defines the following variables:
# #
# LINPHONE_FOUND - system has linphone # LINPHONE_FOUND - system has linphone
# LINPHONE_INCLUDE_DIRS - the linphone include directory # LINPHONE_INCLUDE_DIRS - the linphone include directory
...@@ -28,56 +29,23 @@ ...@@ -28,56 +29,23 @@
# LINPHONE_CPPFLAGS - The compilation flags needed to use linphone # LINPHONE_CPPFLAGS - The compilation flags needed to use linphone
# LINPHONE_LDFLAGS - The linking flags needed to use linphone # LINPHONE_LDFLAGS - The linking flags needed to use linphone
find_package(ORTP REQUIRED) include("${CMAKE_CURRENT_LIST_DIR}/LinphoneTargets.cmake")
find_package(MS2 REQUIRED) find_package(Mediastreamer2 REQUIRED)
find_package(XML2 REQUIRED)
find_package(BelleSIP REQUIRED) find_package(BelleSIP REQUIRED)
if(@ENABLE_MSG_STORAGE@) if(@ENABLE_TUNNEL@)
find_package(Sqlite3) find_package(Tunnel)
endif() endif()
set(_LINPHONE_ROOT_PATHS get_filename_component(LINPHONE_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
${WITH_LINPHONE} set(LINPHONE_INCLUDE_DIRS "${LINPHONE_CMAKE_DIR}/../../../include")
${CMAKE_INSTALL_PREFIX} set(LINPHONE_LIBRARIES BelledonneCommunications::linphone)
) set(LINPHONE_LDFLAGS @LINK_FLAGS@)
list(APPEND LINPHONE_INCLUDE_DIRS ${MEDIASTREAMER2_INCLUDE_DIRS} ${BELLESIP_INCLUDE_DIRS})
find_path(LINPHONE_INCLUDE_DIRS list(APPEND LINPHONE_LIBRARIES ${MEDIASTREAMER2_LIBRARIES} ${BELLESIP_LIBRARIES})
NAMES linphone/linphonecore.h set(LINPHONE_CPPFLAGS "${MEDIASTREAMER2_CPPFLAGS}")
HINTS _LINPHONE_ROOT_PATHS set(LINPHONE_LDFLAGS "${MEDIASTREAMER2_LDFLAGS} ${BELLESIP_LDFLAGS}")
PATH_SUFFIXES include if(TUNNEL_FOUND)
) list(APPEND LINPHONE_INCLUDE_DIRS ${TUNNEL_INCLUDE_DIRS})
list(APPEND LINPHONE_LIBRARIES ${TUNNEL_LIBRARIES})
if(LINPHONE_INCLUDE_DIRS)
set(HAVE_LINPHONE_LINPHONECORE_H 1)
endif()
find_library(LINPHONE_LIBRARIES
NAMES linphone
HINTS ${_LINPHONE_ROOT_PATHS}
PATH_SUFFIXES bin lib
)
list(APPEND LINPHONE_INCLUDE_DIRS ${ORTP_INCLUDE_DIRS} ${MS2_INCLUDE_DIRS} ${XML2_INCLUDE_DIRS} ${BELLESIP_INCLUDE_DIRS})
list(APPEND LINPHONE_LIBRARIES ${ORTP_LIBRARIES} ${MS2_LIBRARIES} ${XML2_LIBRARIES} ${BELLESIP_LIBRARIES})
if(SQLITE3_FOUND)
list(APPEND LINPHONE_INCLUDE_DIRS ${SQLITE3_INCLUDE_DIRS})
list(APPEND LINPHONE_LIBRARIES ${SQLITE3_LIBRARIES})
endif() endif()
set(LINPHONE_FOUND 1)
if(WIN32)
list(APPEND LINPHONE_LIBRARIES shlwapi)
endif(WIN32)
list(REMOVE_DUPLICATES LINPHONE_INCLUDE_DIRS)
list(REMOVE_DUPLICATES LINPHONE_LIBRARIES)
set(LINPHONE_CPPFLAGS "${MS2_CPPFLAGS}")
set(LINPHONE_LDFLAGS "${MS2_LDFLAGS} ${BELLESIP_LDFLAGS}")
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Linphone
DEFAULT_MSG
LINPHONE_INCLUDE_DIRS LINPHONE_LIBRARIES
)
mark_as_advanced(LINPHONE_INCLUDE_DIRS LINPHONE_LIBRARIES LINPHONE_CPPFLAGS LINPHONE_LDFLAGS)
...@@ -29,6 +29,7 @@ ...@@ -29,6 +29,7 @@
#define LINPHONE_ALL_LANGS "${LINPHONE_ALL_LANGS}" #define LINPHONE_ALL_LANGS "${LINPHONE_ALL_LANGS}"
#define LINPHONE_PLUGINS_DIR "${LINPHONE_PLUGINS_DIR}" #define LINPHONE_PLUGINS_DIR "${LINPHONE_PLUGINS_DIR}"
#define LINPHONE_CONFIG_DIR "${LINPHONE_CONFIG_DIR}"
#define GETTEXT_PACKAGE "${GETTEXT_PACKAGE}" #define GETTEXT_PACKAGE "${GETTEXT_PACKAGE}"
......
dnl Process this file with autoconf to produce a configure script. dnl Process this file with autoconf to produce a configure script.
AC_INIT([linphone],[3.7.0-linphone-daemon],[linphone-developers@nongnu.org]) AC_INIT([linphone],[3.8.0-linphone-daemon],[linphone-developers@nongnu.org])
AC_CANONICAL_SYSTEM AC_CANONICAL_SYSTEM
AC_CONFIG_SRCDIR([coreapi/linphonecore.c]) AC_CONFIG_SRCDIR([coreapi/linphonecore.c])
</