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

Side by Side Diff: third_party/harfbuzz-ng/BUILD.gn

Issue 1318823008: Un-nest configs in GN files. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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_2/BUILD.gn ('k') | third_party/hunspell/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/chrome_build.gni") 5 import("//build/config/chrome_build.gni")
6 import("//build/config/linux/pkg_config.gni") 6 import("//build/config/linux/pkg_config.gni")
7 import("//build/config/ui.gni") 7 import("//build/config/ui.gni")
8 8
9 # The GYP build supports system harfbuzz for non-official builds when using 9 # The GYP build supports system harfbuzz for non-official builds when using
10 # pangoft2 1.31.0 or greater (which pulls it in). 10 # pangoft2 1.31.0 or greater (which pulls it in).
(...skipping 23 matching lines...) Expand all
34 packages = [ "harfbuzz" ] 34 packages = [ "harfbuzz" ]
35 } 35 }
36 group("harfbuzz-ng") { 36 group("harfbuzz-ng") {
37 public_configs = [ ":harfbuzz_pkgconfig" ] 37 public_configs = [ ":harfbuzz_pkgconfig" ]
38 } 38 }
39 } else { 39 } else {
40 config("harfbuzz-ng_config") { 40 config("harfbuzz-ng_config") {
41 include_dirs = [ "src" ] 41 include_dirs = [ "src" ]
42 } 42 }
43 43
44 config("harfbuzz_warnings") {
45 cflags = []
46 if (is_clang) {
47 cflags += [
48 "-Wno-unused-value",
49
50 # Harfbuzz uses unused typedefs for its static asserts (and its
51 # static asserts are strange enough that they can't be replaced
52 # by static_assert).
53 "-Wno-unused-local-typedef",
54 ]
55 }
56 if (is_win) {
57 # Result of 32-bit shift implicitly converted to 64 bits.
58 cflags += [ "/wd4334" ]
59 }
60 }
61
62 # See also chrome/browser/ui/libgtk2ui/BUILD.gn which pulls this.
63 config("pangoft2_link_hack") {
64 if (is_linux && use_pango && !is_chromeos && !is_official_build &&
65 current_cpu != "arm" && current_cpu != "mipsel" &&
66 !is_component_build) {
67 # These symbols are referenced from libpangoft2, which will be
68 # dynamically linked later.
69 ldflags =
70 [ "-Wl,-uhb_ft_face_create_cached,-uhb_glib_get_unicode_funcs" ]
71 }
72 }
73
44 static_library("harfbuzz-ng") { 74 static_library("harfbuzz-ng") {
45 sources = [ 75 sources = [
46 "src/hb-atomic-private.hh", 76 "src/hb-atomic-private.hh",
47 "src/hb-blob.cc", 77 "src/hb-blob.cc",
48 "src/hb-blob.h", 78 "src/hb-blob.h",
49 "src/hb-buffer-deserialize-json.hh", 79 "src/hb-buffer-deserialize-json.hh",
50 "src/hb-buffer-deserialize-text.hh", 80 "src/hb-buffer-deserialize-text.hh",
51 "src/hb-buffer-private.hh", 81 "src/hb-buffer-private.hh",
52 "src/hb-buffer-serialize.cc", 82 "src/hb-buffer-serialize.cc",
53 "src/hb-buffer.cc", 83 "src/hb-buffer.cc",
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
139 ] 169 ]
140 170
141 defines = [ 171 defines = [
142 "HAVE_OT", 172 "HAVE_OT",
143 "HAVE_ICU", 173 "HAVE_ICU",
144 "HAVE_ICU_BUILTIN", 174 "HAVE_ICU_BUILTIN",
145 "HB_NO_MT", 175 "HB_NO_MT",
146 ] 176 ]
147 177
148 configs -= [ "//build/config/compiler:chromium_code" ] 178 configs -= [ "//build/config/compiler:chromium_code" ]
149 configs += [ "//build/config/compiler:no_chromium_code" ] 179 configs += [
150 180 ":harfbuzz_warnings",
Nico 2015/09/01 18:27:47 Not lgtm, this breaks things. ":harfbuzz_warnings"
Dirk Pranke 2015/09/01 18:38:38 I'm guessing that if we change this to: configs -
Nico 2015/09/01 18:42:00 Yes. (FWIW, the "usually with the assumption that
151 config("harfbuzz_warnings") { 181 "//build/config/compiler:no_chromium_code",
152 cflags = [] 182 ]
153 if (is_clang) {
154 cflags += [
155 "-Wno-unused-value",
156
157 # Harfbuzz uses unused typedefs for its static asserts (and its
158 # static asserts are strange enough that they can't be replaced
159 # by static_assert).
160 "-Wno-unused-local-typedef",
161 ]
162 }
163 if (is_win) {
164 cflags += [ "/wd4334" ] # Result of 32-bit shift implicitly converted t o 64 bits.
165 }
166 }
167 configs += [ ":harfbuzz_warnings" ]
168
169 public_configs = [ ":harfbuzz-ng_config" ] 183 public_configs = [ ":harfbuzz-ng_config" ]
170 184
171 deps = [ 185 deps = [
172 "//third_party/icu:icuuc", 186 "//third_party/icu:icuuc",
173 ] 187 ]
174 188
175 if (is_mac) { 189 if (is_mac) {
176 sources += [ 190 sources += [
177 "src/hb-coretext.cc", 191 "src/hb-coretext.cc",
178 "src/hb-coretext.h", 192 "src/hb-coretext.h",
(...skipping 13 matching lines...) Expand all
192 "//build/config/linux:glib", 206 "//build/config/linux:glib",
193 ] 207 ]
194 sources += [ 208 sources += [
195 "src/hb-ft.cc", 209 "src/hb-ft.cc",
196 "src/hb-ft.h", 210 "src/hb-ft.h",
197 "src/hb-glib.cc", 211 "src/hb-glib.cc",
198 "src/hb-glib.h", 212 "src/hb-glib.h",
199 ] 213 ]
200 } 214 }
201 215
202 # See also chrome/browser/ui/libgtk2ui/BUILD.gn which pulls this.
203 config("pangoft2_link_hack") {
204 if (is_linux && use_pango && !is_chromeos && !is_official_build &&
205 current_cpu != "arm" && current_cpu != "mipsel" &&
206 !is_component_build) {
207 # These symbols are referenced from libpangoft2, which will be
208 # dynamically linked later.
209 ldflags =
210 [ "-Wl,-uhb_ft_face_create_cached,-uhb_glib_get_unicode_funcs" ]
211 }
212 }
213 } 216 }
214 } 217 }
OLDNEW
« no previous file with comments | « third_party/cld_2/BUILD.gn ('k') | third_party/hunspell/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698