如何获取较旧的webrtc修订版并为arm64编译

时间:2015-01-06 06:47:15

标签: ios webrtc arm64

是否可以使用“fetch webrtc”获取较旧的webrtc修订版(可能带有一些标记/选项),然后将其编译为arm64?

我尝试使用gclient sync --force -r 6881删除旧版本,但在编译时出错。

我知道它的旧版本,但是,如果可能的话,我想为arm64编译特定的版本。

这就是我所做的:

git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
export PATH="$PATH":`pwd`/depot_tools
gclient config http://webrtc.googlecode.com/svn/trunk
echo "target_os = ['ios']" >> .gclient
export GYP_DEFINES="OS=ios"
gclient sync --force -r 6881

这是拉正确的主干(运行'svn checkout http://webrtc.googlecode.com/svn/trunk@6881..。)

export GYP_CROSSCOMPILE=1
export GYP_DEFINES=“build_with_libjingle=1 clang=1 component=static_library dcheck_always_on=1 fastbuild=0 OS=ios target_arch=arm64 target_subarch=arm64”
export GYP_GENERATOR_FLAGS=“output_dir=out_ios64"
export GYP_GENERATORS=“ninja"
cd trunk
gclient runhooks
ninja -C out_ios64/Release-iphoneos AppRTCDemo

我收到了这个错误:

Admins-Mac-mini:trunk admin$ ninja -C out_ios64/Release-iphoneos AppRTCDemo
ninja: Entering directory `out_ios64/Release-iphoneos'
[206/1912] CXX obj/third_party/libyuv/source/libyuv.scale_argb.o
FAILED: c++ -MMD -MF obj/third_party/libyuv/source/libyuv.scale_argb.o.d -DV8_DEPRECATION_WARNINGS -DBLINK_SCALE_FILTERS_AT_RECORD_TIME -DDISABLE_NACL -DCHROMIUM_BUILD -DCR_CLANG_REVISION=214024 -DUSE_LIBJPEG_TURBO=1 -DENABLE_CONFIGURATION_POLICY -DDISCARDABLE_MEMORY_ALWAYS_SUPPORTED_NATIVELY -DSYSTEM_NATIVELY_SIGNALS_MEMORY_PRESSURE -DDCHECK_ALWAYS_ON=1 -DENABLE_EGLIMAGE=1 -DCLD_VERSION=1 -DENABLE_SPELLCHECK=1 -DDISABLE_FTP_SUPPORT=1 -DNDEBUG -DNVALGRIND -DDYNAMIC_ANNOTATIONS_ENABLED=0 -DNS_BLOCK_ASSERTIONS=1 -Igen -I../../third_party/libyuv/include -I../../third_party/libyuv -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.1.sdk -Os -gdwarf-2 -fvisibility=hidden -Wnewline-eof -miphoneos-version-min=6.0 -arch arm64 -Wendif-labels -Wno-unused-parameter -Wno-missing-field-initializers -Wno-selector-type-mismatch -Wno-unknown-warning-option -Wheader-hygiene -Wno-char-subscripts -Wno-unneeded-internal-declaration -Wno-covered-switch-default -Wstring-conversion -Wno-c++11-narrowing -Wno-deprecated-register -std=gnu++0x -fno-rtti -fno-exceptions -fvisibility-inlines-hidden -fno-threadsafe-statics -fno-slp-vectorize -fcolor-diagnostics  -c ../../third_party/libyuv/source/scale_argb.cc -o obj/third_party/libyuv/source/libyuv.scale_argb.o
../../third_party/libyuv/source/scale_argb.cc:150:26: error: assigning to 'void (*)(const uint8 *, ptrdiff_t, int, uint8 *, int)' from incompatible type 'void (const uint8 *, int, int, uint8 *, int)': type mismatch at 2nd parameter ('ptrdiff_t' (aka 'long') vs 'int')
    ScaleARGBRowDownEven = filtering ? ScaleARGBRowDownEvenBox_NEON :
                         ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
[206/1912] LINK libvpx_obj_int_extract, POSTBUILDS
ninja: build stopped: subcommand failed.

我想我错过了一些依赖项(也许是因为它是一个旧主干)但不确定。

同样对于ios target_arch=armv7,它编译得很好。

任何帮助都会很棒,

由于

更新

拉一个稍新的版本(r6915)没有帮助:

libvpx库仍有一些错误

[58/1912] CXX obj/third_party/libyuv/source/libyuv.scale_argb.o
FAILED: c++ -MMD -MF obj/third_party/libyuv/source/libyuv.scale_argb.o.d -DV8_DEPRECATION_WARNINGS -DDISABLE_NACL -DCHROMIUM_BUILD -DCR_CLANG_REVISION=214024 -DUSE_LIBJPEG_TURBO=1 -DENABLE_CONFIGURATION_POLICY -DDISCARDABLE_MEMORY_ALWAYS_SUPPORTED_NATIVELY -DSYSTEM_NATIVELY_SIGNALS_MEMORY_PRESSURE -DDCHECK_ALWAYS_ON=1 -DENABLE_EGLIMAGE=1 -DCLD_VERSION=1 -DENABLE_SPELLCHECK=1 -DDISABLE_FTP_SUPPORT=1 -DNDEBUG -DNVALGRIND -DDYNAMIC_ANNOTATIONS_ENABLED=0 -DNS_BLOCK_ASSERTIONS=1 -Igen -I../../third_party/libyuv/include -I../../third_party/libyuv -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.1.sdk -Os -gdwarf-2 -fvisibility=hidden -Wnewline-eof -miphoneos-version-min=7.0 -arch arm64 -Wendif-labels -Wno-unused-parameter -Wno-missing-field-initializers -Wno-selector-type-mismatch -Wno-unknown-warning-option -Wheader-hygiene -Wno-char-subscripts -Wno-unneeded-internal-declaration -Wno-covered-switch-default -Wstring-conversion -Wno-c++11-narrowing -Wno-deprecated-register -std=gnu++0x -stdlib=libstdc++ -fno-rtti -fno-exceptions -fvisibility-inlines-hidden -fno-threadsafe-statics -fno-slp-vectorize -fcolor-diagnostics  -c ../../third_party/libyuv/source/scale_argb.cc -o obj/third_party/libyuv/source/libyuv.scale_argb.o
../../third_party/libyuv/source/scale_argb.cc:150:26: error: assigning to 'void (*)(const uint8 *, ptrdiff_t, int, uint8 *, int)' from incompatible type 'void (const uint8 *, int, int, uint8 *, int)': type mismatch at 2nd parameter ('ptrdiff_t' (aka 'long') vs 'int')
    ScaleARGBRowDownEven = filtering ? ScaleARGBRowDownEvenBox_NEON :
                         ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
[58/1912] LINK libvpx_obj_int_extract, POSTBUILDS
ninja: build stopped: subcommand failed.

更新2:

事实证明(现在)arm64构建仅适用于以下环境:

OS X版本10.9.5

Xcode版本:6.1.1

所以今天早上我尝试按照http://www.webrtc.org/native-code/ios

的指示拉动并构建最新版本(当时 - r8053)

除了2个警告外,它似乎构建正常:

1622/2019] CC obj/chromium/src/net/third_party/nss/ssl/libssl.sslmutex.o
../../chromium/src/net/third_party/nss/ssl/sslmutex.c:522:14: warning: 'sem_init' is deprecated [-Wdeprecated-declarations]
        rv = sem_init(&pMutex->u.sem, shared, 1);
             ^
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.1.sdk/usr/include/sys/semaphore.h:55:5: note: 'sem_init' has been explicitly marked deprecated here
int sem_init(sem_t *, int, unsigned int) __deprecated;
    ^
../../chromium/src/net/third_party/nss/ssl/sslmutex.c:544:7: warning: 'sem_destroy' is deprecated [-Wdeprecated-declarations]
        rv = sem_destroy(&pMutex->u.sem);
             ^
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.1.sdk/usr/include/sys/semaphore.h:53:5: note: 'sem_destroy' has been explicitly marked deprecated here
int sem_destroy(sem_t *) __deprecated;
    ^
2 warnings generated.
[2019/2019] STAMP AppRTCDemo.app

但是对于旧版本,仍然无法构建arm64库(构建时有关libyuv的一些错误)

所以我的问题是:

  1. 是否可以在几个月前修改arm64库以进行修订,例如6881 ???

  2. 如何使用新的获取方法获取旧版本?

  3. 谢谢

0 个答案:

没有答案