Commit 484aaaea authored by Ghislain MARY's avatar Ghislain MARY

Add openh264 builder.

parent d22e78e5
......@@ -89,6 +89,9 @@ endif(${ENABLE_ISAC})
if(${ENABLE_SILK})
list(APPEND LINPHONE_BUILDER_BUILDERS mssilk)
endif(${ENABLE_SILK})
if(${ENABLE_OPENH264})
list(APPEND LINPHONE_BUILDER_BUILDERS openh264)
endif(${ENABLE_OPENH264})
if(${ENABLE_X264})
list(APPEND LINPHONE_BUILDER_BUILDERS x264 msx264)
endif(${ENABLE_X264})
......
......@@ -68,6 +68,9 @@ else(WIN32)
else(${ENABLE_VIDEO})
list(APPEND EP_linphone_CONFIGURE_OPTIONS "--disable-video")
endif(${ENABLE_VIDEO})
if(${ENABLE_OPENH264})
list(APPEND EP_linphone_DEPENDENCIES EP_openh264)
endif(${ENABLE_OPENH264})
if(${ENABLE_X264})
list(APPEND EP_linphone_DEPENDENCIES EP_msx264)
endif(${ENABLE_X264})
......
############################################################################
# openh264.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_program(NASM_PROGRAM
NAMES nasm nasm.exe
)
if(NOT NASM_PROGRAM)
if(WIN32)
message(FATAL_ERROR "Could not find the nasm.exe program. Please install it from http://www.nasm.us/")
else()
message(FATAL_ERROR "Could not find the nasm program.")
endif()
endif()
set(EP_openh264_GIT_REPOSITORY "https://github.com/cisco/openh264")
set(EP_openh264_GIT_TAG "fb5700bd5cc18dd33c120ce9dd5f79b8f1f35f3a")
set(EP_openh264_BUILD_METHOD "custom")
set(EP_openh264_BUILD_IN_SOURCE "yes")
set(EP_openh264_LINKING_TYPE "-shared")
set(EP_openh264_CONFIGURE_COMMAND ${CMAKE_CURRENT_BINARY_DIR}/EP_openh264_configure.sh)
set(EP_openh264_BUILD_COMMAND ${CMAKE_CURRENT_BINARY_DIR}/EP_openh264_build.sh)
set(EP_openh264_INSTALL_COMMAND ${CMAKE_CURRENT_BINARY_DIR}/EP_openh264_install.sh)
linphone_builder_set_ep_directories(openh264)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builders/openh264/configure.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/EP_openh264_configure.sh)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builders/openh264/build.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/EP_openh264_build.sh)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/builders/openh264/install.sh.cmake ${CMAKE_CURRENT_BINARY_DIR}/EP_openh264_install.sh)
#!/bin/sh
export CC=@LINPHONE_BUILDER_TOOLCHAIN_CC@
export CXX=@LINPHONE_BUILDER_TOOLCHAIN_CXX@
export OBJC=@LINPHONE_BUILDER_TOOLCHAIN_OBJC@
export LD=@LINPHONE_BUILDER_TOOLCHAIN_LD@
export AR=@LINPHONE_BUILDER_TOOLCHAIN_AR@
export RANLIB=@LINPHONE_BUILDER_TOOLCHAIN_RANLIB@
export STRIP=@LINPHONE_BUILDER_TOOLCHAIN_STRIP@
export NM=@LINPHONE_BUILDER_TOOLCHAIN_NM@
export ASFLAGS="@LINPHONE_BUILDER_TOOLCHAIN_ASFLAGS@"
export CPPFLAGS="@LINPHONE_BUILDER_TOOLCHAIN_CPPFLAGS@"
export CFLAGS="@LINPHONE_BUILDER_TOOLCHAIN_CFLAGS@"
export CXXFLAGS="@LINPHONE_BUILD_TOOLCHAIN_CXXFLAGS@"
export OBJCFLAGS="@LINPHONE_BUILD_TOOLCHAIN_OBJCFLAGS@"
export LDFLAGS="@LINPHONE_BUILDER_TOOLCHAIN_LDFLAGS@"
export PKG_CONFIG="@LINPHONE_BUILDER_PKG_CONFIG@"
export PKG_CONFIG_PATH="@LINPHONE_BUILDER_PKG_CONFIG_PATH@"
export PKG_CONFIG_LIBDIR="@LINPHONE_BUILDER_PKG_CONFIG_LIBDIR@"
cd @ep_build@
make PREFIX="@CMAKE_INSTALL_PREFIX@" SHARED="@EP_openh264_LINKING_TYPE@"
#!/bin/sh
export CC=@LINPHONE_BUILDER_TOOLCHAIN_CC@
export CXX=@LINPHONE_BUILDER_TOOLCHAIN_CXX@
export OBJC=@LINPHONE_BUILDER_TOOLCHAIN_OBJC@
export LD=@LINPHONE_BUILDER_TOOLCHAIN_LD@
export AR=@LINPHONE_BUILDER_TOOLCHAIN_AR@
export RANLIB=@LINPHONE_BUILDER_TOOLCHAIN_RANLIB@
export STRIP=@LINPHONE_BUILDER_TOOLCHAIN_STRIP@
export NM=@LINPHONE_BUILDER_TOOLCHAIN_NM@
export ASFLAGS="@LINPHONE_BUILDER_TOOLCHAIN_ASFLAGS@"
export CPPFLAGS="@LINPHONE_BUILDER_TOOLCHAIN_CPPFLAGS@"
export CFLAGS="@LINPHONE_BUILDER_TOOLCHAIN_CFLAGS@"
export CXXFLAGS="@LINPHONE_BUILD_TOOLCHAIN_CXXFLAGS@"
export OBJCFLAGS="@LINPHONE_BUILD_TOOLCHAIN_OBJCFLAGS@"
export LDFLAGS="@LINPHONE_BUILDER_TOOLCHAIN_LDFLAGS@"
export PKG_CONFIG="@LINPHONE_BUILDER_PKG_CONFIG@"
export PKG_CONFIG_PATH="@LINPHONE_BUILDER_PKG_CONFIG_PATH@"
export PKG_CONFIG_LIBDIR="@LINPHONE_BUILDER_PKG_CONFIG_LIBDIR@"
cd @ep_build@
make install PREFIX="@CMAKE_INSTALL_PREFIX@" SHARED="@EP_openh264_LINKING_TYPE@"
......@@ -70,8 +70,10 @@ cmake_dependent_option(ENABLE_MPEG4 "Enable MPEG4 video codec support." ${DEFAUL
linphone_builder_add_feature_info("MPEG4" ENABLE_MPEG4 "MPEG4 video encoding/decoding support.")
cmake_dependent_option(ENABLE_VPX "Enable VPX video codec support." ${DEFAULT_VALUE_ENABLE_VPX} "ENABLE_VIDEO" OFF)
linphone_builder_add_feature_info("VPX" ENABLE_VPX "VPX video encoding/decoding support.")
cmake_dependent_option(ENABLE_X264 "Enable H.264 video encoder support with the x264 library." ${DEFAULT_VALUE_ENABLE_X264} "ENABLE_FFMPEG" OFF)
cmake_dependent_option(ENABLE_X264 "Enable H.264 video encoder support with the x264 library." ${DEFAULT_VALUE_ENABLE_X264} "ENABLE_FFMPEG; NOT ENABLE_OPENH264" OFF)
linphone_builder_add_feature_info("x264" ENABLE_X264 "H.264 video encoding support with the x264 library.")
cmake_dependent_option(ENABLE_OPENH264 "Enable H.264 video encoder support with the openh264 library." ${DEFAULT_VALUE_ENABLE_OPENH264} "ENABLE_VIDEO; NOT ENABLE_X264" OFF)
linphone_builder_add_feature_info("openh264" ENABLE_OPENH264 "H.264 video encoding support with the openh264 library.")
option(ENABLE_TUNNEL "Enable tunnel support." ${DEFAULT_VALUE_ENABLE_TUNNEL})
linphone_builder_add_feature_info("Tunnel" ENABLE_TUNNEL "Secure tunnel for SIP/RTP .")
......
......@@ -38,6 +38,7 @@ set(DEFAULT_VALUE_ENABLE_SPEEX ON)
set(DEFAULT_VALUE_ENABLE_H263 OFF)
set(DEFAULT_VALUE_ENABLE_H263P OFF)
set(DEFAULT_VALUE_ENABLE_MPEG4 OFF)
set(DEFAULT_VALUE_ENABLE_OPENH264 OFF)
set(DEFAULT_VALUE_ENABLE_VPX OFF)
set(DEFAULT_VALUE_ENABLE_X264 OFF)
set(DEFAULT_VALUE_ENABLE_TUNNEL OFF)
......
......@@ -38,6 +38,7 @@ set(DEFAULT_VALUE_ENABLE_SPEEX ON)
set(DEFAULT_VALUE_ENABLE_H263 ON)
set(DEFAULT_VALUE_ENABLE_H263P ON)
set(DEFAULT_VALUE_ENABLE_MPEG4 ON)
set(DEFAULT_VALUE_ENABLE_OPENH264 OFF)
set(DEFAULT_VALUE_ENABLE_VPX ON)
set(DEFAULT_VALUE_ENABLE_X264 ON)
set(DEFAULT_VALUE_ENABLE_TUNNEL OFF)
......
......@@ -38,6 +38,7 @@ set(DEFAULT_VALUE_ENABLE_SPEEX ON)
set(DEFAULT_VALUE_ENABLE_H263 OFF)
set(DEFAULT_VALUE_ENABLE_H263P OFF)
set(DEFAULT_VALUE_ENABLE_MPEG4 OFF)
set(DEFAULT_VALUE_ENABLE_OPENH264 OFF)
set(DEFAULT_VALUE_ENABLE_VPX OFF)
set(DEFAULT_VALUE_ENABLE_X264 OFF)
set(DEFAULT_VALUE_ENABLE_TUNNEL OFF)
......
......@@ -38,6 +38,7 @@ set(DEFAULT_VALUE_ENABLE_SPEEX ON)
set(DEFAULT_VALUE_ENABLE_H263 OFF)
set(DEFAULT_VALUE_ENABLE_H263P OFF)
set(DEFAULT_VALUE_ENABLE_MPEG4 OFF)
set(DEFAULT_VALUE_ENABLE_OPENH264 OFF)
set(DEFAULT_VALUE_ENABLE_VPX ON)
set(DEFAULT_VALUE_ENABLE_X264 OFF)
set(DEFAULT_VALUE_ENABLE_TUNNEL OFF)
......
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