OLD | NEW |
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 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 { | 5 { |
6 'variables': { | 6 'variables': { |
7 'conditions': [ | 7 'conditions': [ |
8 # TODO(wtc): change "mipselx" to "mipsel" in this file when the | 8 # TODO(wtc): change "mipselx" to "mipsel" in this file when the |
9 # compilation errors in the MIPS optimizations are fixed. | 9 # compilation errors in the MIPS optimizations are fixed. |
10 ['target_arch=="arm" or target_arch=="arm64" or target_arch=="mipselx"', { | 10 ['target_arch=="arm" or target_arch=="arm64" or target_arch=="mipselx"', { |
(...skipping 13 matching lines...) Expand all Loading... |
24 }], | 24 }], |
25 ['target_arch=="arm" and (OS=="win" or OS=="android" or OS=="linux")', { | 25 ['target_arch=="arm" and (OS=="win" or OS=="android" or OS=="linux")', { |
26 # Based on the conditions in celt/arm/armcpu.c: | 26 # Based on the conditions in celt/arm/armcpu.c: |
27 # defined(_MSC_VER) || defined(__linux__). | 27 # defined(_MSC_VER) || defined(__linux__). |
28 'use_opus_rtcd%': 1, | 28 'use_opus_rtcd%': 1, |
29 }, { | 29 }, { |
30 'use_opus_rtcd%': 0, | 30 'use_opus_rtcd%': 0, |
31 }], | 31 }], |
32 ], | 32 ], |
33 }, | 33 }, |
| 34 'target_defaults': { |
| 35 'target_conditions': [ |
| 36 ['_type=="executable"', { |
| 37 # All of the executable targets depend on 'opus'. Unfortunately the |
| 38 # 'dependencies' block cannot be inherited via 'target_defaults'. |
| 39 'include_dirs': [ |
| 40 'src/celt', |
| 41 'src/silk', |
| 42 ], |
| 43 'conditions': [ |
| 44 ['OS == "win"', { |
| 45 'defines': [ |
| 46 'inline=__inline', |
| 47 ], |
| 48 }], |
| 49 ['OS=="android"', { |
| 50 'libraries': [ |
| 51 '-llog', |
| 52 ], |
| 53 }], |
| 54 ['clang==1', { |
| 55 'cflags': [ '-Wno-absolute-value' ], |
| 56 }] |
| 57 ], |
| 58 }], |
| 59 ], |
| 60 }, |
34 'targets': [ | 61 'targets': [ |
35 { | 62 { |
36 'target_name': 'opus', | 63 'target_name': 'opus', |
37 'type': 'static_library', | 64 'type': 'static_library', |
38 'defines': [ | 65 'defines': [ |
39 'OPUS_BUILD', | 66 'OPUS_BUILD', |
40 'OPUS_EXPORT=', | 67 'OPUS_EXPORT=', |
41 ], | 68 ], |
42 'include_dirs': [ | 69 'include_dirs': [ |
43 'src/celt', | 70 'src/celt', |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 ], | 171 ], |
145 }], | 172 }], |
146 ], | 173 ], |
147 }, # target opus | 174 }, # target opus |
148 { | 175 { |
149 'target_name': 'opus_compare', | 176 'target_name': 'opus_compare', |
150 'type': 'executable', | 177 'type': 'executable', |
151 'dependencies': [ | 178 'dependencies': [ |
152 'opus' | 179 'opus' |
153 ], | 180 ], |
154 'conditions': [ | |
155 ['OS == "win"', { | |
156 'defines': [ | |
157 'inline=__inline', | |
158 ], | |
159 }], | |
160 ['OS=="android"', { | |
161 'link_settings': { | |
162 'libraries': [ | |
163 '-llog', | |
164 ], | |
165 }, | |
166 }], | |
167 ['clang==1', { | |
168 'cflags': [ '-Wno-absolute-value' ], | |
169 }] | |
170 ], | |
171 'sources': [ | 181 'sources': [ |
172 'src/src/opus_compare.c', | 182 'src/src/opus_compare.c', |
173 ], | 183 ], |
174 'include_dirs': [ | |
175 'src/celt', | |
176 'src/silk', | |
177 ], | |
178 }, # target opus_compare | 184 }, # target opus_compare |
179 { | 185 { |
180 'target_name': 'opus_demo', | 186 'target_name': 'opus_demo', |
181 'type': 'executable', | 187 'type': 'executable', |
182 'dependencies': [ | 188 'dependencies': [ |
183 'opus' | 189 'opus' |
184 ], | 190 ], |
185 'conditions': [ | |
186 ['OS == "win"', { | |
187 'defines': [ | |
188 'inline=__inline', | |
189 ], | |
190 }], | |
191 ['OS=="android"', { | |
192 'link_settings': { | |
193 'libraries': [ | |
194 '-llog', | |
195 ], | |
196 }, | |
197 }], | |
198 ['clang==1', { | |
199 'cflags': [ '-Wno-absolute-value' ], | |
200 }] | |
201 ], | |
202 'sources': [ | 191 'sources': [ |
203 'src/src/opus_demo.c', | 192 'src/src/opus_demo.c', |
204 ], | 193 ], |
205 'include_dirs': [ | 194 }, # target opus_demo |
206 'src/celt', | 195 { |
207 'src/silk', | 196 'target_name': 'test_opus_api', |
| 197 'type': 'executable', |
| 198 'dependencies': [ |
| 199 'opus' |
208 ], | 200 ], |
209 }, # target opus_demo | 201 'sources': [ |
| 202 'src/tests/test_opus_api.c', |
| 203 ], |
| 204 }, # target test_opus_api |
| 205 { |
| 206 'target_name': 'test_opus_encode', |
| 207 'type': 'executable', |
| 208 'dependencies': [ |
| 209 'opus' |
| 210 ], |
| 211 'sources': [ |
| 212 'src/tests/test_opus_encode.c', |
| 213 ], |
| 214 }, # target test_opus_encode |
| 215 { |
| 216 'target_name': 'test_opus_decode', |
| 217 'type': 'executable', |
| 218 'dependencies': [ |
| 219 'opus' |
| 220 ], |
| 221 'sources': [ |
| 222 'src/tests/test_opus_decode.c', |
| 223 ], |
| 224 }, # target test_opus_decode |
| 225 { |
| 226 'target_name': 'test_opus_padding', |
| 227 'type': 'executable', |
| 228 'dependencies': [ |
| 229 'opus' |
| 230 ], |
| 231 'sources': [ |
| 232 'src/tests/test_opus_padding.c', |
| 233 ], |
| 234 }, # target test_opus_padding |
210 ] | 235 ] |
211 } | 236 } |
OLD | NEW |