Build OpenH264 in the SDK.

This commit is contained in:
Ghislain MARY 2014-04-04 15:39:09 +02:00
parent 14ea54c904
commit 8d23daf39c
6 changed files with 107 additions and 2 deletions

6
.gitmodules vendored
View file

@ -64,3 +64,9 @@
[submodule "submodules/cunit"]
path = submodules/cunit
url = git://git.linphone.org/cunit.git
[submodule "submodules/externals/openh264"]
path = submodules/externals/openh264
url = https://github.com/cisco/openh264
[submodule "submodules/msopenh264"]
path = submodules/msopenh264
url = git://git.linphone.org/msopenh264.git

View file

@ -55,7 +55,7 @@ endif
LINPHONE_SRC_DIR=$(BUILDER_SRC_DIR)/linphone
LINPHONE_BUILD_DIR=$(BUILDER_BUILD_DIR)/linphone
all: build-linphone build-msilbc build-msamr build-msx264 build-mssilk build-msbcg729 build-msisac
all: build-linphone build-msilbc build-msamr build-msx264 build-mssilk build-msbcg729 build-msisac build-msopenh264
# setup the switches that might trigger a linphone reconfiguration
@ -133,7 +133,7 @@ veryclean: veryclean-linphone veryclean-msbcg729
rm -rf $(BUILDER_BUILD_DIR)
# list of the submodules to build
MS_MODULES := msilbc libilbc msamr mssilk msx264 msisac
MS_MODULES := msilbc libilbc msamr mssilk msx264 msisac msopenh264
SUBMODULES_LIST := polarssl libantlr cunit belle-sip srtp speex libgsm libvpx libxml2 bzrtp ffmpeg opus
.NOTPARALLEL build-linphone: init $(addprefix build-,$(SUBMODULES_LIST)) mode_switch_check $(LINPHONE_BUILD_DIR)/Makefile

View file

@ -0,0 +1,44 @@
############################################################################
# msopenh264.mk
# Copyright (C) 2011 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.
#
############################################################################
msopenh264_dir?=msopenh264
$(BUILDER_SRC_DIR)/$(msopenh264_dir)/configure:
cd $(BUILDER_SRC_DIR)/$(msopenh264_dir) && ./autogen.sh
$(BUILDER_BUILD_DIR)/$(msopenh264_dir)/Makefile: $(BUILDER_SRC_DIR)/$(msopenh264_dir)/configure
mkdir -p $(BUILDER_BUILD_DIR)/$(msopenh264_dir)
cd $(BUILDER_BUILD_DIR)/$(msopenh264_dir)/ \
&& PKG_CONFIG_LIBDIR=$(prefix)/lib/pkgconfig CONFIG_SITE=$(BUILDER_SRC_DIR)/build/$(config_site) \
$(BUILDER_SRC_DIR)/$(msopenh264_dir)/configure -prefix=$(prefix) --host=$(host) ${library_mode}
build-msopenh264: build-openh264 $(BUILDER_BUILD_DIR)/$(msopenh264_dir)/Makefile
cd $(BUILDER_BUILD_DIR)/$(msopenh264_dir) && PKG_CONFIG_LIBDIR=$(prefix)/lib/pkgconfig CONFIG_SITE=$(BUILDER_SRC_DIR)/build/$(config_site) make && make install
clean-msopenh264: clean-openh264
cd $(BUILDER_BUILD_DIR)/$(msopenh264_dir) && make clean
veryclean-msopenh264: veryclean-openh264
-cd $(BUILDER_BUILD_DIR)/$(msopenh264_dir) && make distclean
-cd $(BUILDER_SRC_DIR)/$(msopenh264_dir) && rm -f configure
clean-makefile-msopenh264: clean-makefile-openh264
cd $(BUILDER_BUILD_DIR)/$(msopenh264_dir) && rm -f Makefile

View file

@ -0,0 +1,53 @@
############################################################################
# openh264.mk
# Copyright (C) 2011 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.
#
############################################################################
ifneq (,$(findstring i386-,$(host)))
ARCH=i386
endif
ifneq (,$(findstring armv7-,$(host)))
ARCH=armv7
endif
ifneq (,$(findstring armv7s-,$(host)))
ARCH=armv7s
endif
openh264_dir?=externals/openh264
$(BUILDER_BUILD_DIR)/$(openh264_dir)/Makefile:
mkdir -p $(BUILDER_BUILD_DIR)/$(openh264_dir) \
&& cd $(BUILDER_BUILD_DIR)/$(openh264_dir)/ \
&& rsync -rvLpgoc --exclude ".git" $(BUILDER_SRC_DIR)/$(openh264_dir)/* .
build-openh264: $(BUILDER_BUILD_DIR)/$(openh264_dir)/Makefile
cd $(BUILDER_BUILD_DIR)/$(openh264_dir) \
&& make libraries OS=ios ARCH=$(ARCH) PREFIX=$(prefix)\
&& make install OS=ios ARCH=$(ARCH) PREFIX=$(prefix)
clean-openh264:
cd $(BUILDER_BUILD_DIR)/$(openh264_dir) \
&& make clean OS=ios ARCH=$(ARCH)
veryclean-openh264:
cd $(BUILDER_SRC_DIR)/$(openh264_dir)/ \
&& git clean -f && git reset --hard \
rm -rf $(BUILDER_BUILD_DIR)/$(openh264_dir)

1
submodules/externals/openh264 vendored Submodule

@ -0,0 +1 @@
Subproject commit fb5700bd5cc18dd33c120ce9dd5f79b8f1f35f3a

1
submodules/msopenh264 Submodule

@ -0,0 +1 @@
Subproject commit 863889de427c70806d6bda87e2f95c3f38662c23