Commit efa9910f authored by Ghislain MARY's avatar Ghislain MARY

Reorganize builders.

parent 58343099
...@@ -37,10 +37,9 @@ linphone_builder_apply_toolchain_flags() ...@@ -37,10 +37,9 @@ linphone_builder_apply_toolchain_flags()
# Include project configuration according to the toolchain # Include project configuration according to the toolchain
include(configs/config-${LINPHONE_BUILDER_TOOLCHAIN}.cmake) include(configs/config-${LINPHONE_BUILDER_TOOLCHAIN}.cmake)
linphone_builder_add_external_projects()
# Include builders definitions # Give a feature summary
include(builders/CMakeLists.txt)
feature_summary(WHAT ENABLED_FEATURES DESCRIPTION "Enabled features:") feature_summary(WHAT ENABLED_FEATURES DESCRIPTION "Enabled features:")
feature_summary(WHAT DISABLED_FEATURES DESCRIPTION "Disabled features:") feature_summary(WHAT DISABLED_FEATURES DESCRIPTION "Disabled features:")
...@@ -20,7 +20,47 @@ ...@@ -20,7 +20,47 @@
# #
############################################################################ ############################################################################
cmake_minimum_required(VERSION 2.8) # Include linphone builder options definitions
include(cmake/LinphoneBuilderOptions.cmake)
# List of the projects to build. The order is important and must follow the dependencies.
set(LINPHONE_BUILDER_BUILDERS )
if(${ENABLE_UNIT_TESTS})
list(APPEND LINPHONE_BUILDER_BUILDERS cunit)
endif(${ENABLE_UNIT_TESTS})
if(${ENABLE_SRTP})
list(APPEND LINPHONE_BUILDER_BUILDERS srtp)
endif(${ENABLE_SRTP})
if(${ENABLE_GSM})
list(APPEND LINPHONE_BUILDER_BUILDERS gsm)
endif(${ENABLE_GSM})
if(${ENABLE_OPUS})
list(APPEND LINPHONE_BUILDER_BUILDERS opus)
endif(${ENABLE_OPUS})
if(${ENABLE_SPEEX})
list(APPEND LINPHONE_BUILDER_BUILDERS speex)
endif(${ENABLE_SPEEX})
if(${ENABLE_FFMPEG})
list(APPEND LINPHONE_BUILDER_BUILDERS ffmpeg)
endif(${ENABLE_FFMPEG})
if(${ENABLE_VPX})
list(APPEND LINPHONE_BUILDER_BUILDERS vpx)
endif(${ENABLE_VPX})
if("${BUILD_V4L}" STREQUAL "yes")
list(APPEND LINPHONE_BUILDER_BUILDERS v4l)
endif("${BUILD_V4L}" STREQUAL "yes")
list(APPEND LINPHONE_BUILDER_BUILDERS
xml2
antlr3c
polarssl
bellesip
ortp
ms2
linphone
)
# Include builders # Include builders
foreach(BUILDER ${LINPHONE_BUILDER_BUILDERS}) foreach(BUILDER ${LINPHONE_BUILDER_BUILDERS})
......
...@@ -20,4 +20,6 @@ ...@@ -20,4 +20,6 @@
# #
############################################################################ ############################################################################
linphone_builder_add_cmake_project(antlr3c) set(EP_antlr3c_GIT_REPOSITORY "git://git.linphone.org/antlr3.git")
set(EP_antlr3c_GIT_TAG "b882cfc0d8e6485d6d050e7f5ec36f870c7ece7b") # Branch 'linphone'
set(EP_antlr3c_CMAKE_OPTIONS "-DENABLE_DEBUGGER=0")
...@@ -20,4 +20,13 @@ ...@@ -20,4 +20,13 @@
# #
############################################################################ ############################################################################
linphone_builder_add_cmake_project(bellesip) set(EP_bellesip_GIT_REPOSITORY "git://git.linphone.org/belle-sip.git")
set(EP_bellesip_GIT_TAG "cb977e6aaa0a319c437d08e3d67492d1453adbfb") # Branch 'master'
set(EP_bellesip_CMAKE_OPTIONS )
set(EP_bellesip_DEPENDENCIES EP_antlr3c EP_polarssl)
if(${ENABLE_UNIT_TESTS})
list(APPEND EP_bellesip_DEPENDENCIES EP_cunit)
else(${ENABLE_UNIT_TESTS})
list(APPEND EP_bellesip_CMAKE_OPTIONS "-DENABLE_TESTS=0")
endif(${ENABLE_UNIT_TESTS})
...@@ -20,4 +20,6 @@ ...@@ -20,4 +20,6 @@
# #
############################################################################ ############################################################################
linphone_builder_add_cmake_project(cunit) set(EP_cunit_GIT_REPOSITORY "git://git.linphone.org/cunit.git")
set(EP_cunit_GIT_TAG "86562ef04d0d66c007d7822944a75f540ae37f19") # Branch 'linphone'
set(EP_cunit_CMAKE_OPTIONS "-DENABLE_AUTOMATED=0" "-DENABLE_CONSOLE=0")
...@@ -20,4 +20,14 @@ ...@@ -20,4 +20,14 @@
# #
############################################################################ ############################################################################
linphone_builder_add_autotools_project(ffmpeg) set(EP_ffmpeg_URL "http://ffmpeg.org/releases/ffmpeg-0.10.2.tar.gz")
set(EP_ffmpeg_AUTOTOOLS "yes")
# Disable video acceleration support for compatibility with older Mac OS X versions (vda, vaapi, vdpau).
set(EP_ffmpeg_CONFIGURE_OPTIONS "--enable-pic --disable-zlib --disable-bzlib --disable-mmx --disable-ffplay --disable-ffprobe --disable-ffserver --disable-avdevice --disable-avfilter --disable-network --disable-avformat --disable-everything --enable-decoder=mjpeg --enable-encoder=mjpeg --disable-vda --disable-vaapi --disable-vdpau")
set(EP_ffmpeg_ARCH "i386")
if(APPLE)
set(EP_ffmpeg_TARGET_OS "darwin")
else(APPLE)
set(EP_ffmpeg_TARGET_OS "linux")
endif(APPLE)
...@@ -20,4 +20,6 @@ ...@@ -20,4 +20,6 @@
# #
############################################################################ ############################################################################
linphone_builder_add_cmake_project(gsm) set(EP_gsm_GIT_REPOSITORY "git://git.linphone.org/gsm.git")
set(EP_gsm_GIT_TAG "8729c98e098341582e9c9f00e56b74f7e53e1034") # Branch 'linphone'
set(EP_gsm_PATCH_COMMAND "${CMAKE_COMMAND}" "-E" "copy" "${CMAKE_CURRENT_SOURCE_DIR}/builders/gsm/CMakeLists.txt" "<SOURCE_DIR>")
...@@ -20,4 +20,20 @@ ...@@ -20,4 +20,20 @@
# #
############################################################################ ############################################################################
linphone_builder_add_autotools_project(linphone) set(EP_linphone_GIT_REPOSITORY "git://git.linphone.org/linphone.git")
set(EP_linphone_GIT_TAG "3a8d2ee20d219432b40cc583dd0d0a3e28e4e7f7") # Branch 'master'
set(EP_linphone_AUTOTOOLS "yes")
set(EP_linphone_CONFIGURE_OPTIONS "--disable-strict --enable-bellesip --enable-external-ortp --enable-external-mediastreamer")
set(EP_linphone_DEPENDENCIES EP_bellesip EP_ortp EP_ms2 EP_xml2)
if(${ENABLE_ZRTP})
# TODO
else(${ENABLE_ZRTP})
set(EP_linphone_CONFIGURE_OPTIONS "${EP_linphone_CONFIGURE_OPTIONS} --disable-zrtp")
endif(${ENABLE_ZRTP})
if(${ENABLE_UNIT_TESTS})
list(APPEND EP_linphone_DEPENDENCIES EP_cunit)
else(${ENABLE_UNIT_TESTS})
set(EP_linphone_CONFIGURE_OPTIONS "${EP_linphone_CONFIGURE_OPTIONS} --disable-tests")
endif(${ENABLE_UNIT_TESTS})
...@@ -20,4 +20,49 @@ ...@@ -20,4 +20,49 @@
# #
############################################################################ ############################################################################
linphone_builder_add_autotools_project(ms2) set(EP_ms2_GIT_REPOSITORY "git://git.linphone.org/mediastreamer2.git")
set(EP_ms2_GIT_TAG "a16157a62d0512b54ee7b36dadea5a95e83847c0") # Branch 'master'
set(EP_ms2_AUTOTOOLS "yes")
set(EP_ms2_CONFIGURE_OPTIONS "--disable-strict --enable-external-ortp")
set(EP_ms2_DEPENDENCIES EP_ortp)
if(${ENABLE_GSM})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --with-gsm=${CMAKE_INSTALL_PREFIX}")
list(APPEND EP_ms2_DEPENDENCIES EP_gsm)
else(${ENABLE_GSM})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-gsm")
endif(${ENABLE_GSM})
if(${ENABLE_OPUS})
list(APPEND EP_ms2_DEPENDENCIES EP_opus)
else(${ENABLE_OPUS})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-opus")
endif(${ENABLE_OPUS})
if(${ENABLE_SPEEX})
list(APPEND EP_ms2_DEPENDENCIES EP_speex)
else(${ENABLE_SPEEX})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-speex")
endif(${ENABLE_SPEEX})
if(${ENABLE_FFMPEG})
list(APPEND EP_ms2_DEPENDENCIES EP_ffmpeg)
else(${ENABLE_FFMPEG})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-ffmpeg")
endif(${ENABLE_FFMPEG})
if(${ENABLE_VPX})
list(APPEND EP_ms2_DEPENDENCIES EP_vpx)
else(${ENABLE_VPX})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-vp8")
endif(${ENABLE_VPX})
if("${BUILD_V4L}" STREQUAL "yes")
list(APPEND EP_ms2_DEPENDENCIES EP_v4l)
endif("${BUILD_V4L}" STREQUAL "yes")
if(${ENABLE_UNIT_TESTS})
list(APPEND EP_ms2_DEPENDENCIES EP_cunit)
else(${ENABLE_UNIT_TESTS})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-tests")
endif(${ENABLE_UNIT_TESTS})
...@@ -20,4 +20,7 @@ ...@@ -20,4 +20,7 @@
# #
############################################################################ ############################################################################
linphone_builder_add_autotools_project(opus) set(EP_opus_GIT_REPOSITORY "git://git.opus-codec.org/opus.git")
set(EP_opus_GIT_TAG "v1.0.3")
set(EP_opus_AUTOTOOLS "yes")
set(EP_opus_CONFIGURE_OPTIONS "--disable-extra-programs --disable-doc")
...@@ -20,4 +20,19 @@ ...@@ -20,4 +20,19 @@
# #
############################################################################ ############################################################################
linphone_builder_add_autotools_project(ortp) set(EP_ortp_GIT_REPOSITORY "git://git.linphone.org/ortp.git")
set(EP_ortp_GIT_TAG "e1ea9d5121cdabbcc16ffdb884bf705caacd81a1") # Branch 'master'
set(EP_ortp_AUTOTOOLS "yes")
set(EP_ortp_CONFIGURE_OPTIONS "--disable-strict")
set(EP_ortp_DEPENDENCIES )
if(${ENABLE_SRTP})
set(EP_ortp_CONFIGURE_OPTIONS "${EP_ortp_CONFIGURE_OPTIONS} --with-srtp=${CMAKE_INSTALL_PREFIX}")
list(APPEND EP_ortp_DEPENDENCIES EP_srtp)
endif(${ENABLE_SRTP})
if(${ENABLE_ZRTP})
# TODO
else(${ENABLE_ZRTP})
set(EP_ortp_CONFIGURE_OPTIONS "${EP_ortp_CONFIGURE_OPTIONS} --disable-zrtp")
endif(${ENABLE_ZRTP})
...@@ -20,4 +20,5 @@ ...@@ -20,4 +20,5 @@
# #
############################################################################ ############################################################################
linphone_builder_add_cmake_project(polarssl) set(EP_polarssl_GIT_REPOSITORY "git://git.linphone.org/polarssl.git")
set(EP_polarssl_GIT_TAG "3681900a1e0a3a8c77fc33c545cccd93977a1cf2") # Branch 'linphone'
...@@ -20,4 +20,5 @@ ...@@ -20,4 +20,5 @@
# #
############################################################################ ############################################################################
linphone_builder_add_cmake_project(speex) set(EP_speex_GIT_REPOSITORY "git://git.linphone.org/speex.git")
set(EP_speex_GIT_TAG "302ce26e309efb1b4a4b7b6ea4807375d157258f") # Branch 'linphone'
...@@ -20,4 +20,5 @@ ...@@ -20,4 +20,5 @@
# #
############################################################################ ############################################################################
linphone_builder_add_cmake_project(srtp) set(EP_srtp_GIT_REPOSITORY "git://git.linphone.org/srtp.git")
set(EP_srtp_GIT_TAG "da2ece56f18d35a12f0fee5dcb99e03ff15864de") # Branch 'master'
...@@ -20,4 +20,6 @@ ...@@ -20,4 +20,6 @@
# #
############################################################################ ############################################################################
linphone_builder_add_autotools_project(v4l) set(EP_v4l_URL "http://linuxtv.org/downloads/v4l-utils/v4l-utils-1.0.0.tar.bz2")
set(EP_v4l_AUTOTOOLS "yes")
set(EP_v4l_CONFIGURE_OPTIONS "--disable-v4l-utils --disable-libdvbv5 --with-udevdir=${CMAKE_INSTALL_PREFIX}/etc --without-jpeg")
...@@ -20,4 +20,13 @@ ...@@ -20,4 +20,13 @@
# #
############################################################################ ############################################################################
linphone_builder_add_autotools_project(vpx) set(EP_vpx_GIT_REPOSITORY "https://chromium.googlesource.com/webm/libvpx")
set(EP_vpx_GIT_TAG "v1.3.0")
set(EP_vpx_AUTOTOOLS "yes")
set(EP_vpx_CONFIGURE_OPTIONS "--enable-pic --enable-error-concealment --enable-realtime-only --enable-spatial-resampling --enable-vp8 --disable-vp9 --enable-libs --disable-install-docs --disable-debug-libs --disable-examples --disable-unit-tests")
if(APPLE)
set(EP_vpx_TARGET "x86-darwin10-gcc")
else(APPLE)
set(EP_vpx_TARGET "generic-gnu")
endif(APPLE)
...@@ -20,4 +20,7 @@ ...@@ -20,4 +20,7 @@
# #
############################################################################ ############################################################################
linphone_builder_add_autotools_project(xml2) set(EP_xml2_GIT_REPOSITORY "git://git.gnome.org/libxml2")
set(EP_xml2_GIT_TAG "v2.8.0")
set(EP_xml2_AUTOTOOLS "yes")
set(EP_xml2_CONFIGURE_OPTIONS "--with-minimum --with-xpath --with-tree --with-schemas --with-reader --with-writer --enable-rebuild-docs=no")
...@@ -156,37 +156,27 @@ macro(linphone_builder_set_ep_directories PROJNAME) ...@@ -156,37 +156,27 @@ macro(linphone_builder_set_ep_directories PROJNAME)
endif() endif()
endmacro(linphone_builder_set_ep_directories) endmacro(linphone_builder_set_ep_directories)
macro(linphone_builder_add_cmake_project PROJNAME) macro(linphone_builder_add_project PROJNAME)
linphone_builder_set_ep_directories(${PROJNAME}) linphone_builder_set_ep_directories(${PROJNAME})
linphone_builder_apply_extra_flags("${EP_${PROJNAME}_EXTRA_CFLAGS}" "${EP_${PROJNAME}_EXTRA_CXXFLAGS}" "${EP_${PROJNAME}_EXTRA_LDFLAGS}") linphone_builder_apply_extra_flags("${EP_${PROJNAME}_EXTRA_CFLAGS}" "${EP_${PROJNAME}_EXTRA_CXXFLAGS}" "${EP_${PROJNAME}_EXTRA_LDFLAGS}")
linphone_builder_expand_external_project_vars() linphone_builder_expand_external_project_vars()
if(NOT "${EP_${PROJNAME}_URL}" STREQUAL "") if("${EP_${PROJNAME}_AUTOTOOLS}" STREQUAL "yes")
set(DOWNLOAD_SOURCE URL ${EP_${PROJNAME}_URL}) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builders/${PROJNAME}/configure.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_configure.sh)
else(NOT "${EP_${PROJNAME}_URL}" STREQUAL "") configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builders/${PROJNAME}/build.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_build.sh)
set(DOWNLOAD_SOURCE GIT_REPOSITORY ${EP_${PROJNAME}_GIT_REPOSITORY} GIT_TAG ${EP_${PROJNAME}_GIT_TAG}) configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builders/${PROJNAME}/install.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_install.sh)
endif(NOT "${EP_${PROJNAME}_URL}" STREQUAL "")
set(BUILD_COMMANDS
ExternalProject_Add(EP_${PROJNAME} CONFIGURE_COMMAND ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_configure.sh
DEPENDS ${EP_${PROJNAME}_DEPENDENCIES} BUILD_COMMAND ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_build.sh
TMP_DIR ${ep_tmp} INSTALL_COMMAND ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_install.sh
BINARY_DIR ${ep_build} )
${DOWNLOAD_SOURCE} else("${EP_${PROJNAME}_AUTOTOOLS}" STREQUAL "yes")
PATCH_COMMAND ${EP_${PROJNAME}_PATCH_COMMAND} set(BUILD_COMMANDS
CMAKE_GENERATOR ${CMAKE_GENERATOR} CMAKE_ARGS ${EP_${PROJNAME}_CMAKE_OPTIONS}
CMAKE_ARGS ${EP_${PROJNAME}_CMAKE_OPTIONS} CMAKE_CACHE_ARGS ${LINPHONE_BUILDER_EP_ARGS}
CMAKE_CACHE_ARGS ${LINPHONE_BUILDER_EP_ARGS} )
) endif("${EP_${PROJNAME}_AUTOTOOLS}" STREQUAL "yes")
endmacro(linphone_builder_add_cmake_project)
macro(linphone_builder_add_autotools_project PROJNAME)
linphone_builder_set_ep_directories(${PROJNAME})
linphone_builder_apply_extra_flags("${EP_${PROJNAME}_EXTRA_CFLAGS}" "${EP_${PROJNAME}_EXTRA_CXXFLAGS}" "${EP_${PROJNAME}_EXTRA_LDFLAGS}")
linphone_builder_expand_external_project_vars()
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builders/${PROJNAME}/configure.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_configure.sh)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builders/${PROJNAME}/build.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_build.sh)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builders/${PROJNAME}/install.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_install.sh)
if(NOT "${EP_${PROJNAME}_URL}" STREQUAL "") if(NOT "${EP_${PROJNAME}_URL}" STREQUAL "")
set(DOWNLOAD_SOURCE URL ${EP_${PROJNAME}_URL}) set(DOWNLOAD_SOURCE URL ${EP_${PROJNAME}_URL})
...@@ -201,8 +191,12 @@ macro(linphone_builder_add_autotools_project PROJNAME) ...@@ -201,8 +191,12 @@ macro(linphone_builder_add_autotools_project PROJNAME)
${DOWNLOAD_SOURCE} ${DOWNLOAD_SOURCE}
PATCH_COMMAND ${EP_${PROJNAME}_PATCH_COMMAND} PATCH_COMMAND ${EP_${PROJNAME}_PATCH_COMMAND}
CMAKE_GENERATOR ${CMAKE_GENERATOR} CMAKE_GENERATOR ${CMAKE_GENERATOR}
CONFIGURE_COMMAND ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_configure.sh ${BUILD_COMMANDS}
BUILD_COMMAND ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_build.sh
INSTALL_COMMAND ${CMAKE_CURRENT_BINARY_DIR}/EP_${PROJNAME}_install.sh
) )
endmacro(linphone_builder_add_autotools_project PROJNAME) endmacro(linphone_builder_add_project)
macro(linphone_builder_add_external_projects)
foreach(BUILDER ${LINPHONE_BUILDER_BUILDERS})
linphone_builder_add_project(${BUILDER})
endforeach(BUILDER)
endmacro(linphone_builder_add_external_projects)
...@@ -31,4 +31,4 @@ list(APPEND EP_speex_CMAKE_OPTIONS ...@@ -31,4 +31,4 @@ list(APPEND EP_speex_CMAKE_OPTIONS
) )
# opus # opus
set(EP_opus_CONFIGURE_OPTIONS "${EP_opus_CONFIGURE_OPTIONS} --enable-fixed-point") set(EP_opus_CONFIGURE_OPTIONS "${EP_opus_CONFIGURE_OPTIONS} --enable-fixed-point")
\ No newline at end of file
...@@ -39,8 +39,9 @@ set(DEFAULT_VALUE_ENABLE_X264 OFF) ...@@ -39,8 +39,9 @@ set(DEFAULT_VALUE_ENABLE_X264 OFF)
set(DEFAULT_VALUE_ENABLE_TUNNEL OFF) set(DEFAULT_VALUE_ENABLE_TUNNEL OFF)
set(DEFAULT_VALUE_ENABLE_UNIT_TESTS ON) set(DEFAULT_VALUE_ENABLE_UNIT_TESTS ON)
# Include default configuration
include(configs/config-default.cmake) # Include builders
include(builders/CMakeLists.txt)
set(AUTOTOOLS_SHARED_LIBRARIES "--disable-static --enable-shared") set(AUTOTOOLS_SHARED_LIBRARIES "--disable-static --enable-shared")
...@@ -79,4 +80,4 @@ set(EP_ortp_CONFIGURE_OPTIONS "${AUTOTOOLS_SHARED_LIBRARIES} ${EP_ortp_CONFIGURE ...@@ -79,4 +80,4 @@ set(EP_ortp_CONFIGURE_OPTIONS "${AUTOTOOLS_SHARED_LIBRARIES} ${EP_ortp_CONFIGURE
set(EP_ms2_CONFIGURE_OPTIONS "${AUTOTOOLS_SHARED_LIBRARIES} ${EP_ms2_CONFIGURE_OPTIONS} --disable-nls --disable-theora --disable-sdl --disable-x11 --disable-video --disable-alsa --enable-qsa --enable-relativeprefix=yes") set(EP_ms2_CONFIGURE_OPTIONS "${AUTOTOOLS_SHARED_LIBRARIES} ${EP_ms2_CONFIGURE_OPTIONS} --disable-nls --disable-theora --disable-sdl --disable-x11 --disable-video --disable-alsa --enable-qsa --enable-relativeprefix=yes")
# linphone # linphone
set(EP_linphone_CONFIGURE_OPTIONS "${AUTOTOOLS_SHARED_LIBRARIES} ${EP_linphone_CONFIGURE_OPTIONS} --disable-nls --with-readline=none --enable-gtk_ui=no --enable-console_ui=no --disable-x11 --disable-tutorials --disable-tools --disable-msg-storage --disable-video --disable-alsa --enable-relativeprefix=yes") set(EP_linphone_CONFIGURE_OPTIONS "${AUTOTOOLS_SHARED_LIBRARIES} ${EP_linphone_CONFIGURE_OPTIONS} --disable-nls --with-readline=none --enable-gtk_ui=no --enable-console_ui=yes --disable-x11 --disable-tutorials --disable-tools --disable-msg-storage --disable-video --disable-alsa --enable-relativeprefix=yes")
############################################################################
# config-default.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.
#
############################################################################
# Include linphone builder options definitions
include(cmake/LinphoneBuilderOptions.cmake)
# List of the projects to build. The order is important and must follow the dependencies.
set(LINPHONE_BUILDER_BUILDERS )
if(${ENABLE_UNIT_TESTS})
list(APPEND LINPHONE_BUILDER_BUILDERS cunit)
endif(${ENABLE_UNIT_TESTS})
if(${ENABLE_SRTP})
list(APPEND LINPHONE_BUILDER_BUILDERS srtp)
endif(${ENABLE_SRTP})
if(${ENABLE_GSM})
list(APPEND LINPHONE_BUILDER_BUILDERS gsm)
endif(${ENABLE_GSM})
if(${ENABLE_OPUS})
list(APPEND LINPHONE_BUILDER_BUILDERS opus)
endif(${ENABLE_OPUS})
if(${ENABLE_SPEEX})
list(APPEND LINPHONE_BUILDER_BUILDERS speex)
endif(${ENABLE_SPEEX})
if(${ENABLE_FFMPEG})
list(APPEND LINPHONE_BUILDER_BUILDERS ffmpeg)
endif(${ENABLE_FFMPEG})
if(${ENABLE_VPX})
list(APPEND LINPHONE_BUILDER_BUILDERS vpx)
endif(${ENABLE_VPX})
if("${BUILD_V4L}" STREQUAL "yes")
list(APPEND LINPHONE_BUILDER_BUILDERS v4l)
endif("${BUILD_V4L}" STREQUAL "yes")
list(APPEND LINPHONE_BUILDER_BUILDERS
xml2
antlr3c
polarssl
bellesip
ortp
ms2
linphone
)
# cunit
set(EP_cunit_GIT_REPOSITORY "git://git.linphone.org/cunit.git")
set(EP_cunit_GIT_TAG "86562ef04d0d66c007d7822944a75f540ae37f19") # Branch 'linphone'
set(EP_cunit_CMAKE_OPTIONS "-DENABLE_AUTOMATED=0" "-DENABLE_CONSOLE=0")
# xml2
set(EP_xml2_GIT_REPOSITORY "git://git.gnome.org/libxml2")
set(EP_xml2_GIT_TAG "v2.8.0")
set(EP_xml2_CONFIGURE_OPTIONS "--with-minimum --with-xpath --with-tree --with-schemas --with-reader --with-writer --enable-rebuild-docs=no")
# antlr3c
set(EP_antlr3c_GIT_REPOSITORY "git://git.linphone.org/antlr3.git")
set(EP_antlr3c_GIT_TAG "b882cfc0d8e6485d6d050e7f5ec36f870c7ece7b") # Branch 'linphone'
set(EP_antlr3c_CMAKE_OPTIONS "-DENABLE_DEBUGGER=0")
# polarssl
set(EP_polarssl_GIT_REPOSITORY "git://git.linphone.org/polarssl.git")
set(EP_polarssl_GIT_TAG "3681900a1e0a3a8c77fc33c545cccd93977a1cf2") # Branch 'linphone'
# belle-sip
set(EP_bellesip_GIT_REPOSITORY "git://git.linphone.org/belle-sip.git")
set(EP_bellesip_GIT_TAG "cb977e6aaa0a319c437d08e3d67492d1453adbfb") # Branch 'master'
set(EP_bellesip_CMAKE_OPTIONS )
set(EP_bellesip_DEPENDENCIES EP_antlr3c EP_polarssl)
if(${ENABLE_UNIT_TESTS})
list(APPEND EP_bellesip_DEPENDENCIES EP_cunit)
else(${ENABLE_UNIT_TESTS})
list(APPEND EP_bellesip_CMAKE_OPTIONS "-DENABLE_TESTS=0")
endif(${ENABLE_UNIT_TESTS})
# srtp
set(EP_srtp_GIT_REPOSITORY "git://git.linphone.org/srtp.git")
set(EP_srtp_GIT_TAG "da2ece56f18d35a12f0fee5dcb99e03ff15864de") # Branch 'master'
# gsm
set(EP_gsm_GIT_REPOSITORY "git://git.linphone.org/gsm.git")
set(EP_gsm_GIT_TAG "8729c98e098341582e9c9f00e56b74f7e53e1034") # Branch 'linphone'
set(EP_gsm_PATCH_COMMAND "${CMAKE_COMMAND}" "-E" "copy" "${CMAKE_CURRENT_SOURCE_DIR}/builders/gsm/CMakeLists.txt" "<SOURCE_DIR>")
# speex
set(EP_speex_GIT_REPOSITORY "git://git.linphone.org/speex.git")
set(EP_speex_GIT_TAG "302ce26e309efb1b4a4b7b6ea4807375d157258f") # Branch 'linphone'
# opus
set(EP_opus_GIT_REPOSITORY "git://git.opus-codec.org/opus.git")
set(EP_opus_GIT_TAG "v1.0.3")
set(EP_opus_CONFIGURE_OPTIONS "--disable-extra-programs --disable-doc")
# FFmpeg
set(EP_ffmpeg_URL "http://ffmpeg.org/releases/ffmpeg-0.10.2.tar.gz")
# Disable video acceleration support for compatibility with older Mac OS X versions (vda, vaapi, vdpau).
set(EP_ffmpeg_CONFIGURE_OPTIONS "--enable-pic --disable-zlib --disable-bzlib --disable-mmx --disable-ffplay --disable-ffprobe --disable-ffserver --disable-avdevice --disable-avfilter --disable-network --disable-avformat --disable-everything --enable-decoder=mjpeg --enable-encoder=mjpeg --disable-vda --disable-vaapi --disable-vdpau")
set(EP_ffmpeg_ARCH "i386")
if(APPLE)
set(EP_ffmpeg_TARGET_OS "darwin")
else(APPLE)
set(EP_ffmpeg_TARGET_OS "linux")
endif(APPLE)
# vpx
set(EP_vpx_GIT_REPOSITORY "https://chromium.googlesource.com/webm/libvpx")
set(EP_vpx_GIT_TAG "v1.3.0")
set(EP_vpx_CONFIGURE_OPTIONS "--enable-pic --enable-error-concealment --enable-realtime-only --enable-spatial-resampling --enable-vp8 --disable-vp9 --enable-libs --disable-install-docs --disable-debug-libs --disable-examples --disable-unit-tests")
if(APPLE)
set(EP_vpx_TARGET "x86-darwin10-gcc")
else(APPLE)
set(EP_vpx_TARGET "generic-gnu")
endif(APPLE)
# v4l
set(EP_v4l_URL "http://linuxtv.org/downloads/v4l-utils/v4l-utils-1.0.0.tar.bz2")
set(EP_v4l_CONFIGURE_OPTIONS "--disable-v4l-utils --disable-libdvbv5 --with-udevdir=${CMAKE_INSTALL_PREFIX}/etc --without-jpeg")
# oRTP
set(EP_ortp_GIT_REPOSITORY "git://git.linphone.org/ortp.git")
set(EP_ortp_GIT_TAG "e1ea9d5121cdabbcc16ffdb884bf705caacd81a1") # Branch 'master'
set(EP_ortp_CONFIGURE_OPTIONS "--disable-strict")
set(EP_ortp_DEPENDENCIES )
if(${ENABLE_SRTP})
set(EP_ortp_CONFIGURE_OPTIONS "${EP_ortp_CONFIGURE_OPTIONS} --with-srtp=${CMAKE_INSTALL_PREFIX}")
list(APPEND EP_ortp_DEPENDENCIES EP_srtp)
endif(${ENABLE_SRTP})
if(${ENABLE_ZRTP})
# TODO
else(${ENABLE_ZRTP})
set(EP_ortp_CONFIGURE_OPTIONS "${EP_ortp_CONFIGURE_OPTIONS} --disable-zrtp")
endif(${ENABLE_ZRTP})
# mediastreamer2
set(EP_ms2_GIT_REPOSITORY "git://git.linphone.org/mediastreamer2.git")
set(EP_ms2_GIT_TAG "a16157a62d0512b54ee7b36dadea5a95e83847c0") # Branch 'master'
set(EP_ms2_CONFIGURE_OPTIONS "--disable-strict --enable-external-ortp")
set(EP_ms2_DEPENDENCIES EP_ortp)
if(${ENABLE_GSM})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --with-gsm=${CMAKE_INSTALL_PREFIX}")
list(APPEND EP_ms2_DEPENDENCIES EP_gsm)
else(${ENABLE_GSM})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-gsm")
endif(${ENABLE_GSM})
if(${ENABLE_OPUS})
list(APPEND EP_ms2_DEPENDENCIES EP_opus)
else(${ENABLE_OPUS})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-opus")
endif(${ENABLE_OPUS})
if(${ENABLE_SPEEX})
list(APPEND EP_ms2_DEPENDENCIES EP_speex)
else(${ENABLE_SPEEX})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-speex")
endif(${ENABLE_SPEEX})
if(${ENABLE_FFMPEG})
list(APPEND EP_ms2_DEPENDENCIES EP_ffmpeg)
else(${ENABLE_FFMPEG})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-ffmpeg")
endif(${ENABLE_FFMPEG})
if(${ENABLE_VPX})
list(APPEND EP_ms2_DEPENDENCIES EP_vpx)
else(${ENABLE_VPX})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-vp8")
endif(${ENABLE_VPX})
if("${BUILD_V4L}" STREQUAL "yes")
list(APPEND EP_ms2_DEPENDENCIES EP_v4l)
endif("${BUILD_V4L}" STREQUAL "yes")
if(${ENABLE_UNIT_TESTS})
list(APPEND EP_ms2_DEPENDENCIES EP_cunit)
else(${ENABLE_UNIT_TESTS})
set(EP_ms2_CONFIGURE_OPTIONS "${EP_ms2_CONFIGURE_OPTIONS} --disable-tests")
endif(${ENABLE_UNIT_TESTS})
# linphone
set(EP_linphone_GIT_REPOSITORY "git://git.linphone.org/linphone.git")
set(EP_linphone_GIT_TAG "3a8d2ee20d219432b40cc583dd0d0a3e28e4e7f7") # Branch 'master'
set(EP_linphone_CONFIGURE_OPTIONS "--disable-strict --enable-bellesip --enable-external-ortp --enable-external-mediastreamer")
set(EP_linphone_DEPENDENCIES EP_bellesip EP_ortp EP_ms2 EP_xml2)
if(${ENABLE_ZRTP})
# TODO
else(${ENABLE_ZRTP})
set(EP_linphone_CONFIGURE_OPTIONS "${EP_linphone_CONFIGURE_OPTIONS} --disable-zrtp")
endif(${ENABLE_ZRTP})
if(${ENABLE_UNIT_TESTS})
list(APPEND EP_linphone_DEPENDENCIES EP_cunit)
else(${ENABLE_UNIT_TESTS})
set(EP_linphone_CONFIGURE_OPTIONS "${EP_linphone_CONFIGURE_OPTIONS} --disable-tests")
endif(${ENABLE_UNIT_TESTS})
...@@ -39,8 +39,9 @@ set(DEFAULT_VALUE_ENABLE_X264 ON) ...@@ -39,8 +39,9 @@ set(DEFAULT_VALUE_ENABLE_X264 ON)
set(DEFAULT_VALUE_ENABLE_TUNNEL OFF) set(DEFAULT_VALUE_ENABLE_TUNNEL OFF)
set(DEFAULT_VALUE_ENABLE_UNIT_TESTS ON) set(DEFAULT_VALUE_ENABLE_UNIT_TESTS ON)
# Include default configuration
include(configs/config-default.cmake) # Include builders
include(builders/CMakeLists.txt)
set(AUTOTOOLS_SHARED_LIBRARIES "--disable-static --enable-shared") set(AUTOTOOLS_SHARED_LIBRARIES "--disable-static --enable-shared")
......
...@@ -39,8 +39,9 @@ set(DEFAULT_VALUE_ENABLE_X264 OFF) ...@@ -39,8 +39,9 @@ set(DEFAULT_VALUE_ENABLE_X264 OFF)
set(DEFAULT_VALUE_ENABLE_TUNNEL OFF) set(DEFAULT_VALUE_ENABLE_TUNNEL OFF)
set(DEFAULT_VALUE_ENABLE_UNIT_TESTS OFF) set(DEFAULT_VALUE_ENABLE_UNIT_TESTS OFF)
# Include default configuration
include(configs/config-default.cmake) # Include builders
include(builders/CMakeLists.txt)
set(AUTOTOOLS_SHARED_LIBRARIES "--disable-static --enable-shared") set(AUTOTOOLS_SHARED_LIBRARIES "--disable-static --enable-shared")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment