OLD | NEW |
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 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/features.gni") | 5 import("//build/config/features.gni") |
6 import("//build/config/ui.gni") | 6 import("//build/config/ui.gni") |
7 import("//testing/test.gni") | 7 import("//testing/test.gni") |
8 if (current_cpu == "arm") { | 8 if (current_cpu == "arm") { |
9 import("//build/config/arm.gni") | 9 import("//build/config/arm.gni") |
10 } | 10 } |
| 11 if (current_cpu == "mipsel" || current_cpu == "mips64el") { |
| 12 import("//build/config/mips.gni") |
| 13 } |
11 | 14 |
12 skia_support_gpu = !is_ios | 15 skia_support_gpu = !is_ios |
13 skia_support_pdf = !is_ios && (enable_basic_printing || enable_print_preview) | 16 skia_support_pdf = !is_ios && (enable_basic_printing || enable_print_preview) |
14 | 17 |
15 # The list of Skia defines that are to be set for blink. | 18 # The list of Skia defines that are to be set for blink. |
16 gypi_blink_skia_defines = | 19 gypi_blink_skia_defines = |
17 exec_script("//build/gypi_to_gn.py", | 20 exec_script("//build/gypi_to_gn.py", |
18 [ | 21 [ |
19 rebase_path( | 22 rebase_path( |
20 "//third_party/WebKit/public/blink_skia_config.gypi"), | 23 "//third_party/WebKit/public/blink_skia_config.gypi"), |
(...skipping 20 matching lines...) Expand all Loading... |
41 exec_script("//build/gypi_to_gn.py", | 44 exec_script("//build/gypi_to_gn.py", |
42 [ | 45 [ |
43 rebase_path("//third_party/skia/gyp/core.gypi"), | 46 rebase_path("//third_party/skia/gyp/core.gypi"), |
44 "--replace=<(skia_include_path)=//third_party/skia/include", | 47 "--replace=<(skia_include_path)=//third_party/skia/include", |
45 "--replace=<(skia_src_path)=//third_party/skia/src", | 48 "--replace=<(skia_src_path)=//third_party/skia/src", |
46 ], | 49 ], |
47 "scope", | 50 "scope", |
48 [ "//third_party/skia/gyp/core.gypi" ]) | 51 [ "//third_party/skia/gyp/core.gypi" ]) |
49 | 52 |
50 # The list of Skia gpu sources that are to be set for chromium. | 53 # The list of Skia gpu sources that are to be set for chromium. |
51 gypi_skia_gpu = | 54 if (skia_support_gpu) { |
52 exec_script("//build/gypi_to_gn.py", | 55 gypi_skia_gpu = |
53 [ | 56 exec_script("//build/gypi_to_gn.py", |
54 rebase_path("//third_party/skia/gyp/gpu.gypi"), | 57 [ |
55 "--replace=<(skia_include_path)=//third_party/skia/include", | 58 rebase_path("//third_party/skia/gyp/gpu.gypi"), |
56 "--replace=<(skia_src_path)=//third_party/skia/src", | 59 "--replace=<(skia_include_path)=//third_party/skia/include", |
57 ], | 60 "--replace=<(skia_src_path)=//third_party/skia/src", |
58 "scope", | 61 ], |
59 [ "//third_party/skia/gyp/gpu.gypi" ]) | 62 "scope", |
| 63 [ "//third_party/skia/gyp/gpu.gypi" ]) |
| 64 } |
60 | 65 |
61 # The list of Skia pdf sources that are to be set for chromium. | 66 # The list of Skia pdf sources that are to be set for chromium. |
62 gypi_skia_pdf = | 67 if (skia_support_pdf) { |
63 exec_script("//build/gypi_to_gn.py", | 68 gypi_skia_pdf = |
64 [ | 69 exec_script("//build/gypi_to_gn.py", |
65 rebase_path("//third_party/skia/gyp/pdf.gypi"), | 70 [ |
66 "--replace=<(skia_include_path)=//third_party/skia/include", | 71 rebase_path("//third_party/skia/gyp/pdf.gypi"), |
67 "--replace=<(skia_src_path)=//third_party/skia/src", | 72 "--replace=<(skia_include_path)=//third_party/skia/include", |
68 ], | 73 "--replace=<(skia_src_path)=//third_party/skia/src", |
69 "scope", | 74 ], |
70 [ "//third_party/skia/gyp/pdf.gypi" ]) | 75 "scope", |
| 76 [ "//third_party/skia/gyp/pdf.gypi" ]) |
| 77 } |
71 | 78 |
72 # The list of Skia effects that are to be set for chromium. | 79 # The list of Skia effects that are to be set for chromium. |
73 gypi_skia_effects = | 80 gypi_skia_effects = |
74 exec_script("//build/gypi_to_gn.py", | 81 exec_script("//build/gypi_to_gn.py", |
75 [ | 82 [ |
76 rebase_path("//third_party/skia/gyp/effects.gypi"), | 83 rebase_path("//third_party/skia/gyp/effects.gypi"), |
77 "--replace=<(skia_include_path)=//third_party/skia/include", | 84 "--replace=<(skia_include_path)=//third_party/skia/include", |
78 "--replace=<(skia_src_path)=//third_party/skia/src", | 85 "--replace=<(skia_src_path)=//third_party/skia/src", |
79 ], | 86 ], |
80 "scope", | 87 "scope", |
(...skipping 462 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
543 source_set("skia_opts") { | 550 source_set("skia_opts") { |
544 cflags = [] | 551 cflags = [] |
545 defines = [] | 552 defines = [] |
546 | 553 |
547 if (current_cpu == "x86" || current_cpu == "x64") { | 554 if (current_cpu == "x86" || current_cpu == "x64") { |
548 sources = gypi_skia_opts.sse2_sources + gypi_skia_opts.ssse3_sources + | 555 sources = gypi_skia_opts.sse2_sources + gypi_skia_opts.ssse3_sources + |
549 gypi_skia_opts.sse41_sources + | 556 gypi_skia_opts.sse41_sources + |
550 [ | 557 [ |
551 # Chrome-specific. | 558 # Chrome-specific. |
552 "ext/convolver_SSE2.cc", | 559 "ext/convolver_SSE2.cc", |
| 560 "ext/convolver_SSE2.h", |
553 ] | 561 ] |
554 | 562 |
555 if (is_linux || is_mac) { | 563 if (is_linux || is_mac) { |
556 cflags += [ "-msse4.1" ] | 564 cflags += [ "-msse4.1" ] |
557 } | 565 } |
558 } else if (current_cpu == "arm") { | 566 } else if (current_cpu == "arm") { |
559 # The assembly uses the frame pointer register (r7 in Thumb/r11 in | 567 # The assembly uses the frame pointer register (r7 in Thumb/r11 in |
560 # ARM), the compiler doesn't like that. | 568 # ARM), the compiler doesn't like that. |
561 cflags += [ "-fomit-frame-pointer" ] | 569 cflags += [ "-fomit-frame-pointer" ] |
562 | 570 |
563 if (arm_version >= 7) { | 571 if (arm_version >= 7) { |
564 sources = gypi_skia_opts.armv7_sources | 572 sources = gypi_skia_opts.armv7_sources |
565 if (arm_use_neon || arm_optionally_use_neon) { | 573 if (arm_use_neon || arm_optionally_use_neon) { |
566 sources += gypi_skia_opts.neon_sources | 574 sources += gypi_skia_opts.neon_sources |
567 | 575 |
568 # Root build config sets -mfpu=$arm_fpu, which we expect to be neon | 576 # Root build config sets -mfpu=$arm_fpu, which we expect to be neon |
569 # when running this. | 577 # when running this. |
570 if (!arm_use_neon) { | 578 if (!arm_use_neon) { |
571 configs -= [ "//build/config/compiler:compiler_arm_fpu" ] | 579 configs -= [ "//build/config/compiler:compiler_arm_fpu" ] |
572 cflags += [ "-mfpu=neon" ] | 580 cflags += [ "-mfpu=neon" ] |
573 } | 581 } |
574 } | 582 } |
575 } else { | 583 } else { |
576 sources = gypi_skia_opts.none_sourcees | 584 sources = gypi_skia_opts.none_sourcees |
577 } | 585 } |
578 } else if (current_cpu == "mipsel") { | 586 } else if (current_cpu == "mipsel") { |
579 cflags += [ "-fomit-frame-pointer" ] | 587 cflags += [ "-fomit-frame-pointer" ] |
580 sources = gypi_skia_opts.none_sources | 588 |
| 589 if (mips_dsp_rev >= 1) { |
| 590 sources = gypi_skia_opts.mips_dsp_sources |
| 591 if (mips_dsp_rev >= 2) { |
| 592 sources += [ |
| 593 # Chrome-specific. |
| 594 "ext/convolver_mips_dspr2.cc", |
| 595 "ext/convolver_mips_dspr2.h", |
| 596 ] |
| 597 } |
| 598 } else { |
| 599 sources = gypi_skia_opts.none_sources |
| 600 } |
581 } else { | 601 } else { |
582 assert(false, "Need to port cpu specific stuff from skia_library_opts.gyp") | 602 assert(false, "Need to port cpu specific stuff from skia_library_opts.gyp") |
583 } | 603 } |
584 | 604 |
585 if (is_android && !is_debug) { | 605 if (is_android && !is_debug) { |
586 configs -= [ "//build/config/compiler:optimize" ] | 606 configs -= [ "//build/config/compiler:optimize" ] |
587 configs += [ "//build/config/compiler:optimize_max" ] | 607 configs += [ "//build/config/compiler:optimize_max" ] |
588 } | 608 } |
589 | 609 |
590 configs -= [ "//build/config/compiler:chromium_code" ] | 610 configs -= [ "//build/config/compiler:chromium_code" ] |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
647 sources = [ | 667 sources = [ |
648 "tools/filter_fuzz_stub/filter_fuzz_stub.cc", | 668 "tools/filter_fuzz_stub/filter_fuzz_stub.cc", |
649 ] | 669 ] |
650 | 670 |
651 deps = [ | 671 deps = [ |
652 ":skia", | 672 ":skia", |
653 "//base", | 673 "//base", |
654 ] | 674 ] |
655 } | 675 } |
656 } | 676 } |
OLD | NEW |