Commit f9504a4c authored by Erwan Croze's avatar Erwan Croze 👋🏻

Merge branch 'master' of git.linphone.org:linphone-cmake-builder into dev_lime_v2

parents cd63a051 01c40162
......@@ -30,10 +30,14 @@ if(CMAKE_ANDROID_NDK_VERSION VERSION_LESS 16)
set(SUPPORT_SOURCES
"${CMAKE_ANDROID_NDK}/sources/android/support/src/musl-multibyte/wctomb.c"
)
else()
elseif(CMAKE_ANDROID_NDK_VERSION VERSION_LESS 17)
set(SUPPORT_SOURCES
"${CMAKE_ANDROID_NDK}/sources/android/support/src/iswblank.cpp"
)
else()
set(SUPPORT_SOURCES
"${CMAKE_ANDROID_NDK}/sources/android/support/src/locale_support.cpp"
)
endif()
add_library(support STATIC ${SUPPORT_SOURCES})
......
......@@ -27,3 +27,5 @@ lcb_external_source_paths("bcg729")
lcb_groupable(YES)
lcb_sanitizable(YES)
lcb_package_source(YES)
lcb_spec_file("bcg729.spec")
......@@ -148,6 +148,12 @@ else()
else()
set(FFMPEG_TARGET_OS "linux")
lcb_configure_options("--enable-runtime-cpudetect")
if(CMAKE_SYSTEM_PROCESSOR MATCHES "armv7")
lcb_configure_options("--cpu=cortex-a8"
"--enable-fft")
lcb_extra_cflags("-mfpu=neon")
lcb_extra_cxxflags("-mfpu=neon")
endif()
endif()
lcb_configure_options("--cc=$CC")
endif()
......
......@@ -46,18 +46,20 @@ endif()
if(ENABLE_REDIS)
lcb_dependencies("hiredis")
endif()
if(ENABLE_JWE_AUTH_PLUGIN)
lcb_dependencies("jose")
endif()
lcb_cmake_options(
"-DENABLE_TRANSCODER=${ENABLE_TRANSCODER}"
"-DENABLE_ODBC=NO"
"-DENABLE_REDIS=${ENABLE_REDIS}"
"-DENABLE_SOCI=${ENABLE_SOCI}"
"-DENABLE_PUSHNOTIFICATION=${ENABLE_PUSHNOTIFICATION}"
"-DENABLE_PRESENCE=${ENABLE_PRESENCE}"
"-DENABLE_CONFERENCE=${ENABLE_CONFERENCE}"
"-DENABLE_SNMP=${ENABLE_SNMP}"
"-DENABLE_DOC=${ENABLE_DOC}"
"-DENABLE_PROTOBUF=${ENABLE_PROTOBUF}"
"-DENABLE_MDNS=${ENABLE_MDNS}"
"-DENABLE_JWE_AUTH_PLUGIN=${ENABLE_JWE_AUTH_PLUGIN}"
)
############################################################################
# jansson.cmake
# Copyright (C) 2018 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., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
############################################################################
lcb_git_repository("git@gitlab.linphone.org:BC/public/external/jansson.git")
lcb_external_source_paths("externals/jansson")
lcb_may_be_found_on_system(YES)
############################################################################
# jose.cmake
# Copyright (C) 2018 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., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
############################################################################
lcb_git_repository("git@gitlab.linphone.org:BC/public/external/jose.git")
lcb_external_source_paths("externals/jose")
lcb_spec_file("jose.spec")
lcb_dependencies("jansson")
lcb_dependencies("zlib")
......@@ -66,4 +66,5 @@ lcb_cmake_options(
"-DENABLE_CXX_WRAPPER=${ENABLE_CXX_WRAPPER}"
"-DENABLE_CSHARP_WRAPPER=${ENABLE_CSHARP_WRAPPER}"
"-DENABLE_JAVA_WRAPPER=${ENABLE_JAVA_WRAPPER}"
"-DENABLE_QRCODE=${ENABLE_QRCODE}"
)
......@@ -53,6 +53,7 @@ lcb_cmake_options(
"-DENABLE_G729=${ENABLE_G729}"
"-DENABLE_G729B_CNG=${ENABLE_G729B_CNG}"
"-DENABLE_JPEG=${ENABLE_JPEG}"
"-DENABLE_QRCODE=${ENABLE_QRCODE}"
)
if(ENABLE_GSM)
lcb_dependencies("gsm")
......@@ -72,6 +73,9 @@ endif()
if(ENABLE_JPEG)
lcb_dependencies("turbo-jpeg")
endif()
if(ENABLE_QRCODE)
lcb_dependencies("zxing")
endif()
lcb_cmake_options("-DENABLE_VIDEO=${ENABLE_VIDEO}")
if(ENABLE_VIDEO)
......
......@@ -145,8 +145,9 @@ else()
)
list(REMOVE_ITEM EP_vpx_CONFIGURE_OPTIONS "--enable-multithread")
else()
lcb_use_c_compiler_for_assembler(NO)
if(CMAKE_SYSTEM_PROCESSOR STREQUAL "armv7l")
set(USE_TARGET NO)
set(VPX_TARGET "armv7-linux-gcc")
else()
if(CMAKE_SIZEOF_VOID_P EQUAL 8)
set(VPX_TARGET "x86_64-linux-gcc")
......
############################################################################
# zxing.cmake
# Copyright (C) 2018 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., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
############################################################################
lcb_git_repository("git://git.linphone.org/zxing-cpp.git")
lcb_git_tag_latest("bc")
lcb_git_tag("bc")
lcb_external_source_paths("externals/zxing-cpp")
#lcb_linking_type("-DENABLE_STATIC=YES" "-DENABLE_SHARED=NO")
#lcb_extra_cflags("-fPIC")
......@@ -22,6 +22,10 @@
if("@CMAKE_C_COMPILER_ID@" STREQUAL "GNU")
string(REGEX REPLACE "gcc$" "as" AS_COMPILER "@CMAKE_C_COMPILER@")
if (AS_COMPILER STREQUAL "@CMAKE_C_COMPILER@")
#fallback for the case where gcc is found as /usr/bin/cc
string(REGEX REPLACE "cc$" "as" AS_COMPILER "@CMAKE_C_COMPILER@")
endif()
set(AUTOTOOLS_AS_COMPILER ${AS_COMPILER} CACHE PATH "Initial cache" FORCE)
endif()
set(C_LAUNCHER "")
......
......@@ -24,9 +24,6 @@
lcb_add_option("Theora" "Theora video encoding/decoding support." "${DEFAULT_VALUE_ENABLE_THEORA}")
lcb_add_option("Static only" "Enable compilation of libraries in static mode." "${DEFAULT_VALUE_ENABLE_STATIC_ONLY}")
lcb_add_option("Packaging" "Enable packaging" "${DEFAULT_VALUE_ENABLE_PACKAGING}")
if(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
lcb_add_option("Sanitizer" "Enable Clang sanitizer" "${DEFAULT_VALUE_ENABLE_SANITIZER}")
endif()
lcb_add_option("Source packaging" "Enable source packaging" "${DEFAULT_VALUE_ENABLE_SOURCE_PACKAGING}")
......
......@@ -36,7 +36,7 @@ set(DEFAULT_VALUE_CMAKE_LINKING_TYPE "-DENABLE_SHARED=YES" "-DENABLE_STATIC=NO")
# Global configuration
set(LINPHONE_BUILDER_HOST "")
set(RPM_INSTALL_PREFIX "/opt/belledonne-communications/linphone")
set(RPM_INSTALL_PREFIX "/opt/com.belledonne-communications/linphone")
set(LINPHONE_BUILDER_RPMBUILD_PACKAGE_PREFIX "linphone-")
# Adjust PKG_CONFIG_PATH to include install directory
......@@ -68,4 +68,3 @@ if(PLATFORM STREQUAL "Debian")
# some debians are using dash as shell, which doesn't support "export -n", so we override and use bash
set(LINPHONE_BUILDER_RPMBUILD_GLOBAL_OPTIONS "${LINPHONE_BUILDER_RPMBUILD_GLOBAL_OPTIONS} --define '_buildshell /bin/bash'")
endif()
......@@ -56,6 +56,10 @@ endif()
include(configs/config-desktop-common.cmake)
lcb_builder_cmake_options(belr "-DENABLE_TOOLS=YES")
lcb_builder_cmake_options(linphone "-DENABLE_TOOLS=YES")
# Install GTK and intltool for build with Visual Studio
if(MSVC AND ENABLE_GTK_UI)
if(NOT EXISTS "${CMAKE_CURRENT_BINARY_DIR}/intltool_win32.zip")
......
......@@ -51,7 +51,6 @@ set(LINPHONE_BUILDER_USE_SYSTEM_DEPENDENCIES YES CACHE BOOL "" FORCE)
# Define default values for the flexisip builder options
set(DEFAULT_VALUE_ENABLE_CXX_WRAPPER ON)
set(DEFAULT_VALUE_ENABLE_PUSHNOTIFICATION ON)
set(DEFAULT_VALUE_ENABLE_REDIS ON)
set(DEFAULT_VALUE_ENABLE_SOCI ON)
set(DEFAULT_VALUE_ENABLE_UNIT_TESTS OFF)
......
......@@ -21,7 +21,6 @@
############################################################################
# Define default values for the flexisip builder options
set(DEFAULT_VALUE_ENABLE_PUSHNOTIFICATION ON)
set(DEFAULT_VALUE_ENABLE_REDIS ON)
set(DEFAULT_VALUE_ENABLE_UNIT_TESTS OFF)
set(DEFAULT_VALUE_ENABLE_PRESENCE OFF)
......@@ -29,6 +28,7 @@ set(DEFAULT_VALUE_ENABLE_CONFERENCE OFF)
set(DEFAULT_VALUE_ENABLE_SNMP ON)
set(DEFAULT_VALUE_ENABLE_POLARSSL ON)
set(DEFAULT_VALUE_ENABLE_PROTOBUF OFF)
set(DEFAULT_VALUE_ENABLE_JWE_AUTH_PLUGIN OFF)
set(DEFAULT_VALUE_ENABLE_VCARD OFF)
set(DEFAULT_VALUE_ENABLE_VIDEO OFF)
......@@ -91,4 +91,3 @@ if(ENABLE_CONFERENCE)
"-DENABLE_UNIT_TESTS=${ENABLE_UNIT_TESTS}"
)
endif()
......@@ -43,6 +43,7 @@ set(DEFAULT_VALUE_ENABLE_ZRTP ON)
set(DEFAULT_VALUE_ENABLE_LIME ON)
set(DEFAULT_VALUE_ENABLE_TOOLS OFF)
set(DEFAULT_VALUE_ENABLE_STATIC_ONLY OFF)
set(DEFAULT_VALUE_ENABLE_UPDATE_CHECK ON)
set(ENABLE_NLS NO CACHE BOOL "" FORCE)
set(CMAKE_MACOSX_RPATH TRUE)
set(CMAKE_INSTALL_RPATH "@executable_path/../Frameworks")
......@@ -86,6 +87,16 @@ if(NOT ENABLE_STATIC_ONLY)
lcb_builder_linking_type(bctoolbox "-DENABLE_STATIC=NO" "-DENABLE_SHARED=YES")
endif()
#belcard
if(NOT ENABLE_STATIC_ONLY)
lcb_builder_linking_type(belcard "-DENABLE_STATIC=NO" "-DENABLE_SHARED=YES")
endif()
#belcard
if(NOT ENABLE_STATIC_ONLY)
lcb_builder_linking_type(belr "-DENABLE_STATIC=NO" "-DENABLE_SHARED=YES")
endif()
# linphone
lcb_builder_cmake_options(linphone "-DENABLE_RELATIVE_PREFIX=YES")
lcb_builder_cmake_options(linphone "-DENABLE_CONSOLE_UI=NO")
......@@ -148,3 +159,6 @@ lcb_builder_linking_type(vpx "--enable-static" "--disable-shared")
# x264
lcb_builder_linking_type(x264 "--enable-static" "--enable-pic")
lcb_builder_install_target(x264 "install-lib-static")
# zxing
lcb_builder_linking_type(zxing "-DENABLE_STATIC=YES" "-DENABLE_SHARED=NO")
......@@ -24,7 +24,11 @@
lcb_add_option("Unit tests" "Enable unit tests support with BCUnit library." "${DEFAULT_VALUE_ENABLE_UNIT_TESTS}")
lcb_add_option("Debug logs" "Enable debug level logs in libinphone and mediastreamer2." NO)
lcb_add_option("Doc" "Enable documentation generation with Doxygen." YES)
lcb_add_option("Doc" "Enable documentation generation with Doxygen and Sphinx" NO)
lcb_add_option("SOCI" "Enable SOCI support." "${DEFAULT_VALUE_ENABLE_SOCI}")
lcb_add_option("Tools" "Enable tools binary compilation." "${DEFAULT_VALUE_ENABLE_TOOLS}")
lcb_add_option("unmaintained" "Allow inclusion of unmaintained code in the build." OFF)
if(CMAKE_CXX_COMPILER_ID MATCHES "Clang" AND NOT IOS AND NOT ANDROID)
lcb_add_option("Sanitizer" "Enable Clang sanitizer" "${DEFAULT_VALUE_ENABLE_SANITIZER}")
endif()
......@@ -22,10 +22,10 @@
# Flexisip build options
lcb_add_option("REDIS" "Enable hiredis support." "${DEFAULT_VALUE_ENABLE_REDIS}")
lcb_add_option("PushNotification" "Enable push notification support." "${DEFAULT_VALUE_ENABLE_PUSHNOTIFICATION}")
lcb_add_option("Redis" "Enable hiredis support." "${DEFAULT_VALUE_ENABLE_REDIS}")
lcb_add_option("Presence" "Enable presence server support." "${DEFAULT_VALUE_ENABLE_PRESENCE}")
lcb_add_option("Conference" "Enable conference server support." "${DEFAULT_VALUE_ENABLE_CONFERENCE}")
lcb_add_option("SNMP" "Enable SNMP support." "${DEFAULT_ENABLE_SNMP}")
lcb_add_option("Transcoder" "Enable transcoder support." "${DEFAULT_ENABLE_TRANSCODER}")
lcb_add_option("PROTOBUF" "Enable protobuf for REDIS." "${DEFAULT_ENABLE_PROTOBUF}" "ENABLE_PROTOBUF" OFF)
lcb_add_option("Protobuf" "Enable protobuf for REDIS." "${DEFAULT_ENABLE_PROTOBUF}" "ENABLE_PROTOBUF" OFF)
lcb_add_option("Jwe Auth Plugin" "Enable JweAuth plugin support." "${DEFAULT_VALUE_ENABLE_JWE_AUTH_PLUGIN}")
......@@ -46,9 +46,10 @@ lcb_add_option("OPUS" "OPUS audio encoding/decoding support." "${DEFAULT_VALUE_
lcb_add_option("Silk" "Silk audio encoding/decoding support." "${DEFAULT_VALUE_ENABLE_SILK}")
lcb_add_option("Speex" "Speex audio encoding/decoding support." "${DEFAULT_VALUE_ENABLE_SPEEX}")
lcb_add_option("BV16" "BroadVoice 16 audio encoding/decoding support." "${DEFAULT_VALUE_ENABLE_BV16}")
lcb_add_option("jpeg" "JPEG support with libjpeg-turbo." "${DEFAULT_VALUE_ENABLE_JPEG}")
#video options and codecs
lcb_add_option("Video" "Ability to capture and display video." "${DEFAULT_VALUE_ENABLE_VIDEO}")
lcb_add_option("jpeg" "JPEG support with libjpeg-turbo." "${DEFAULT_VALUE_ENABLE_JPEG}")
lcb_add_option("qrcode" "QRCode support with zxing." "${DEFAULT_VALUE_ENABLE_QRCODE}")
# FFMpeg is LGPL which is an issue only for iOS applications; otherwise it can be used in proprietary software as well
if (IOS)
lcb_add_strict_dependent_option("FFmpeg" "Some video processing features via FFmpeg: JPEG encoding/decoding, video scaling, H264 decoding..." "${DEFAULT_VALUE_ENABLE_FFMPEG}" "ENABLE_VIDEO" OFF "ENABLE_GPL_THIRD_PARTIES" "GPL third parties not enabled (ENABLE_GPL_THIRD_PARTIES).")
......
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