mirror of
https://github.com/danog/patches.git
synced 2024-11-30 04:19:34 +01:00
Add patches to build webrtc with external OpenSSL.
This commit is contained in:
parent
b2ee1fb198
commit
9986480b6f
27
webrtc_libsrtp.diff
Normal file
27
webrtc_libsrtp.diff
Normal file
@ -0,0 +1,27 @@
|
||||
diff --git a/BUILD.gn b/BUILD.gn
|
||||
index 6359585..0c9d2ff 100644
|
||||
--- a/BUILD.gn
|
||||
+++ b/BUILD.gn
|
||||
@@ -3,6 +3,7 @@
|
||||
# found in the LICENSE file.
|
||||
|
||||
import("//testing/test.gni")
|
||||
+import("//webrtc.gni")
|
||||
|
||||
declare_args() {
|
||||
# Tests may not be appropriate for some build environments, e.g. Windows.
|
||||
@@ -114,9 +115,11 @@ static_library("libsrtp") {
|
||||
"srtp/ekt.c",
|
||||
"srtp/srtp.c",
|
||||
]
|
||||
- public_deps = [
|
||||
- "//third_party/boringssl:boringssl",
|
||||
- ]
|
||||
+ if (rtc_build_ssl) {
|
||||
+ public_deps += [ "//third_party/boringssl" ]
|
||||
+ } else {
|
||||
+ configs += [ "//rtc_base:external_ssl_library" ]
|
||||
+ }
|
||||
}
|
||||
|
||||
if (build_libsrtp_tests) {
|
26
webrtc_src.diff
Normal file
26
webrtc_src.diff
Normal file
@ -0,0 +1,26 @@
|
||||
diff --git a/rtc_base/BUILD.gn b/rtc_base/BUILD.gn
|
||||
index 0805a5c549..6150fdaaa9 100644
|
||||
--- a/rtc_base/BUILD.gn
|
||||
+++ b/rtc_base/BUILD.gn
|
||||
@@ -24,6 +24,7 @@ if (!rtc_build_ssl) {
|
||||
assert(rtc_ssl_root != "",
|
||||
"You must specify rtc_ssl_root when rtc_build_ssl==0.")
|
||||
include_dirs = [ rtc_ssl_root ]
|
||||
+ libs = rtc_ssl_libs
|
||||
}
|
||||
}
|
||||
|
||||
diff --git a/webrtc.gni b/webrtc.gni
|
||||
index 64a170c23f..044529a689 100644
|
||||
--- a/webrtc.gni
|
||||
+++ b/webrtc.gni
|
||||
@@ -85,6 +85,9 @@ declare_args() {
|
||||
# library that comes with WebRTC (i.e. rtc_build_ssl == 0).
|
||||
rtc_ssl_root = ""
|
||||
|
||||
+ # Used to specify an external OpenSSL libs.
|
||||
+ rtc_ssl_libs = []
|
||||
+
|
||||
# Selects fixed-point code where possible.
|
||||
rtc_prefer_fixed_point = false
|
||||
|
23
webrtc_third_party.diff
Normal file
23
webrtc_third_party.diff
Normal file
@ -0,0 +1,23 @@
|
||||
diff --git a/usrsctp/BUILD.gn b/usrsctp/BUILD.gn
|
||||
index 014a076aec3..2d7daeba03a 100644
|
||||
--- a/usrsctp/BUILD.gn
|
||||
+++ b/usrsctp/BUILD.gn
|
||||
@@ -3,6 +3,7 @@
|
||||
# found in the LICENSE file.
|
||||
|
||||
import("//build/toolchain/toolchain.gni")
|
||||
+import("//webrtc.gni")
|
||||
|
||||
config("usrsctp_config") {
|
||||
include_dirs = [
|
||||
@@ -140,5 +141,9 @@ static_library("usrsctp") {
|
||||
if (is_fuchsia) {
|
||||
defines += [ "__Userspace_os_Fuchsia" ]
|
||||
}
|
||||
- deps = [ "//third_party/boringssl" ]
|
||||
+ if (rtc_build_ssl) {
|
||||
+ deps += [ "//third_party/boringssl" ]
|
||||
+ } else {
|
||||
+ configs += [ "//rtc_base:external_ssl_library" ]
|
||||
+ }
|
||||
}
|
Loading…
Reference in New Issue
Block a user