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

Side by Side Diff: third_party/cld_2/BUILD.gn

Issue 2400273002: Revert of Switching from CLD3 to CLD2 (Closed)
Patch Set: Created 4 years, 2 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 | « third_party/cld/BUILD.gn ('k') | no next file » | 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/features.gni") 5 import("//build/config/features.gni")
6 6
7 declare_args() { 7 declare_args() {
8 if (is_android || is_ios) { 8 if (is_android || is_ios) {
9 cld2_table_size = 0 # Small, accurate tables 9 cld2_table_size = 0 # Small, accurate tables
10 } else { 10 } else {
11 cld2_table_size = 2 # Larger, more accurate tables 11 cld2_table_size = 2 # Larger, more accurate tables
12 } 12 }
13 } 13 }
14 14
15 gypi_values = exec_script("//build/gypi_to_gn.py",
16 [ rebase_path("cld_2.gyp") ],
17 "scope",
18 [ "cld_2.gyp" ])
19
15 config("cld2_data_warnings") { 20 config("cld2_data_warnings") {
16 visibility = [ ":*" ] 21 visibility = [ ":*" ]
17 if (is_clang) { 22 if (is_clang) {
18 # The generated files don't have braces around subobject initializers. 23 # The generated files don't have braces around subobject initializers.
19 cflags = [ "-Wno-missing-braces" ] 24 cflags = [ "-Wno-missing-braces" ]
20 } 25 }
21 } 26 }
22 27
23 static_library("cld2_data") { 28 static_library("cld2_data") {
24 sources = [ 29 sources = gypi_values.cld2_data_sources
25 "src/internal/cld2_generated_cjk_compatible.cc",
26 "src/internal/cld2_generated_deltaoctachrome.cc",
27 "src/internal/cld2_generated_distinctoctachrome.cc",
28 "src/internal/cld_generated_cjk_delta_bi_4.cc",
29 "src/internal/cld_generated_cjk_uni_prop_80.cc",
30 "src/internal/cld_generated_score_quad_octa_2.cc",
31 "src/internal/generated_distinct_bi_0.cc",
32 ]
33
34 if (cld2_table_size == 0) { 30 if (cld2_table_size == 0) {
35 sources += [ "src/internal/cld2_generated_quadchrome_16.cc" ] 31 sources += gypi_values.cld2_data_smallest_sources
36 } else if (cld2_table_size == 2) { 32 } else if (cld2_table_size == 2) {
37 sources += [ "src/internal/cld2_generated_quadchrome_2.cc" ] 33 sources += gypi_values.cld2_data_largest_sources
38 } 34 }
39 35
40 include_dirs = [ 36 include_dirs = [
41 "src/internal", 37 "src/internal",
42 "src/public", 38 "src/public",
43 ] 39 ]
44 40
45 configs -= [ "//build/config/compiler:chromium_code" ] 41 configs -= [ "//build/config/compiler:chromium_code" ]
46 configs += [ 42 configs += [
47 "//build/config/compiler:no_chromium_code", 43 "//build/config/compiler:no_chromium_code",
(...skipping 10 matching lines...) Expand all
58 # https://code.google.com/p/cld2/issues/detail?id=37 54 # https://code.google.com/p/cld2/issues/detail?id=37
59 "-Wno-unused-private-field", 55 "-Wno-unused-private-field",
60 56
61 # offsetmap.cc uses a char as a subscript. 57 # offsetmap.cc uses a char as a subscript.
62 "-Wno-char-subscripts", 58 "-Wno-char-subscripts",
63 ] 59 ]
64 } 60 }
65 } 61 }
66 62
67 static_library("cld_2") { 63 static_library("cld_2") {
68 sources = [ 64 sources = gypi_values.cld2_core_sources + gypi_values.cld2_core_impl_sources
69 "src/internal/cld2tablesummary.h",
70 "src/internal/cldutil.cc",
71 "src/internal/cldutil.h",
72 "src/internal/cldutil_shared.cc",
73 "src/internal/cldutil_shared.h",
74 "src/internal/compact_lang_det.cc",
75 "src/internal/compact_lang_det_hint_code.cc",
76 "src/internal/compact_lang_det_hint_code.h",
77 "src/internal/compact_lang_det_impl.cc",
78 "src/internal/compact_lang_det_impl.h",
79 "src/internal/debug.h",
80 "src/internal/debug_empty.cc",
81 "src/internal/fixunicodevalue.cc",
82 "src/internal/fixunicodevalue.h",
83 "src/internal/generated_entities.cc",
84 "src/internal/generated_language.cc",
85 "src/internal/generated_language.h",
86 "src/internal/generated_ulscript.cc",
87 "src/internal/generated_ulscript.h",
88 "src/internal/getonescriptspan.cc",
89 "src/internal/getonescriptspan.h",
90 "src/internal/integral_types.h",
91 "src/internal/lang_script.cc",
92 "src/internal/lang_script.h",
93 "src/internal/langspan.h",
94 "src/internal/offsetmap.cc",
95 "src/internal/offsetmap.h",
96 "src/internal/port.h",
97 "src/internal/scoreonescriptspan.cc",
98 "src/internal/scoreonescriptspan.h",
99 "src/internal/stringpiece.h",
100 "src/internal/tote.cc",
101 "src/internal/tote.h",
102 "src/internal/utf8prop_lettermarkscriptnum.h",
103 "src/internal/utf8repl_lettermarklower.h",
104 "src/internal/utf8scannot_lettermarkspecial.h",
105 "src/internal/utf8statetable.cc",
106 "src/internal/utf8statetable.h",
107 "src/public/compact_lang_det.h",
108 "src/public/encodings.h",
109 ]
110
111 include_dirs = [ 65 include_dirs = [
112 "src/internal", 66 "src/internal",
113 "src/public", 67 "src/public",
114 ] 68 ]
115 69
116 public_deps = [ 70 public_deps = [
117 ":cld2_data", 71 ":cld2_data",
118 ] 72 ]
119 configs -= [ "//build/config/compiler:chromium_code" ] 73 configs -= [ "//build/config/compiler:chromium_code" ]
120 configs += [ 74 configs += [
121 "//build/config/compiler:no_chromium_code", 75 "//build/config/compiler:no_chromium_code",
122 ":cld2_warnings", 76 ":cld2_warnings",
123 ] 77 ]
124 } 78 }
OLDNEW
« no previous file with comments | « third_party/cld/BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698