diff --git a/.gitmodules b/.gitmodules index 58601cfe1..923aaf877 100644 --- a/.gitmodules +++ b/.gitmodules @@ -34,3 +34,6 @@ [submodule "submodules/msx264"] path = submodules/msx264 url = git://git.linphone.org/msx264.git +[submodule "submodules/externals/libvpx"] + path = submodules/externals/libvpx + url = git://review.webmproject.org/libvpx.git diff --git a/linphone.xcodeproj/project.pbxproj b/linphone.xcodeproj/project.pbxproj index 9fea01100..6add84603 100755 --- a/linphone.xcodeproj/project.pbxproj +++ b/linphone.xcodeproj/project.pbxproj @@ -97,6 +97,7 @@ 22F3D57E13CCC89600A0DA02 /* liblinphone.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 22F3D57D13CCC89600A0DA02 /* liblinphone.a */; }; 22F51EF6107FA66500F98953 /* untitled.plist in Resources */ = {isa = PBXBuildFile; fileRef = 22F51EF5107FA66500F98953 /* untitled.plist */; }; 288765FD0DF74451002DB57D /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 288765FC0DF74451002DB57D /* CoreGraphics.framework */; }; + 7066FC0C13E830E400EFC6DC /* libvpx.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7066FC0B13E830E400EFC6DC /* libvpx.a */; }; 70E542F313E147E3002BA2C0 /* OpenGLES.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 70E542F213E147E3002BA2C0 /* OpenGLES.framework */; }; 70E542F513E147EB002BA2C0 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 70E542F413E147EB002BA2C0 /* QuartzCore.framework */; }; /* End PBXBuildFile section */ @@ -438,6 +439,7 @@ 288765FC0DF74451002DB57D /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; }; 29B97316FDCFA39411CA2CEA /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; 32CA4F630368D1EE00C91783 /* linphone_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = linphone_Prefix.pch; sourceTree = ""; }; + 7066FC0B13E830E400EFC6DC /* libvpx.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libvpx.a; path = "liblinphone-sdk/apple-darwin/lib/libvpx.a"; sourceTree = ""; }; 70E542F213E147E3002BA2C0 /* OpenGLES.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGLES.framework; path = System/Library/Frameworks/OpenGLES.framework; sourceTree = SDKROOT; }; 70E542F413E147EB002BA2C0 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; 8D1107310486CEB800E47090 /* linphone-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "linphone-Info.plist"; plistStructureDefinitionIdentifier = "com.apple.xcode.plist.structure-definition.iphone.info-plist"; sourceTree = ""; }; @@ -448,6 +450,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + 7066FC0C13E830E400EFC6DC /* libvpx.a in Frameworks */, 70E542F513E147EB002BA2C0 /* QuartzCore.framework in Frameworks */, 70E542F313E147E3002BA2C0 /* OpenGLES.framework in Frameworks */, 22F3D57E13CCC89600A0DA02 /* liblinphone.a in Frameworks */, @@ -844,6 +847,7 @@ 29B97314FDCFA39411CA2CEA /* CustomTemplate */ = { isa = PBXGroup; children = ( + 7066FC0B13E830E400EFC6DC /* libvpx.a */, 70E542F413E147EB002BA2C0 /* QuartzCore.framework */, 70E542F213E147E3002BA2C0 /* OpenGLES.framework */, 22AA8AFB13D7125500B30535 /* libx264.a */, diff --git a/submodules/build/builder-iphone-os.mk b/submodules/build/builder-iphone-os.mk index dea57c805..015c9511e 100644 --- a/submodules/build/builder-iphone-os.mk +++ b/submodules/build/builder-iphone-os.mk @@ -33,6 +33,7 @@ linphone_configure_controls= \ --disable-sdl \ --disable-x11 \ --with-gsm=$(prefix) \ + --enable-vp8 \ SPEEX_CFLAGS="-I$(prefix)/include" \ SPEEXDSP_CFLAGS="-I$(prefix)/include" \ SPEEXDSP_LIBS="-L$(prefix)/lib -lspeexdsp" \ @@ -81,17 +82,17 @@ init: veryclean: veryclean-linphone rm -rf $(BUILDER_BUILD_DIR) -.NOTPARALLEL build-linphone: init build-openssl build-osip2 build-eXosip2 build-speex build-libgsm build-ffmpeg $(LINPHONE_BUILD_DIR)/Makefile +.NOTPARALLEL build-linphone: init build-openssl build-osip2 build-eXosip2 build-speex build-libgsm build-ffmpeg build-libvpx $(LINPHONE_BUILD_DIR)/Makefile cd $(LINPHONE_BUILD_DIR) && export PKG_CONFIG_PATH=$(prefix)/lib/pkgconfig export CONFIG_SITE=$(BUILDER_SRC_DIR)/build/$(config_site) make newdate && make && make install -clean-linphone: clean-osip2 clean-eXosip2 clean-speex clean-libgsm clean-msilbc clean-libilbc clean-openssl clean-msamr clean-ffmpeg clean-msx264 +clean-linphone: clean-osip2 clean-eXosip2 clean-speex clean-libgsm clean-msilbc clean-libilbc clean-openssl clean-msamr clean-ffmpeg clean-libvpx clean-msx264 cd $(LINPHONE_BUILD_DIR) && make clean veryclean-linphone: veryclean-osip2 veryclean-eXosip2 veryclean-speex veryclean-libgsm veryclean-msilbc veryclean-libilbc veryclean-openssl veryclean-msamr veryclean-msx264 #-cd $(LINPHONE_BUILD_DIR) && make distclean -cd $(LINPHONE_SRC_DIR) && rm -f configure -clean-makefile-linphone: clean-makefile-osip2 clean-makefile-eXosip2 clean-makefile-speex clean-makefile-libilbc clean-makefile-msilbc clean-makefile-openssl clean-makefile-msamr clean-makefile-ffmpeg +clean-makefile-linphone: clean-makefile-osip2 clean-makefile-eXosip2 clean-makefile-speex clean-makefile-libilbc clean-makefile-msilbc clean-makefile-openssl clean-makefile-msamr clean-makefile-ffmpeg clean-makefile-libvpx cd $(LINPHONE_BUILD_DIR) && rm -f Makefile && rm -f oRTP/Makefile && rm -f mediastreamer2/Makefile diff --git a/submodules/build/builders.d/libvpx.mk b/submodules/build/builders.d/libvpx.mk new file mode 100644 index 000000000..453cea967 --- /dev/null +++ b/submodules/build/builders.d/libvpx.mk @@ -0,0 +1,33 @@ +libvpx_configure_options=\ + --enable-static --disable-shared\ +# --extra-cflags="-arch $$ARCH" +# -Wl,-syslibroot,$$SYSROOT_PATH " \ + --enable-error-concealment --disable-examples + +ifneq (,$(findstring armv6,$(host))) + libvpx_configure_options+= --target=armv6-darwin-gcc --cpu=arm1176jzf-s +else ifneq (,$(findstring armv7,$(host))) + libvpx_configure_options+= --target=armv7-darwin-gcc --cpu=cortex-a8 +else + libvpx_configure_options+= --target=x86_64-darwin10-gcc +endif +libvpx_dir?=externals/libvpx + +$(BUILDER_BUILD_DIR)/$(libvpx_dir)/config.mak: + mkdir -p $(BUILDER_BUILD_DIR)/$(libvpx_dir) + cd $(BUILDER_BUILD_DIR)/$(libvpx_dir)/ \ + && host_alias=${host} . $(BUILDER_SRC_DIR)/build/$(config_site) \ + && $(BUILDER_SRC_DIR)/$(libvpx_dir)/configure --prefix=$(prefix) $(libvpx_configure_options) + +build-libvpx: $(BUILDER_BUILD_DIR)/$(libvpx_dir)/config.mak + cd $(BUILDER_BUILD_DIR)/$(libvpx_dir) && PKG_CONFIG_PATH=$(prefix)/lib/pkgconfig CONFIG_SITE=$(BUILDER_SRC_DIR)/build/$(config_site) make && make install + +clean-libvpx: + cd $(BUILDER_BUILD_DIR)/$(libvpx_dir) && make clean + +veryclean-libvpx: + cd $(BUILDER_BUILD_DIR)/$(libvpx_dir) && make distclean + +clean-makefile-libvpx: + cd $(BUILDER_BUILD_DIR)/$(libvpx_dir) && rm -f config.mak + diff --git a/submodules/externals/libvpx b/submodules/externals/libvpx new file mode 160000 index 000000000..6f080f9ce --- /dev/null +++ b/submodules/externals/libvpx @@ -0,0 +1 @@ +Subproject commit 6f080f9cec229bac78f78b5726849793aea91fd5 diff --git a/submodules/liblinphone.xcodeproj/project.pbxproj b/submodules/liblinphone.xcodeproj/project.pbxproj index 11588ab59..cb523e691 100644 --- a/submodules/liblinphone.xcodeproj/project.pbxproj +++ b/submodules/liblinphone.xcodeproj/project.pbxproj @@ -208,6 +208,8 @@ 22DD21B413A8E3310018ECD4 /* mediastreamViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 22DD21AD13A8E3310018ECD4 /* mediastreamViewController.m */; }; 22FC56A813CB69FB002FD0F1 /* qualityindicator.c in Sources */ = {isa = PBXBuildFile; fileRef = 22FC56A713CB69FA002FD0F1 /* qualityindicator.c */; }; 22FC56AA13CB6A4F002FD0F1 /* bitratecontrol.c in Sources */ = {isa = PBXBuildFile; fileRef = 22FC56A913CB6A4F002FD0F1 /* bitratecontrol.c */; }; + 7066FC0713E82A3600EFC6DC /* vp8.c in Sources */ = {isa = PBXBuildFile; fileRef = 7066FC0613E82A3600EFC6DC /* vp8.c */; }; + 7066FC0A13E830B800EFC6DC /* libvpx.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 7066FC0913E830B800EFC6DC /* libvpx.a */; }; 70E542EE13E147C7002BA2C0 /* OpenGLES.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 70E542ED13E147C7002BA2C0 /* OpenGLES.framework */; }; 70E542F113E147CE002BA2C0 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 70E542F013E147CE002BA2C0 /* QuartzCore.framework */; }; 70E542FA13E14816002BA2C0 /* shaders.h in Headers */ = {isa = PBXBuildFile; fileRef = 70E542F613E14816002BA2C0 /* shaders.h */; }; @@ -463,6 +465,8 @@ 22DD21AD13A8E3310018ECD4 /* mediastreamViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = mediastreamViewController.m; sourceTree = ""; }; 22FC56A713CB69FA002FD0F1 /* qualityindicator.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = qualityindicator.c; sourceTree = ""; }; 22FC56A913CB6A4F002FD0F1 /* bitratecontrol.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = bitratecontrol.c; sourceTree = ""; }; + 7066FC0613E82A3600EFC6DC /* vp8.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = vp8.c; sourceTree = ""; }; + 7066FC0913E830B800EFC6DC /* libvpx.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = libvpx.a; path = "../liblinphone-sdk/apple-darwin/lib/libvpx.a"; sourceTree = ""; }; 70E542ED13E147C7002BA2C0 /* OpenGLES.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = OpenGLES.framework; path = System/Library/Frameworks/OpenGLES.framework; sourceTree = SDKROOT; }; 70E542F013E147CE002BA2C0 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; }; 70E542F613E14816002BA2C0 /* shaders.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = shaders.h; sourceTree = ""; }; @@ -479,6 +483,7 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( + 7066FC0A13E830B800EFC6DC /* libvpx.a in Frameworks */, 70E542F113E147CE002BA2C0 /* QuartzCore.framework in Frameworks */, 70E542EE13E147C7002BA2C0 /* OpenGLES.framework in Frameworks */, 229A615313DEE8A500090183 /* libx264.a in Frameworks */, @@ -524,6 +529,7 @@ 0867D691FE84028FC02AAC07 /* liblinphone */ = { isa = PBXGroup; children = ( + 7066FC0913E830B800EFC6DC /* libvpx.a */, 70E542F013E147CE002BA2C0 /* QuartzCore.framework */, 70E542ED13E147C7002BA2C0 /* OpenGLES.framework */, 229A615113DEE8A400090183 /* libx264.a */, @@ -656,6 +662,7 @@ 222CA5DC11F6CF7600621220 /* src */ = { isa = PBXGroup; children = ( + 7066FC0613E82A3600EFC6DC /* vp8.c */, 70E542F613E14816002BA2C0 /* shaders.h */, 70E542F713E14816002BA2C0 /* shaders.m */, 70E542F813E14816002BA2C0 /* yuv2rgb.fs.h */, @@ -1211,6 +1218,7 @@ 229A614E13DDFE3500090183 /* g722_encode.c in Sources */, 229A615013DDFE3500090183 /* msg722.c in Sources */, 70E542FB13E14816002BA2C0 /* shaders.m in Sources */, + 7066FC0713E82A3600EFC6DC /* vp8.c in Sources */, ); runOnlyForDeploymentPostprocessing = 0; };