git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
At least 30 GB of free disk space
Matching macOS and Xcode version (see Versions)
export PATH=/path/to/depot_tools:$PATH
export COMMIT=commit_id
export PATCH_COMMIT=patch_commit_id
# e.g.
# export COMMIT=963cc1ef1336b52ca27742beb28bfbc211ed54d0
# export PATCH_COMMIT=a57784d2f12b566cd79cd771d65b49a078841cca
mkdir WebRTC-build
cd WebRTC-build
fetch --nohooks webrtc_ios
git clone https://github.com/threema-ch/webrtc-build-docker.git
cd webrtc-build-docker
(The patches are part of our WebRTC PeerConnection Build Script.)
export PATH=/path/to/depot_tools:$PATH
export COMMIT=commit_id
export PATCH_COMMIT=patch_commit_id
cd WebRTC-build/src
git reset --hard
cd ../webrtc-build-docker
git checkout master && git pull origin master
git checkout $PATCH_COMMIT
cd ../src
git checkout master && git pull && git checkout $COMMIT && gclient sync
for i in ../webrtc-build-docker/build/patches/*.patch; do patch -p1 < $i; done
You can either build for release or debug. Debug is needed for the simulator.
tools_webrtc/ios/build_ios_libs.py --bitcode --arch arm64 arm --output-dir ../out
rm -r ../../WebRTC-release
mkdir ../../WebRTC-release
mv ../out/WebRTC.framework ../../WebRTC-release
tools_webrtc/ios/build_ios_libs.py --bitcode --arch arm64 arm x64 x86 --output-dir ../out
rm -r ../../WebRTC-debug
mkdir ../../WebRTC-debug
mv ../out/WebRTC.framework ../../WebRTC-debug
To ensure this version will be used in the app build, remove the existing chosen WebRTC build.
rm -r ../../WebRTC
iOS App Version | WebRTC Commit | Patch Commit | macOS Version | Xcode Version | WebRTC Binary Version |
---|---|---|---|---|---|
4.6.3 (2587) | 963cc1ef1336b52ca27742beb28bfbc211ed54d0 (m84) | a57784d2f12b566cd79cd771d65b49a078841cca | 10.15.5 (19F101) | 11.5 (11E608c) | 84.1.1 |