Commit 57d38dde authored by Ghislain MARY's avatar Ghislain MARY

Rework definition of builders.

parent 45de5211
......@@ -91,7 +91,7 @@ else()
add_dependencies(TARGET_linphone_builder TARGET_bellesip)
add_dependencies(TARGET_bellesip TARGET_bctoolbox)
if(LINPHONE_BUILDER_BUILD_DEPENDENCIES)
if( NOT DISABLE_BC_ANTLR)
if(NOT DISABLE_BC_ANTLR)
linphone_builder_add_builder_to_target(TARGET_bellesip antlr3c)
endif()
if(NOT ANDROID AND NOT APPLE AND NOT QNX)
......
......@@ -20,4 +20,4 @@
#
############################################################################
set(EP_androidcpufeatures_EXTERNAL_SOURCE_PATHS "cmake-builder/builders/androidcpufeatures")
lcb_external_source_paths("cmake-builder/builders/androidcpufeatures")
......@@ -20,4 +20,4 @@
#
############################################################################
set(EP_androidsupport_EXTERNAL_SOURCE_PATHS "cmake-builder/builders/androidsupport")
lcb_external_source_paths("cmake-builder/builders/androidsupport")
......@@ -20,13 +20,11 @@
#
############################################################################
set(EP_antlr3c_GIT_REPOSITORY "git://git.linphone.org/antlr3.git" CACHE STRING "antlr3c repository URL")
set(EP_antlr3c_GIT_TAG_LATEST "linphone" CACHE STRING "antlr3c tag to use when compiling latest version")
set(EP_antlr3c_GIT_TAG "52075ffb35975c6901e924b4a763b6fb23abd623" CACHE STRING "antlr3c tag to use")
set(EP_antlr3c_EXTERNAL_SOURCE_PATHS "antlr3c" "antlr3" "externals/antlr3")
set(EP_antlr3c_MAY_BE_FOUND_ON_SYSTEM TRUE)
set(EP_antlr3c_IGNORE_WARNINGS TRUE)
lcb_git_repository("git://git.linphone.org/antlr3.git")
lcb_git_tag_latest("linphone")
lcb_git_tag("52075ffb35975c6901e924b4a763b6fb23abd623")
lcb_external_source_paths("antlr3c" "antlr3" "externals/antlr3")
lcb_may_be_found_on_system(YES)
lcb_ignore_warnings(YES)
set(EP_antlr3c_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
set(EP_antlr3c_CMAKE_OPTIONS "-DENABLE_DEBUGGER=NO")
lcb_cmake_options("-DENABLE_DEBUGGER=NO")
############################################################################
# bcg729.cmake
# bcg729bcng.cmake
# Copyright (C) 2014 Belledonne Communications, Grenoble France
#
############################################################################
......@@ -20,11 +20,10 @@
#
############################################################################
set(EP_bcg729bcng_GIT_REPOSITORY "git://git.linphone.org/bcg729.git" CACHE STRING "bcg729 repository URL")
set(EP_bcg729bcng_GIT_TAG_LATEST "master" CACHE STRING "bcg729 tag to use when compiling latest version")
set(EP_bcg729bcng_GIT_TAG "1.0.2" CACHE STRING "bcg729 tag to use")
set(EP_bcg729bcng_EXTERNAL_SOURCE_PATHS "bcg729")
set(EP_bcg729bcng_GROUPABLE YES)
lcb_git_repository("git://git.linphone.org/bcg729.git")
lcb_git_tag_latest("master")
lcb_git_tag("1.0.2")
lcb_external_source_paths("bcg729")
lcb_groupable(YES)
set(EP_bcg729bcng_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_PLUGIN_LINKING_TYPE})
set(EP_bcg729bcng_CMAKE_OPTIONS "-DENABLE_MSPLUGIN=NO")
lcb_cmake_options("-DENABLE_MSPLUGIN=NO")
############################################################################
# belle-sip.cmake
# bctoolbox.cmake
# Copyright (C) 2014 Belledonne Communications, Grenoble France
#
############################################################################
......@@ -20,39 +20,35 @@
#
############################################################################
set(EP_bctoolbox_GIT_REPOSITORY "git://git.linphone.org/bctoolbox.git" CACHE STRING "bctoolbox repository URL")
set(EP_bctoolbox_GIT_TAG_LATEST "master" CACHE STRING "bctoolbox tag to use when compiling latest version")
set(EP_bctoolbox_GIT_TAG "master" CACHE STRING "bctoolbox tag to use")
set(EP_bctoolbox_EXTERNAL_SOURCE_PATHS "bctoolbox")
set(EP_bctoolbox_GROUPABLE YES)
lcb_git_repository("git://git.linphone.org/bctoolbox.git")
lcb_git_tag_latest("master")
lcb_git_tag("master")
lcb_external_source_paths("bctoolbox")
lcb_groupable(YES)
lcb_spec_file("bctoolbox.spec")
set(EP_bctoolbox_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
set(EP_bctoolbox_DEPENDENCIES )
if(LINPHONE_BUILDER_BUILD_DEPENDENCIES)
if(ENABLE_MBEDTLS)
list(APPEND EP_bctoolbox_DEPENDENCIES EP_mbedtls)
lcb_dependencies("mbedtls")
elseif(ENABLE_POLARSSL)
list(APPEND EP_bctoolbox_DEPENDENCIES EP_polarssl)
lcb_dependencies("polarssl")
endif()
if(ENABLE_UNIT_TESTS)
lcb_dependencies("bcunit")
endif()
endif()
list(APPEND EP_bctoolbox_CMAKE_OPTIONS
lcb_cmake_options(
"-DENABLE_TESTS=${ENABLE_UNIT_TESTS}"
"-DENABLE_TESTS_COMPONENT=${ENABLE_UNIT_TESTS}"
)
if(ENABLE_UNIT_TESTS AND LINPHONE_BUILDER_BUILD_DEPENDENCIES)
list(APPEND EP_bctoolbox_DEPENDENCIES EP_bcunit)
endif()
# TODO: Activate strict compilation options on IOS
if(IOS)
list(APPEND EP_bctoolbox_CMAKE_OPTIONS "-DENABLE_STRICT=NO")
lcb_cmake_options("-DENABLE_STRICT=NO")
endif()
if(EP_bctoolbox_BUILD_METHOD STREQUAL "rpm")
set(EP_bctoolbox_SPEC_FILE "bctoolbox.spec")
set(EP_bctoolbox_CONFIGURE_COMMAND_SOURCE ${CMAKE_CURRENT_SOURCE_DIR}/builders/bctoolbox/configure.sh.rpm.cmake)
set(EP_bctoolbox_BUILD_COMMAND_SOURCE ${CMAKE_CURRENT_SOURCE_DIR}/builders/bctoolbox/build.sh.rpm.cmake)
endif()
#
#set(EP_bctoolbox_RPMBUILD_NAME "belle-sip")
......@@ -20,12 +20,13 @@
#
############################################################################
set(EP_bcunit_GIT_REPOSITORY "git://git.linphone.org/bcunit.git" CACHE STRING "bcunit repository URL")
set(EP_bcunit_GIT_TAG_LATEST "linphone" CACHE STRING "bcunit tag to use when compiling latest version")
set(EP_bcunit_GIT_TAG "0a0a9c60f5a1b899ae26b705fa5224ef25377982" CACHE STRING "bcunit tag to use")
set(EP_bcunit_EXTERNAL_SOURCE_PATHS "bcunit")
set(EP_bcunit_IGNORE_WARNINGS TRUE)
lcb_git_repository("git://git.linphone.org/bcunit.git")
lcb_git_tag_latest("linphone")
lcb_git_tag("0a0a9c60f5a1b899ae26b705fa5224ef25377982")
lcb_external_source_paths("bcunit")
lcb_ignore_warnings(YES)
set(EP_bcunit_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
set(EP_bcunit_CMAKE_OPTIONS "-DENABLE_AUTOMATED=YES" "-DENABLE_CONSOLE=NO")
lcb_cmake_options(
"-DENABLE_AUTOMATED=YES"
"-DENABLE_CONSOLE=NO"
)
......@@ -20,21 +20,15 @@
#
############################################################################
set(EP_belcard_GIT_REPOSITORY "git://git.linphone.org/belcard.git" CACHE STRING "belcard repository URL")
set(EP_belcard_GIT_TAG_LATEST "master" CACHE STRING "belcard tag to use when compiling latest version")
set(EP_belcard_EXTERNAL_SOURCE_PATHS "belcard")
set(EP_belcard_GROUPABLE YES)
set(EP_belcard_DEPENDENCIES EP_bctoolbox EP_belr)
lcb_git_repository("git://git.linphone.org/belcard.git")
lcb_git_tag_latest("master")
lcb_git_tag("master")
lcb_external_source_paths("belcard")
lcb_groupable(YES)
if(EP_belcard_FORCE_AUTOTOOLS)
set(EP_belcard_LINKING_TYPE "--enable-static")
set(EP_belcard_USE_AUTOGEN True)
else()
set(EP_belcard_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
endif()
lcb_dependencies("bctoolbox" "belr")
# TODO: Activate strict compilation options on IOS
if(IOS)
list(APPEND EP_belcard_CMAKE_OPTIONS "-DENABLE_STRICT=NO")
lcb_cmake_options("-DENABLE_STRICT=NO")
endif()
############################################################################
# belle-sip.cmake
# bellesip.cmake
# Copyright (C) 2014 Belledonne Communications, Grenoble France
#
############################################################################
......@@ -20,36 +20,35 @@
#
############################################################################
set(EP_bellesip_GIT_REPOSITORY "git://git.linphone.org/belle-sip.git" CACHE STRING "bellesip repository URL")
set(EP_bellesip_GIT_TAG_LATEST "master" CACHE STRING "bellesip tag to use when compiling latest version")
set(EP_bellesip_GIT_TAG "1.5.3" CACHE STRING "bellesip tag to use")
set(EP_bellesip_EXTERNAL_SOURCE_PATHS "belle-sip")
set(EP_bellesip_GROUPABLE YES)
lcb_git_repository("git://git.linphone.org/belle-sip.git")
lcb_git_tag_latest("master")
lcb_git_tag("1.5.3")
lcb_external_source_paths("belle-sip")
lcb_groupable(YES)
lcb_spec_file("belle-sip.spec")
lcb_rpmbuild_name("belle-sip")
set(EP_bellesip_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
set(EP_bellesip_DEPENDENCIES EP_bctoolbox)
lcb_dependencies("bctoolbox")
if(ENABLE_TUNNEL)
lcb_dependencies("tunnel")
endif()
if(LINPHONE_BUILDER_BUILD_DEPENDENCIES)
if(NOT DISABLE_BC_ANTLR)
list(APPEND EP_bellesip_DEPENDENCIES EP_antlr3c)
lcb_dependencies("antlr3c")
endif()
if (NOT QNX)
list(APPEND EP_bellesip_DEPENDENCIES EP_zlib)
lcb_dependencies("zlib")
endif()
endif()
set(EP_bellesip_CMAKE_OPTIONS "-DENABLE_RTP_MAP_ALWAYS_IN_SDP=${ENABLE_RTP_MAP_ALWAYS_IN_SDP}")
lcb_cmake_options(
"-DENABLE_RTP_MAP_ALWAYS_IN_SDP=${ENABLE_RTP_MAP_ALWAYS_IN_SDP}"
"-DENABLE_TUNNEL=${ENABLE_TUNNEL}"
"-DENABLE_TESTS=${ENABLE_UNIT_TESTS}"
)
# TODO: Activate strict compilation options on IOS
if(IOS)
list(APPEND EP_bellesip_CMAKE_OPTIONS "-DENABLE_STRICT=NO")
endif()
list(APPEND EP_bellesip_CMAKE_OPTIONS "-DENABLE_TUNNEL=${ENABLE_TUNNEL}")
if(ENABLE_TUNNEL)
list(APPEND EP_bellesip_DEPENDENCIES EP_tunnel)
lcb_cmake_options("-DENABLE_STRICT=NO")
endif()
list(APPEND EP_bellesip_CMAKE_OPTIONS "-DENABLE_TESTS=${ENABLE_UNIT_TESTS}")
set(EP_bellesip_SPEC_FILE "belle-sip.spec")
set(EP_bellesip_RPMBUILD_NAME "belle-sip")
......@@ -20,20 +20,15 @@
#
############################################################################
set(EP_belr_GIT_REPOSITORY "git://git.linphone.org/belr.git" CACHE STRING "belr repository URL")
set(EP_belr_GIT_TAG_LATEST "master" CACHE STRING "belr tag to use when compiling latest version")
set(EP_belr_EXTERNAL_SOURCE_PATHS "belr")
set(EP_belr_GROUPABLE YES)
lcb_git_repository("git://git.linphone.org/belr.git")
lcb_git_tag_latest("master")
lcb_git_tag("master")
lcb_external_source_paths("belr")
lcb_groupable(YES)
if(EP_belr_FORCE_AUTOTOOLS)
set(EP_belr_LINKING_TYPE "--enable-static")
set(EP_belr_USE_AUTOGEN True)
else()
set(EP_belr_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
endif()
set(EP_belr_DEPENDENCIES EP_bctoolbox)
lcb_dependencies("bctoolbox")
# TODO: Activate strict compilation options on IOS
if(IOS)
list(APPEND EP_belr_CMAKE_OPTIONS "-DENABLE_STRICT=NO")
lcb_cmake_options("-DENABLE_STRICT=NO")
endif()
......@@ -20,9 +20,7 @@
#
############################################################################
set(EP_bv16_GIT_REPOSITORY "git://git.linphone.org/bv16-floatingpoint.git" CACHE STRING "bv16 repository URL")
set(EP_bv16_GIT_TAG_LATEST "linphone" CACHE STRING "bv16 tag to use when compiling latest version")
set(EP_bv16_GIT_TAG "6899f2759c7b19d5402335d3a937c53020abfeca" CACHE STRING "bv16 tag to use")
set(EP_bv16_EXTERNAL_SOURCE_PATHS "externals/bv16-floatingpoint")
set(EP_bv16_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
lcb_git_repository("git://git.linphone.org/bv16-floatingpoint.git")
lcb_git_tag_latest("linphone")
lcb_git_tag("6899f2759c7b19d5402335d3a937c53020abfeca")
lcb_external_source_paths("externals/bv16-floatingpoint")
......@@ -20,24 +20,24 @@
#
############################################################################
set(EP_bzrtp_GIT_REPOSITORY "git://git.linphone.org/bzrtp.git" CACHE STRING "bzrtp repository URL")
set(EP_bzrtp_GIT_TAG_LATEST "master" CACHE STRING "bzrtp tag to use when compiling latest version")
set(EP_bzrtp_GIT_TAG "1.0.4" CACHE STRING "bzrtp tag to use")
set(EP_bzrtp_EXTERNAL_SOURCE_PATHS "bzrtp")
set(EP_bzrtp_GROUPABLE YES)
lcb_git_repository("git://git.linphone.org/bzrtp.git")
lcb_git_tag_latest("master")
lcb_git_tag("1.0.4")
lcb_external_source_paths("bzrtp")
lcb_groupable(YES)
set(EP_bzrtp_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
set(EP_bzrtp_DEPENDENCIES EP_bctoolbox)
if(LINPHONE_BUILDER_BUILD_DEPENDENCIES AND NOT APPLE)
# Do not build xml2 on Apple systems (Mac OS X and iOS), it is provided by the system
list(APPEND EP_bzrtp_DEPENDENCIES EP_xml2)
lcb_dependencies("bctoolbox")
if(LINPHONE_BUILDER_BUILD_DEPENDENCIES)
if(NOT APPLE)
# Do not build xml2 on Apple systems (Mac OS X and iOS), it is provided by the system
lcb_dependencies("xml2")
endif()
if(ENABLE_UNIT_TESTS)
lcb_dependencies("bcunit")
endif()
endif()
if(MINGW)
set(EP_bzrtp_EXTRA_CPPFLAGS "-D__USE_MINGW_ANSI_STDIO")
endif()
set(EP_bzrtp_CMAKE_OPTIONS "-DENABLE_TESTS=${ENABLE_UNIT_TESTS}")
if(ENABLE_UNIT_TESTS AND LINPHONE_BUILDER_BUILD_DEPENDENCIES)
list(APPEND EP_bzrtp_DEPENDENCIES EP_bcunit)
lcb_extra_cppflags("-D__USE_MINGW_ANSI_STDIO")
endif()
lcb_cmake_options("-DENABLE_TESTS=${ENABLE_UNIT_TESTS}")
......@@ -19,9 +19,10 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
############################################################################
set(EP_codec2_GIT_REPOSITORY "git://git.linphone.org/codec2.git" CACHE STRING " codec2 mirror repository URL")
set(EP_codec2_GIT_TAG_LATEST "linphone" CACHE STRING "codec2 tag to use when compiling latest version")
set(EP_codec2_CMAKE_OPTIONS "-DBUILD_SHARED_LIBS=NO")
set(EP_codec2_EXTRA_CFLAGS "-include ${CMAKE_CURRENT_LIST_DIR}/codec2/codec2_prefixed_symbols.h")
set(EP_codec2_EXTERNAL_SOURCE_PATHS "externals/codec2")
lcb_git_repository("git://git.linphone.org/codec2.git")
lcb_git_tag_latest("linphone")
lcb_external_source_paths("externals/codec2")
lcb_cmake_options("-DBUILD_SHARED_LIBS=NO")
lcb_extra_cflags("-include ${CMAKE_CURRENT_LIST_DIR}/codec2/codec2_prefixed_symbols.h")
......@@ -21,33 +21,33 @@
############################################################################
if(LINPHONE_BUILDER_PREBUILT_URL)
set(EP_ffmpeg_FILENAME "ffmpeg-0.10.2-${LINPHONE_BUILDER_ARCHITECTURE}.zip")
file(DOWNLOAD "${LINPHONE_BUILDER_PREBUILT_URL}/${EP_ffmpeg_FILENAME}" "${CMAKE_CURRENT_BINARY_DIR}/${EP_ffmpeg_FILENAME}" STATUS EP_ffmpeg_FILENAME_STATUS)
list(GET EP_ffmpeg_FILENAME_STATUS 0 EP_ffmpeg_DOWNLOAD_STATUS)
if(NOT EP_ffmpeg_DOWNLOAD_STATUS)
set(EP_ffmpeg_PREBUILT 1)
set(FFMPEG_FILENAME "ffmpeg-0.10.2-${LINPHONE_BUILDER_ARCHITECTURE}.zip")
file(DOWNLOAD "${LINPHONE_BUILDER_PREBUILT_URL}/${FFMPEG_FILENAME}" "${CMAKE_CURRENT_BINARY_DIR}/${FFMPEG_FILENAME}" STATUS FFMPEG_FILENAME_STATUS)
list(GET FFMPEG_FILENAME_STATUS 0 FFMPEG_DOWNLOAD_STATUS)
if(NOT FFMPEG_DOWNLOAD_STATUS)
set(FFMPEG_PREBUILT 1)
endif()
endif()
if(EP_ffmpeg_PREBUILT)
set(EP_ffmpeg_URL "${CMAKE_CURRENT_BINARY_DIR}/${EP_ffmpeg_FILENAME}")
set(EP_ffmpeg_BUILD_METHOD "prebuilt")
if(FFMPEG_PREBUILT)
lcb_url("${CMAKE_CURRENT_BINARY_DIR}/${FFMPEG_FILENAME}")
lcb_build_method("prebuilt")
elseif(CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
# Use prebuilt library in the source tree for Windows 10
set(EP_ffmpeg_EXTERNAL_SOURCE_PATHS "build/ffmpeg")
lcb_external_source_paths("build/ffmpeg")
else()
if(WIN32)
set(EP_ffmpeg_PATCH_OPTIONS "--binary")
endif()
set(EP_ffmpeg_GIT_REPOSITORY "git://git.linphone.org/ffmpeg.git" CACHE STRING "ffmpeg repository URL")
set(EP_ffmpeg_GIT_TAG_LATEST "bc" CACHE STRING "ffmpeg tag to use when compiling latest version")
set(EP_ffmpeg_GIT_TAG "51aa587f7ddac63c831d73eb360e246765a2675f" CACHE STRING "ffmpeg tag to use")
set(EP_ffmpeg_EXTERNAL_SOURCE_PATHS "externals/ffmpeg")
set(EP_ffmpeg_MAY_BE_FOUND_ON_SYSTEM TRUE)
set(EP_ffmpeg_IGNORE_WARNINGS TRUE)
set(EP_ffmpeg_BUILD_METHOD "autotools")
set(EP_ffmpeg_CONFIGURE_OPTIONS
lcb_git_repository("git://git.linphone.org/ffmpeg.git")
lcb_git_tag_latest("bc")
lcb_git_tag("51aa587f7ddac63c831d73eb360e246765a2675f")
lcb_external_source_paths("externals/ffmpeg")
lcb_may_be_found_on_system(YES)
lcb_ignore_warnings(YES)
lcb_build_method("autotools")
lcb_configure_options(
"--disable-doc"
"--disable-zlib"
"--disable-bzlib"
......@@ -73,34 +73,34 @@ else()
"--extra-ldflags=\$LDFLAGS"
)
if(ENABLE_H263 OR IOS)
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS
lcb_configure_options(
"--enable-decoder=h263"
"--enable-encoder=h263"
)
endif()
if(ENABLE_H263P OR IOS)
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS "--enable-encoder=h263p")
lcb_configure_options("--enable-encoder=h263p")
endif()
if(ENABLE_MPEG4 OR IOS)
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS
lcb_configure_options(
"--enable-decoder=mpeg4"
"--enable-encoder=mpeg4"
)
endif()
set(EP_ffmpeg_LINKING_TYPE "--disable-static" "--enable-shared")
set(EP_ffmpeg_ARCH "${CMAKE_SYSTEM_PROCESSOR}")
lcb_linking_type("--disable-static" "--enable-shared")
set(FFMPEG_ARCH "${CMAKE_SYSTEM_PROCESSOR}")
if(WIN32)
set(EP_ffmpeg_TARGET_OS "mingw32")
set(EP_ffmpeg_ARCH "i386")
set(EP_ffmpeg_EXTRA_CFLAGS "-include windows.h")
set(EP_ffmpeg_EXTRA_LDFLAGS "-static-libgcc")
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS "--enable-runtime-cpudetect")
set(FFMPEG_TARGET_OS "mingw32")
set(FFMPEG_ARCH "i386")
lcb_extra_cflags("-include windows.h")
lcb_extra_ldflags("-static-libgcc")
lcb_configure_options("--enable-runtime-cpudetect")
else()
if(APPLE)
set(EP_ffmpeg_TARGET_OS "darwin")
set(FFMPEG_TARGET_OS "darwin")
if(IOS)
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS
lcb_configure_options(
"--enable-decoder=h264"
"--disable-iconv"
"--disable-mmx"
......@@ -108,23 +108,23 @@ else()
"--cross-prefix=${SDK_BIN_PATH}/"
"--sysroot=${CMAKE_OSX_SYSROOT}"
)
set(EP_ffmpeg_MAKE_OPTIONS "RANLIB=\"\$RANLIB\"")
lcb_make_options("RANLIB=\"\$RANLIB\"")
if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
set(EP_ffmpeg_ARCH "arm64")
set(FFMPEG_ARCH "arm64")
else()
set(EP_ffmpeg_ARCH "${CMAKE_SYSTEM_PROCESSOR}")
set(FFMPEG_ARCH "${CMAKE_SYSTEM_PROCESSOR}")
endif()
if(CMAKE_SYSTEM_PROCESSOR STREQUAL "armv7")
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS "--enable-neon" "--cpu=cortex-a8" "--disable-armv5te" "--enable-armv6" "--enable-armv6t2")
lcb_configure_options("--enable-neon" "--cpu=cortex-a8" "--disable-armv5te" "--enable-armv6" "--enable-armv6t2")
endif()
else()
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS
lcb_configure_options(
"--enable-runtime-cpudetect"
"--sysroot=${CMAKE_OSX_SYSROOT}"
)
endif()
elseif(ANDROID)
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS
lcb_configure_options(
"--enable-decoder=h264"
"--disable-iconv"
"--disable-mmx"
......@@ -132,32 +132,32 @@ else()
"--cross-prefix=${TOOLCHAIN_PATH}/"
"--sysroot=${CMAKE_SYSROOT}"
)
set(EP_ffmpeg_TARGET_OS "linux")
set(EP_ffmpeg_ARCH "${CMAKE_SYSTEM_PROCESSOR}")
set(EP_ffmpeg_MAKE_OPTIONS "RANLIB=\"\$RANLIB\"")
set(FFMPEG_TARGET_OS "linux")
set(FFMPEG_ARCH "${CMAKE_SYSTEM_PROCESSOR}")
lcb_make_options("RANLIB=\"\$RANLIB\"")
if(CMAKE_SYSTEM_PROCESSOR STREQUAL "armeabi-v7a")
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS "--enable-neon" "--cpu=cortex-a8" "--disable-armv5te" "--enable-armv6" "--enable-armv6t2")
lcb_configure_options("--enable-neon" "--cpu=cortex-a8" "--disable-armv5te" "--enable-armv6" "--enable-armv6t2")
else()
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS "--disable-mmx" "--disable-sse2" "--disable-ssse3")
lcb_configure_options("--disable-mmx" "--disable-sse2" "--disable-ssse3")
endif()
if(CMAKE_C_COMPILER_TARGET) # When building with clang
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS "--extra-cflags=--target=${CMAKE_C_COMPILER_TARGET} --gcc-toolchain=${EXTERNAL_TOOLCHAIN_PATH}/..")
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS "--extra-ldflags=--target=${CMAKE_C_COMPILER_TARGET} --gcc-toolchain=${EXTERNAL_TOOLCHAIN_PATH}/..")
lcb_configure_options("--extra-cflags=--target=${CMAKE_C_COMPILER_TARGET} --gcc-toolchain=${EXTERNAL_TOOLCHAIN_PATH}/..")
lcb_configure_options("--extra-ldflags=--target=${CMAKE_C_COMPILER_TARGET} --gcc-toolchain=${EXTERNAL_TOOLCHAIN_PATH}/..")
endif()
else()
set(EP_ffmpeg_TARGET_OS "linux")
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS "--enable-runtime-cpudetect")
set(FFMPEG_TARGET_OS "linux")
lcb_configure_options("--enable-runtime-cpudetect")
endif()
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS "--cc=$CC")
lcb_configure_options("--cc=$CC")
endif()
set(EP_ffmpeg_CROSS_COMPILATION_OPTIONS
lcb_cross_compilation_options(
"--prefix=${CMAKE_INSTALL_PREFIX}"
"--arch=${EP_ffmpeg_ARCH}"
"--target-os=${EP_ffmpeg_TARGET_OS}"
"--arch=${FFMPEG_ARCH}"
"--target-os=${FFMPEG_TARGET_OS}"
)
if(ENABLE_X264)
list(APPEND EP_ffmpeg_CONFIGURE_OPTIONS "--enable-decoder=h264")
lcb_configure_options("--enable-decoder=h264")
endif()
endif()
......@@ -20,5 +20,5 @@
#
############################################################################
set(EP_ffmpegandroid_EXTERNAL_SOURCE_PATHS "externals/build/ffmpeg")
set(EP_ffmpegandroid_DEPENDENCIES EP_ffmpeg)
\ No newline at end of file
lcb_external_source_paths("externals/build/ffmpeg")
lcb_dependencies("ffmpeg")
......@@ -20,11 +20,9 @@
#
############################################################################
set(EP_gsm_GIT_REPOSITORY "git://git.linphone.org/gsm.git" CACHE STRING "gsm repository URL")
set(EP_gsm_GIT_TAG_LATEST "linphone" CACHE STRING "gsm tag to use when compiling latest version")
set(EP_gsm_GIT_TAG "0f8822b5326c76bb9dc4c6b552631f51792c3982" CACHE STRING "gsm tag to use")
set(EP_gsm_EXTERNAL_SOURCE_PATHS "gsm" "externals/gsm")
set(EP_gsm_MAY_BE_FOUND_ON_SYSTEM TRUE)
set(EP_gsm_IGNORE_WARNINGS TRUE)
set(EP_gsm_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
lcb_git_repository("git://git.linphone.org/gsm.git")
lcb_git_tag_latest("linphone")
lcb_git_tag("0f8822b5326c76bb9dc4c6b552631f51792c3982")
lcb_external_source_paths("gsm" "externals/gsm")
lcb_may_be_found_on_system(YES)
lcb_ignore_warnings(YES)
......@@ -20,23 +20,28 @@
#
############################################################################
set(EP_linphone_GIT_REPOSITORY "git://git.linphone.org/linphone.git" CACHE STRING "linphone repository URL")
set(EP_linphone_GIT_TAG_LATEST "master" CACHE STRING "linphone tag to use when compiling latest version")
set(EP_linphone_GIT_TAG "3.10.0" CACHE STRING "linphone tag to use")
set(EP_linphone_EXTERNAL_SOURCE_PATHS "linphone")
set(EP_linphone_GROUPABLE YES)
lcb_git_repository("git://git.linphone.org/linphone.git")
lcb_git_tag_latest("master")
lcb_git_tag("3.10.0")
lcb_external_source_paths("linphone")
lcb_groupable(YES)
set(EP_linphone_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
set(EP_linphone_DEPENDENCIES EP_bctoolbox EP_bellesip EP_ortp EP_ms2)
lcb_dependencies("bctoolbox" "bellesip" "ortp" "ms2")
if(LINPHONE_BUILDER_BUILD_DEPENDENCIES AND NOT APPLE)
# Do not build sqlite3, xml2 and zlib on Apple systems (Mac OS X and iOS), they are provided by the system
list(APPEND EP_linphone_DEPENDENCIES EP_sqlite3 EP_xml2)
lcb_dependencies("sqlite3" "xml2")
if (NOT QNX)
list(APPEND EP_linphone_DEPENDENCIES EP_zlib)
lcb_dependencies("zlib")
endif()
endif()
if(ENABLE_TUNNEL)
lcb_dependencies("tunnel")
endif()
if(ENABLE_VCARD)
lcb_dependencies("belcard")
endif()
set(EP_linphone_CMAKE_OPTIONS
lcb_cmake_options(
"-DENABLE_GTK_UI=${ENABLE_GTK_UI}"
"-DENABLE_VIDEO=${ENABLE_VIDEO}"
"-DENABLE_DEBUG_LOGS=${ENABLE_DEBUG_LOGS}"
......@@ -44,21 +49,14 @@ set(EP_linphone_CMAKE_OPTIONS
"-DENABLE_TOOLS=${ENABLE_TOOLS}"
"-DENABLE_NLS=${ENABLE_NLS}"
"-DENABLE_LIME=YES"
"-DENABLE_UNIT_TESTS=${ENABLE_UNIT_TESTS}"
"-DENABLE_POLARSSL=${ENABLE_POLARSSL}"
"-DENABLE_MBEDTLS=${ENABLE_MBEDTLS}"
"-DENABLE_TUNNEL=${ENABLE_TUNNEL}"
"-DENABLE_VCARD=${ENABLE_VCARD}"
)
# TODO: Activate strict compilation options on IOS
if(IOS)
list(APPEND EP_linphone_CMAKE_OPTIONS "-DENABLE_STRICT=NO")
endif()
list(APPEND EP_linphone_CMAKE_OPTIONS "-DENABLE_TUNNEL=${ENABLE_TUNNEL}")
if(ENABLE_TUNNEL)
list(APPEND EP_linphone_DEPENDENCIES EP_tunnel)
endif()
list(APPEND EP_linphone_CMAKE_OPTIONS "-DENABLE_VCARD=${ENABLE_VCARD}")
if(ENABLE_VCARD)
list(APPEND EP_linphone_DEPENDENCIES EP_belcard)
lcb_cmake_options("-DENABLE_STRICT=NO")
endif()
list(APPEND EP_linphone_CMAKE_OPTIONS "-DENABLE_UNIT_TESTS=${ENABLE_UNIT_TESTS}")
list(APPEND EP_linphone_CMAKE_OPTIONS "-DENABLE_POLARSSL=${ENABLE_POLARSSL}")
list(APPEND EP_linphone_CMAKE_OPTIONS "-DENABLE_MBEDTLS=${ENABLE_MBEDTLS}")
......@@ -20,9 +20,9 @@
#
############################################################################
set(EP_matroska2_GIT_REPOSITORY "git://git.linphone.org/libmatroska-c.git" CACHE STRING "matroska2 repository URL")
set(EP_matroska2_GIT_TAG_LATEST "bc" CACHE STRING "matroska2 tag to use when compiling latest version")
set(EP_matroska2_GIT_TAG "c3fc2746f18bafefe3010669d8d2855240565c86" CACHE STRING "matroska2 tag to use")
set(EP_matroska2_EXTERNAL_SOURCE_PATHS "externals/libmatroska-c")
lcb_git_repository("git://git.linphone.org/libmatroska-c.git")
lcb_git_tag_latest("bc")
lcb_git_tag("c3fc2746f18bafefe3010669d8d2855240565c86")
lcb_external_source_paths("externals/libmatroska-c")
set(EP_matroska2_LINKING_TYPE "-DENABLE_STATIC=YES" "-DENABLE_SHARED=NO")
lcb_linking_type("-DENABLE_STATIC=YES" "-DENABLE_SHARED=NO")
......@@ -20,15 +20,15 @@
#
############################################################################
set(EP_mbedtls_GIT_REPOSITORY "git://git.linphone.org/mbedtls.git" CACHE STRING "mbedtls repository URL")
set(EP_mbedtls_GIT_TAG_LATEST "linphone" CACHE STRING "mbedtls tag to use when compiling latest version")
set(EP_mbedtls_GIT_TAG "3b88f2749d59e5346de08e121fba1d797c55ddaa" CACHE STRING "mbedtls tag to use")
set(EP_mbedtls_EXTERNAL_SOURCE_PATHS "mbedtls" "externals/mbedtls")
set(EP_mbedtls_MAY_BE_FOUND_ON_SYSTEM TRUE)
set(EP_mbedtls_IGNORE_WARNINGS TRUE)
lcb_git_repository("git://git.linphone.org/mbedtls.git")
lcb_git_tag_latest("linphone")
lcb_git_tag("3b88f2749d59e5346de08e121fba1d797c55ddaa")
lcb_external_source_paths("mbedtls" "externals/mbedtls")
lcb_may_be_found_on_system(YES)
lcb_ignore_warnings(YES)
set(EP_mbedtls_LINKING_TYPE "-DUSE_STATIC_MBEDTLS_LIBRARY=NO" "-DUSE_SHARED_MBEDTLS_LIBRARY=YES")
set(EP_mbedtls_CMAKE_OPTIONS "-DENABLE_PROGRAMS=NO" "-DENABLE_TESTING=NO")
lcb_linking_type("-DUSE_STATIC_MBEDTLS_LIBRARY=NO" "-DUSE_SHARED_MBEDTLS_LIBRARY=YES")
lcb_cmake_options("-DENABLE_PROGRAMS=NO" "-DENABLE_TESTING=NO")
if(MSVC)
set(EP_mbedtls_EXTRA_CFLAGS "-DMBEDTLS_PLATFORM_SNPRINTF_MACRO=_snprintf -DMBEDTLS_EXPORTS")
lcb_extra_cflags("-DMBEDTLS_PLATFORM_SNPRINTF_MACRO=_snprintf -DMBEDTLS_EXPORTS")
endif()
......@@ -20,96 +20,91 @@
#
############################################################################
set(EP_ms2_GIT_REPOSITORY "git://git.linphone.org/mediastreamer2.git" CACHE STRING "ms2 repository URL")
set(EP_ms2_GIT_TAG_LATEST "master" CACHE STRING "ms2 tag to use when compiling latest version")
set(EP_ms2_GIT_TAG "2.14.0" CACHE STRING "ms2 tag to use")
set(EP_ms2_EXTERNAL_SOURCE_PATHS "mediastreamer2" "linphone/mediastreamer2")
set(EP_ms2_GROUPABLE YES)
lcb_git_repository("git://git.linphone.org/mediastreamer2.git")
lcb_git_tag_latest("master")
lcb_git_tag("2.14.0")
lcb_external_source_paths("mediastreamer2" "linphone/mediastreamer2")
lcb_groupable(YES)
lcb_spec_file("mediastreamer2.spec")
lcb_rpmbuild_name("mediastreamer")
if(EP_ms2_FORCE_AUTOTOOLS)
set(EP_ms2_USE_AUTOGEN True)
else()
set(EP_ms2_LINKING_TYPE ${DEFAULT_VALUE_CMAKE_LINKING_TYPE})
endif()
set(EP_ms2_DEPENDENCIES EP_ortp EP_bctoolbox)
lcb_dependencies("ortp" "bctoolbox")
if(ANDROID)
list(APPEND EP_ms2_DEPENDENCIES EP_androidcpufeatures EP_androidsupport)
lcb_dependencies("androidcpufeatures" "androidsupport")
endif()
set(EP_ms2_CMAKE_OPTIONS
lcb_cmake_options(
"-DENABLE_NON_FREE_CODECS=${ENABLE_NON_FREE_CODECS}"
"-DENABLE_UNIT_TESTS=${ENABLE_UNIT_TESTS}"
"-DENABLE_DEBUG_LOGS=${ENABLE_DEBUG_LOGS}"
"-DENABLE_PCAP=${ENABLE_PCAP}"
"-DENABLE_DOC=${ENABLE_DOC}"
"-DENABLE_TOOLS=${ENABLE_TOOLS}"
)
# TODO: Activate strict compilation options on IOS
if(IOS)
list(APPEND EP_ms2_CMAKE_OPTIONS "-DENABLE_STRICT=NO")
endif()
list(APPEND EP_ms2_CMAKE_OPTIONS "-DENABLE_G726=${ENABLE_G726}")
list(APPEND EP_ms2_CMAKE_OPTIONS "-DENABLE_GSM=${ENABLE_GSM}")
lcb_cmake_options(
"-DENABLE_G726=${ENABLE_G726}"
"-DENABLE_GSM=${ENABLE_GSM}"