OLD | NEW |
---|---|
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//testing/test.gni") | 5 import("//testing/test.gni") |
6 | 6 |
7 config("libsrtp_config") { | 7 config("libsrtp_config") { |
8 defines = [ | 8 defines = [ |
9 # Package identity | 9 # Package identity |
10 "PACKAGE_STRING=\"libsrtp2 2.0.0-pre\"", | 10 "PACKAGE_STRING=\"libsrtp2 2.0.0-pre\"", |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
42 # Supports clients depending on SRTP_RELATIVE_PATH. | 42 # Supports clients depending on SRTP_RELATIVE_PATH. |
43 # TODO(mattdr): Remove SRTP_RELATIVE_PATH and this config. | 43 # TODO(mattdr): Remove SRTP_RELATIVE_PATH and this config. |
44 include_dirs = [ | 44 include_dirs = [ |
45 ".", | 45 ".", |
46 "config", | 46 "config", |
47 "include", | 47 "include", |
48 "crypto/include", | 48 "crypto/include", |
49 ] | 49 ] |
50 } | 50 } |
51 | 51 |
52 config("libsrtp_warnings") { | |
53 cflags = [] | |
54 if (is_win) { | |
55 cflags += [ "/wd4018" ] # Signed/unsigned mismatch in comparison | |
56 } | |
57 } | |
58 | |
52 static_library("libsrtp") { | 59 static_library("libsrtp") { |
53 configs -= [ "//build/config/compiler:chromium_code" ] | 60 configs -= [ "//build/config/compiler:chromium_code" ] |
54 configs += [ "//build/config/compiler:no_chromium_code" ] | 61 configs += [ "//build/config/compiler:no_chromium_code" ] |
62 configs += [ ":libsrtp_warnings" ] | |
55 public_configs = [ ":libsrtp_config" ] | 63 public_configs = [ ":libsrtp_config" ] |
56 sources = [ | 64 sources = [ |
57 # includes | 65 # includes |
58 "include/ekt.h", | 66 "include/ekt.h", |
59 "include/rtp.h", | 67 "include/rtp.h", |
60 "include/srtp.h", | 68 "include/srtp.h", |
61 | 69 |
62 # headers | 70 # headers |
63 "crypto/include/aes.h", | 71 "crypto/include/aes.h", |
64 "crypto/include/aes_gcm_ossl.h", | 72 "crypto/include/aes_gcm_ossl.h", |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
101 "srtp/ekt.c", | 109 "srtp/ekt.c", |
102 "srtp/srtp.c", | 110 "srtp/srtp.c", |
103 ] | 111 ] |
104 public_deps = [ | 112 public_deps = [ |
105 "//third_party/boringssl:boringssl", | 113 "//third_party/boringssl:boringssl", |
106 ] | 114 ] |
107 } | 115 } |
108 | 116 |
109 config("srtp_test_config") { | 117 config("srtp_test_config") { |
110 include_dirs = [ "test" ] | 118 include_dirs = [ "test" ] |
119 | |
120 configs = [ ":libsrtp_warnings" ] | |
121 | |
122 cflags = [] | |
123 if (is_win && is_clang) { | |
kjellander_chromium
2016/10/12 22:59:48
Does this work even if it's not in a config? Becau
mattdr-at-chromium
2016/10/12 23:01:26
This is in a config, now, so it should come in aft
kjellander_chromium
2016/10/12 23:56:52
Oh, I dunno why I didn't see it was in a config al
| |
124 # TODO(mattdr): Bring in https://github.com/cisco/libsrtp/pull/213 | |
125 # and remove this. | |
126 cflags += [ "-Wno-format" ] | |
127 } | |
111 } | 128 } |
112 | 129 |
113 template("srtp_test") { | 130 template("srtp_test") { |
114 test("srtp_test_${target_name}") { | 131 test("srtp_test_${target_name}") { |
115 configs -= [ "//build/config/compiler:chromium_code" ] | 132 configs -= [ "//build/config/compiler:chromium_code" ] |
116 configs += [ "//build/config/compiler:no_chromium_code" ] | 133 configs += [ "//build/config/compiler:no_chromium_code" ] |
117 configs += [ ":srtp_test_config" ] | 134 configs += [ ":srtp_test_config" ] |
118 deps = [ | 135 deps = [ |
119 ":libsrtp", | 136 ":libsrtp", |
120 ] | 137 ] |
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
219 ":srtp_test_dtls_srtp_driver", | 236 ":srtp_test_dtls_srtp_driver", |
220 ":srtp_test_kernel_driver", | 237 ":srtp_test_kernel_driver", |
221 ":srtp_test_rdbx_driver", | 238 ":srtp_test_rdbx_driver", |
222 ":srtp_test_replay_driver", | 239 ":srtp_test_replay_driver", |
223 ":srtp_test_roc_driver", | 240 ":srtp_test_roc_driver", |
224 ":srtp_test_rtpw", | 241 ":srtp_test_rtpw", |
225 ":srtp_test_srtp_driver", | 242 ":srtp_test_srtp_driver", |
226 ] | 243 ] |
227 testonly = true | 244 testonly = true |
228 } | 245 } |
OLD | NEW |