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_overrides/build.gni") | 5 import("//build_overrides/build.gni") |
6 | 6 |
| 7 if (current_cpu == "arm" || current_cpu == "arm64") { |
| 8 import("//build/config/arm.gni") |
| 9 } |
| 10 |
7 config("zlib_config") { | 11 config("zlib_config") { |
8 include_dirs = [ "." ] | 12 include_dirs = [ "." ] |
9 } | 13 } |
10 | 14 |
11 static_library("zlib_x86_simd") { | 15 static_library("zlib_x86_simd") { |
12 if (!is_ios && (current_cpu == "x86" || current_cpu == "x64")) { | 16 if (!is_ios && (current_cpu == "x86" || current_cpu == "x64")) { |
13 sources = [ | 17 sources = [ |
14 "crc_folding.c", | 18 "crc_folding.c", |
15 "fill_window_sse.c", | 19 "fill_window_sse.c", |
16 ] | 20 ] |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 "trees.c", | 70 "trees.c", |
67 "trees.h", | 71 "trees.h", |
68 "uncompr.c", | 72 "uncompr.c", |
69 "x86.h", | 73 "x86.h", |
70 "zconf.h", | 74 "zconf.h", |
71 "zlib.h", | 75 "zlib.h", |
72 "zutil.c", | 76 "zutil.c", |
73 "zutil.h", | 77 "zutil.h", |
74 ] | 78 ] |
75 | 79 |
| 80 if (current_cpu == "arm" || current_cpu == "arm64") { |
| 81 if (arm_use_neon) { |
| 82 sources -= [ |
| 83 "inflate.c", |
| 84 "inffast.c", |
| 85 ] |
| 86 sources += [ |
| 87 "contrib/arm/inflate.c", |
| 88 "contrib/arm/inffast.c", |
| 89 "contrib/arm/chunkcopy.h", |
| 90 ] |
| 91 } |
| 92 } |
| 93 |
76 if (!is_ios && (current_cpu == "x86" || current_cpu == "x64")) { | 94 if (!is_ios && (current_cpu == "x86" || current_cpu == "x64")) { |
77 sources += [ "x86.c" ] | 95 sources += [ "x86.c" ] |
78 } | 96 } |
79 | 97 |
80 configs -= [ "//build/config/compiler:chromium_code" ] | 98 configs -= [ "//build/config/compiler:chromium_code" ] |
81 configs += [ | 99 configs += [ |
82 "//build/config/compiler:no_chromium_code", | 100 "//build/config/compiler:no_chromium_code", |
83 | 101 |
84 # Must be after no_chromium_code for warning flags to be ordered correctly. | 102 # Must be after no_chromium_code for warning flags to be ordered correctly. |
85 ":zlib_warnings", | 103 ":zlib_warnings", |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
156 static_library("compression_utils") { | 174 static_library("compression_utils") { |
157 sources = [ | 175 sources = [ |
158 "google/compression_utils.cc", | 176 "google/compression_utils.cc", |
159 "google/compression_utils.h", | 177 "google/compression_utils.h", |
160 ] | 178 ] |
161 deps = [ | 179 deps = [ |
162 ":zlib", | 180 ":zlib", |
163 ] | 181 ] |
164 } | 182 } |
165 } | 183 } |
OLD | NEW |