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 if (cpu_arch == "arm") { | 7 if (cpu_arch == "arm") { |
8 import("//build/config/arm.gni") | 8 import("//build/config/arm.gni") |
9 } | 9 } |
10 | 10 |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 if (is_posix) { | 129 if (is_posix) { |
130 defines += [ "SK_USE_POSIX_THREADS" ] | 130 defines += [ "SK_USE_POSIX_THREADS" ] |
131 } | 131 } |
132 | 132 |
133 if (is_android) { | 133 if (is_android) { |
134 defines += [ | 134 defines += [ |
135 "SK_BUILD_FOR_ANDROID", | 135 "SK_BUILD_FOR_ANDROID", |
136 "USE_CHROMIUM_SKIA", | 136 "USE_CHROMIUM_SKIA", |
137 ] | 137 ] |
138 } | 138 } |
| 139 |
| 140 if (is_mac) { |
| 141 defines += [ "SK_BUILD_FOR_MAC" ] |
| 142 } |
139 } | 143 } |
140 | 144 |
141 # Internal-facing config for Skia library code. | 145 # Internal-facing config for Skia library code. |
142 config("skia_library_config") { | 146 config("skia_library_config") { |
143 # These include directories are only included for Skia code and are not | 147 # These include directories are only included for Skia code and are not |
144 # exported to dependents. It's not clear if this is on purpose, but this | 148 # exported to dependents. It's not clear if this is on purpose, but this |
145 # matches the GYP build. | 149 # matches the GYP build. |
146 include_dirs = [] | 150 include_dirs = [] |
147 if (is_mac || is_ios) { | 151 if (is_mac || is_ios) { |
148 include_dirs += [ "//third_party/skia/include/utils/mac" ] | 152 include_dirs += [ "//third_party/skia/include/utils/mac" ] |
(...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
549 ] | 553 ] |
550 | 554 |
551 # SSE 4 | 555 # SSE 4 |
552 if (cpu_arch == "x86") { | 556 if (cpu_arch == "x86") { |
553 sources += [ "//third_party/skia/src/opts/SkBlitRow_opts_SSE4_asm.S" ] | 557 sources += [ "//third_party/skia/src/opts/SkBlitRow_opts_SSE4_asm.S" ] |
554 } else { # x64 | 558 } else { # x64 |
555 sources += [ "//third_party/skia/src/opts/SkBlitRow_opts_SSE4_x64_asm.S" ] | 559 sources += [ "//third_party/skia/src/opts/SkBlitRow_opts_SSE4_x64_asm.S" ] |
556 } | 560 } |
557 | 561 |
558 if (is_linux || is_mac) { | 562 if (is_linux || is_mac) { |
559 cflags += [ "-msse4" ] | 563 cflags += [ "-msse4.1" ] |
560 } | 564 } |
561 } else if (cpu_arch == "arm") { | 565 } else if (cpu_arch == "arm") { |
562 sources = [ | 566 sources = [ |
563 "//third_party/skia/src/opts/SkBitmapProcState_opts_arm.cpp", | 567 "//third_party/skia/src/opts/SkBitmapProcState_opts_arm.cpp", |
564 ] | 568 ] |
565 | 569 |
566 # The assembly uses the frame pointer register (r7 in Thumb/r11 in | 570 # The assembly uses the frame pointer register (r7 in Thumb/r11 in |
567 # ARM), the compiler doesn't like that. | 571 # ARM), the compiler doesn't like that. |
568 cflags += [ "-fomit-frame-pointer" ] | 572 cflags += [ "-fomit-frame-pointer" ] |
569 | 573 |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
655 ":skia_config", | 659 ":skia_config", |
656 "//build/config/compiler:no_chromium_code" | 660 "//build/config/compiler:no_chromium_code" |
657 ] | 661 ] |
658 | 662 |
659 deps = [ | 663 deps = [ |
660 "//base", | 664 "//base", |
661 ] | 665 ] |
662 | 666 |
663 visibility = ":skia" | 667 visibility = ":skia" |
664 } | 668 } |
OLD | NEW |