Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(102)

Side by Side Diff: media/BUILD.gn

Issue 1095333004: GN Windows component build fixes: media (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « BUILD.gn ('k') | media/audio/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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("//build/config/android/config.gni") 5 import("//build/config/android/config.gni")
6 import("//build/config/arm.gni") 6 import("//build/config/arm.gni")
7 import("//build/config/features.gni") 7 import("//build/config/features.gni")
8 import("//build/config/linux/pkg_config.gni") 8 import("//build/config/linux/pkg_config.gni")
9 import("//build/config/ui.gni") 9 import("//build/config/ui.gni")
10 import("//media/media_options.gni") 10 import("//media/media_options.gni")
11 import("//testing/test.gni") 11 import("//testing/test.gni")
12 12
13 # Common configuration for targets in the media directory. 13 # Common configuration for targets in the media directory.
14 # NOT for exporting. 14 # NOT for exporting.
15 config("media_config") { 15 config("media_config") {
16 defines = [ "MEDIA_IMPLEMENTATION" ] 16 defines = []
17 if (!media_use_libvpx) { 17 if (!media_use_libvpx) {
18 defines += [ "MEDIA_DISABLE_LIBVPX" ] 18 defines += [ "MEDIA_DISABLE_LIBVPX" ]
19 } 19 }
20 if (!media_use_ffmpeg) { 20 if (!media_use_ffmpeg) {
21 defines += [ "MEDIA_DISABLE_FFMPEG" ] 21 defines += [ "MEDIA_DISABLE_FFMPEG" ]
22 } 22 }
23 if (current_cpu == "arm" && arm_use_neon) { 23 if (current_cpu == "arm" && arm_use_neon) {
24 defines += [ "USE_NEON" ] 24 defines += [ "USE_NEON" ]
25 } 25 }
26 if (use_pulseaudio) { 26 if (use_pulseaudio) {
27 defines += [ "USE_PULSEAUDIO" ] 27 defines += [ "USE_PULSEAUDIO" ]
28 if (!link_pulseaudio) { 28 if (!link_pulseaudio) {
29 defines += [ "DLOPEN_PULSEAUDIO" ] 29 defines += [ "DLOPEN_PULSEAUDIO" ]
30 } 30 }
31 } 31 }
32 if (use_cras) { 32 if (use_cras) {
33 defines += [ "USE_CRAS" ] 33 defines += [ "USE_CRAS" ]
34 } 34 }
35 if (use_alsa) { 35 if (use_alsa) {
36 defines += [ "USE_ALSA" ] 36 defines += [ "USE_ALSA" ]
37 } 37 }
38 } 38 }
39 39
40 config("media_implementation") {
41 defines = [ "MEDIA_IMPLEMENTATION" ]
42 }
43
40 config("media_dependent_config") { 44 config("media_dependent_config") {
41 defines = [] 45 defines = []
42 if (!media_use_libvpx) { 46 if (!media_use_libvpx) {
43 defines += [ "MEDIA_DISABLE_LIBVPX" ] 47 defines += [ "MEDIA_DISABLE_LIBVPX" ]
44 } 48 }
45 if (!media_use_ffmpeg) { 49 if (!media_use_ffmpeg) {
46 defines += [ "MEDIA_DISABLE_FFMPEG" ] 50 defines += [ "MEDIA_DISABLE_FFMPEG" ]
47 } 51 }
48 if (is_win) { 52 if (is_win) {
49 ldflags = [ 53 ldflags = [
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
271 "video/picture.cc", 275 "video/picture.cc",
272 "video/picture.h", 276 "video/picture.h",
273 "video/video_decode_accelerator.cc", 277 "video/video_decode_accelerator.cc",
274 "video/video_decode_accelerator.h", 278 "video/video_decode_accelerator.h",
275 "video/video_encode_accelerator.cc", 279 "video/video_encode_accelerator.cc",
276 "video/video_encode_accelerator.h", 280 "video/video_encode_accelerator.h",
277 ] 281 ]
278 282
279 configs += [ 283 configs += [
280 ":media_config", 284 ":media_config",
285 ":media_implementation",
281 286
282 # TODO(wolenetz): Fix size_t to int trunctaion in win64. 287 # TODO(wolenetz): Fix size_t to int trunctaion in win64.
283 # See http://crbug.com/171009 288 # See http://crbug.com/171009
284 "//build/config/compiler:no_size_t_to_int_warning", 289 "//build/config/compiler:no_size_t_to_int_warning",
285 ] 290 ]
286 all_dependent_configs = [ ":media_dependent_config" ] 291 all_dependent_configs = [ ":media_dependent_config" ]
287 292
293 allow_circular_includes_from = []
288 cflags = [] 294 cflags = []
289 libs = [] 295 libs = []
290 defines = [] 296 defines = []
291 deps = [] 297 deps = []
292 298
293 include_dirs = [ "." ] 299 include_dirs = [ "." ]
294 if (media_use_ffmpeg) { 300 if (media_use_ffmpeg) {
295 deps += [ "//third_party/ffmpeg" ] 301 deps += [ "//third_party/ffmpeg" ]
296 sources += [ 302 sources += [
297 "ffmpeg/ffmpeg_common.cc", 303 "ffmpeg/ffmpeg_common.cc",
(...skipping 29 matching lines...) Expand all
327 } 333 }
328 334
329 if (media_use_libvpx) { 335 if (media_use_libvpx) {
330 sources += [ 336 sources += [
331 "filters/vpx_video_decoder.cc", 337 "filters/vpx_video_decoder.cc",
332 "filters/vpx_video_decoder.h", 338 "filters/vpx_video_decoder.h",
333 ] 339 ]
334 deps += [ "//third_party/libvpx" ] 340 deps += [ "//third_party/libvpx" ]
335 } 341 }
336 342
337 if (!is_android) { 343 if (is_android) {
338 sources += [
339 "filters/opus_audio_decoder.cc",
340 "filters/opus_audio_decoder.h",
341 "renderers/default_renderer_factory.cc",
342 "renderers/default_renderer_factory.h",
343 ]
344 } else {
345 sources += [ 344 sources += [
346 "midi/midi_manager_android.cc", 345 "midi/midi_manager_android.cc",
347 "midi/usb_midi_device_android.cc", 346 "midi/usb_midi_device_android.cc",
348 "midi/usb_midi_device_android.h", 347 "midi/usb_midi_device_android.h",
349 "midi/usb_midi_device_factory_android.cc", 348 "midi/usb_midi_device_factory_android.cc",
350 "midi/usb_midi_device_factory_android.h", 349 "midi/usb_midi_device_factory_android.h",
351 "video/capture/android/video_capture_device_android.cc", 350 "video/capture/android/video_capture_device_android.cc",
352 "video/capture/android/video_capture_device_android.h", 351 "video/capture/android/video_capture_device_android.h",
353 "video/capture/android/video_capture_device_factory_android.cc", 352 "video/capture/android/video_capture_device_factory_android.cc",
354 "video/capture/android/video_capture_device_factory_android.h", 353 "video/capture/android/video_capture_device_factory_android.h",
355 ] 354 ]
356 deps += [ 355 deps += [
357 "//media/base/android", 356 "//media/base/android",
358 "//media/base/android:media_java", 357 "//media/base/android:media_java",
359 "//media/base/android:media_jni_headers", 358 "//media/base/android:media_jni_headers",
360 "//media/base/android:video_capture_jni_headers", 359 "//media/base/android:video_capture_jni_headers",
361 ] 360 ]
361 allow_circular_includes_from = [ "//media/base/android" ]
Dirk Pranke 2015/04/24 21:54:26 ick :(.
362 } else {
363 sources += [
364 "filters/opus_audio_decoder.cc",
365 "filters/opus_audio_decoder.h",
366 "renderers/default_renderer_factory.cc",
367 "renderers/default_renderer_factory.h",
368 ]
362 } 369 }
363 370
364 if (current_cpu != "arm" && is_chromeos) { 371 if (current_cpu != "arm" && is_chromeos) {
365 sources += [ 372 sources += [
366 "filters/h264_bitstream_buffer.cc", 373 "filters/h264_bitstream_buffer.cc",
367 "filters/h264_bitstream_buffer.h", 374 "filters/h264_bitstream_buffer.h",
368 ] 375 ]
369 } 376 }
370 377
371 if (use_alsa && use_udev) { 378 if (use_alsa && use_udev) {
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
507 "//ui/events:events_base", 514 "//ui/events:events_base",
508 "//ui/gfx", 515 "//ui/gfx",
509 "//ui/gfx/geometry", 516 "//ui/gfx/geometry",
510 "//url", 517 "//url",
511 ] 518 ]
512 } 519 }
513 520
514 # Minimal media component for media/cast on iOS. 521 # Minimal media component for media/cast on iOS.
515 if (is_ios) { 522 if (is_ios) {
516 component("media_for_cast_ios") { 523 component("media_for_cast_ios") {
517 configs += [ ":media_config" ] 524 configs += [
525 ":media_config",
526 ":media_implementation",
527 ]
518 all_dependent_configs = [ ":media_dependent_config" ] 528 all_dependent_configs = [ ":media_dependent_config" ]
519 include_dirs = [ "." ] 529 include_dirs = [ "." ]
520 libs = [ "CoreVideo.framework" ] 530 libs = [ "CoreVideo.framework" ]
521 531
522 deps = [ 532 deps = [
523 ":shared_memory_support", 533 ":shared_memory_support",
524 "//base", 534 "//base",
525 "//media/base:base_for_cast_ios", 535 "//media/base:base_for_cast_ios",
526 "//media/base/mac", 536 "//media/base/mac",
527 "//ui/gfx/geometry", 537 "//ui/gfx/geometry",
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after
746 "audio/audio_parameters.h", 756 "audio/audio_parameters.h",
747 "base/audio_bus.cc", 757 "base/audio_bus.cc",
748 "base/audio_bus.h", 758 "base/audio_bus.h",
749 "base/channel_layout.cc", 759 "base/channel_layout.cc",
750 "base/channel_layout.h", 760 "base/channel_layout.h",
751 "base/limits.h", 761 "base/limits.h",
752 "base/media_export.h", 762 "base/media_export.h",
753 "base/vector_math.cc", 763 "base/vector_math.cc",
754 "base/vector_math.h", 764 "base/vector_math.h",
755 ] 765 ]
756 configs += [ ":media_config" ] 766 configs += [
757 defines = [ "MEDIA_IMPLEMENTATION" ] 767 ":media_config",
768 ":media_implementation",
769 ]
758 deps = [ 770 deps = [
759 "//base", 771 "//base",
760 ] 772 ]
761 } 773 }
762 774
763 if (media_use_ffmpeg) { 775 if (media_use_ffmpeg) {
764 test("ffmpeg_regression_tests") { 776 test("ffmpeg_regression_tests") {
765 sources = [ 777 sources = [
766 "base/run_all_unittests.cc", 778 "base/run_all_unittests.cc",
767 "ffmpeg/ffmpeg_regression_tests.cc", 779 "ffmpeg/ffmpeg_regression_tests.cc",
768 ] 780 ]
769 781
770 configs += [ "//media:media_config" ] 782 configs += [ "//media:media_config" ]
771 783
772 deps = [ 784 deps = [
773 "//base/test:test_support", 785 "//base/test:test_support",
774 "//media", 786 "//media",
775 "//media:test_support", 787 "//media:test_support",
776 "//media/audio:test_support", 788 "//media/audio:test_support",
777 "//media/base:test_support", 789 "//media/base:test_support",
778 "//media/test:pipeline_integration_tests", 790 "//media/test:pipeline_integration_tests",
779 "//testing/gmock", 791 "//testing/gmock",
780 "//testing/gtest", 792 "//testing/gtest",
781 "//third_party/ffmpeg", 793 "//third_party/ffmpeg",
782 "//ui/gfx/geometry", 794 "//ui/gfx/geometry",
783 "//ui/gfx:test_support", 795 "//ui/gfx:test_support",
784 ] 796 ]
785 } 797 }
786 } 798 }
OLDNEW
« no previous file with comments | « BUILD.gn ('k') | media/audio/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698