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/linux/pkg_config.gni") | 5 import("//build/config/linux/pkg_config.gni") |
6 import("//build/config/features.gni") | 6 import("//build/config/features.gni") |
7 import("//build/config/sysroot.gni") | 7 import("//build/config/sysroot.gni") |
8 import("//build/config/ui.gni") | 8 import("//build/config/ui.gni") |
9 import("//tools/generate_library_loader/generate_library_loader.gni") | 9 import("//tools/generate_library_loader/generate_library_loader.gni") |
10 | 10 |
11 gypi_values = exec_script( | 11 gypi_values = exec_script("//build/gypi_to_gn.py", |
12 "//build/gypi_to_gn.py", | 12 [ rebase_path("../../linux/system.gyp") ], |
13 [ rebase_path("../../linux/system.gyp") ], | 13 "scope", |
14 "scope", | 14 [ "../../linux/system.gyp" ]) |
15 [ "../../linux/system.gyp" ]) | |
16 | 15 |
17 config("sdk") { | 16 config("sdk") { |
18 if (sysroot != "") { | 17 if (sysroot != "") { |
19 cflags = [ "--sysroot=" + sysroot ] | 18 cflags = [ "--sysroot=" + sysroot ] |
20 ldflags = [ "--sysroot=" + sysroot ] | 19 ldflags = [ "--sysroot=" + sysroot ] |
21 | 20 |
22 # Need to get some linker flags out of the sysroot. | 21 # Need to get some linker flags out of the sysroot. |
23 ldflags += [ exec_script("sysroot_ld_path.py", | 22 ldflags += [ exec_script("sysroot_ld_path.py", |
24 [ rebase_path("//build/linux/sysroot_ld_path.sh", root_build_dir), | 23 [ |
25 sysroot ], | 24 rebase_path("//build/linux/sysroot_ld_path.sh", |
26 "value") ] | 25 root_build_dir), |
| 26 sysroot, |
| 27 ], |
| 28 "value") ] |
27 } | 29 } |
28 | 30 |
29 # Set here because OS_CHROMEOS cannot be autodetected in build_config.h like | 31 # Set here because OS_CHROMEOS cannot be autodetected in build_config.h like |
30 # OS_LINUX and the like. | 32 # OS_LINUX and the like. |
31 if (is_chromeos) { | 33 if (is_chromeos) { |
32 defines = [ "OS_CHROMEOS" ] | 34 defines = [ "OS_CHROMEOS" ] |
33 } | 35 } |
34 } | 36 } |
35 | 37 |
36 config("fontconfig") { | 38 config("fontconfig") { |
37 libs = [ "fontconfig" ] | 39 libs = [ "fontconfig" ] |
38 } | 40 } |
39 | 41 |
40 pkg_config("freetype2") { | 42 pkg_config("freetype2") { |
41 packages = [ "freetype2" ] | 43 packages = [ "freetype2" ] |
42 } | 44 } |
43 | 45 |
44 pkg_config("glib") { | 46 pkg_config("glib") { |
45 packages = [ "glib-2.0", "gmodule-2.0", "gobject-2.0", "gthread-2.0" ] | 47 packages = [ |
| 48 "glib-2.0", |
| 49 "gmodule-2.0", |
| 50 "gobject-2.0", |
| 51 "gthread-2.0", |
| 52 ] |
46 } | 53 } |
47 | 54 |
48 pkg_config("pangocairo") { | 55 pkg_config("pangocairo") { |
49 packages = [ "pangocairo" ] | 56 packages = [ "pangocairo" ] |
50 } | 57 } |
51 | 58 |
52 pkg_config("pangoft2") { | 59 pkg_config("pangoft2") { |
53 packages = [ "pangoft2" ] | 60 packages = [ "pangoft2" ] |
54 } | 61 } |
55 | 62 |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
141 output_cc = "libbrlapi_loader.cc" | 148 output_cc = "libbrlapi_loader.cc" |
142 header = "<brlapi.h>" | 149 header = "<brlapi.h>" |
143 config = ":brlapi_config" | 150 config = ":brlapi_config" |
144 | 151 |
145 functions = gypi_values.libbrlapi_functions | 152 functions = gypi_values.libbrlapi_functions |
146 } | 153 } |
147 } | 154 } |
148 | 155 |
149 pkg_config("gio_config") { | 156 pkg_config("gio_config") { |
150 packages = [ "gio-2.0" ] | 157 packages = [ "gio-2.0" ] |
| 158 |
151 # glib >=2.40 deprecate g_settings_list_schemas in favor of | 159 # glib >=2.40 deprecate g_settings_list_schemas in favor of |
152 # g_settings_schema_source_list_schemas. This function is not available on | 160 # g_settings_schema_source_list_schemas. This function is not available on |
153 # earlier versions that we still need to support (specifically, 2.32), so | 161 # earlier versions that we still need to support (specifically, 2.32), so |
154 # disable the warning with the GLIB_DISABLE_DEPRECATION_WARNINGS define. | 162 # disable the warning with the GLIB_DISABLE_DEPRECATION_WARNINGS define. |
155 # TODO(mgiuca): Remove this suppression when we drop support for Ubuntu 13.10 | 163 # TODO(mgiuca): Remove this suppression when we drop support for Ubuntu 13.10 |
156 # (saucy) and earlier. Update the code to use | 164 # (saucy) and earlier. Update the code to use |
157 # g_settings_schema_source_list_schemas instead. | 165 # g_settings_schema_source_list_schemas instead. |
158 defines = [ "USE_GIO", "GLIB_DISABLE_DEPRECATION_WARNINGS" ] | 166 defines = [ |
| 167 "USE_GIO", |
| 168 "GLIB_DISABLE_DEPRECATION_WARNINGS", |
| 169 ] |
159 | 170 |
160 # TODO(brettw) Theoretically I think ignore_libs should be set so that we | 171 # TODO(brettw) Theoretically I think ignore_libs should be set so that we |
161 # don't link directly to GIO and use the loader generated below. But the gio | 172 # don't link directly to GIO and use the loader generated below. But the gio |
162 # target in GYP doesn't make any sense to me and appears to link directly to | 173 # target in GYP doesn't make any sense to me and appears to link directly to |
163 # GIO in addition to making a loader. This this uncommented, the link in | 174 # GIO in addition to making a loader. This this uncommented, the link in |
164 # component build fails, so I think this is closer to the GYP build. | 175 # component build fails, so I think this is closer to the GYP build. |
165 #ignore_libs = true # Loader generated below. | 176 #ignore_libs = true # Loader generated below. |
166 } | 177 } |
167 | 178 |
168 # This generates a target named "gio". | 179 # This generates a target named "gio". |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
207 | 218 |
208 functions = gypi_values.libudev_functions | 219 functions = gypi_values.libudev_functions |
209 } | 220 } |
210 | 221 |
211 group("udev") { | 222 group("udev") { |
212 deps = [ | 223 deps = [ |
213 ":udev0_loader", | 224 ":udev0_loader", |
214 ":udev1_loader", | 225 ":udev1_loader", |
215 ] | 226 ] |
216 } | 227 } |
OLD | NEW |