| OLD | NEW |
| 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 assert(is_linux, "This file should only be referenced on Linux") | 5 assert(is_linux, "This file should only be referenced on Linux") |
| 6 | 6 |
| 7 import("//build/config/features.gni") | 7 import("//build/config/features.gni") |
| 8 import("//build/config/linux/pkg_config.gni") | 8 import("//build/config/linux/pkg_config.gni") |
| 9 | 9 |
| 10 pkg_config("gtk") { | 10 pkg_config("gtk") { |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 "x11_input_method_context_impl_gtk2.cc", | 65 "x11_input_method_context_impl_gtk2.cc", |
| 66 "x11_input_method_context_impl_gtk2.h", | 66 "x11_input_method_context_impl_gtk2.h", |
| 67 ] | 67 ] |
| 68 | 68 |
| 69 if (use_gconf) { | 69 if (use_gconf) { |
| 70 sources += [ | 70 sources += [ |
| 71 "gconf_listener.cc", | 71 "gconf_listener.cc", |
| 72 "gconf_listener.h", | 72 "gconf_listener.h", |
| 73 ] | 73 ] |
| 74 } | 74 } |
| 75 if (is_clang) { | |
| 76 # G_DEFINE_TYPE automatically generates a *get_instance_private inline | |
| 77 # function after glib 2.37. That's unused. Prevent to complain about it. | |
| 78 cflags = [ "-Wno-unused-function" ] | |
| 79 } | |
| 80 | |
| 81 defines = [ "LIBGTK2UI_IMPLEMENTATION" ] | 75 defines = [ "LIBGTK2UI_IMPLEMENTATION" ] |
| 82 | 76 |
| 83 configs += [ | 77 configs += [ |
| 84 ":gtk", | 78 ":gtk", |
| 85 ":gtkprint", | 79 ":gtkprint", |
| 86 "//build/config/linux:gconf", | 80 "//build/config/linux:gconf", |
| 87 "//printing:cups", | 81 "//printing:cups", |
| 88 ] | 82 ] |
| 89 | 83 |
| 84 # gn orders flags on a target before flags from configs. The default config |
| 85 # adds -Wall, and these flags have to be after -Wall -- so they need to come |
| 86 # from a config and can't be on the target directly. |
| 87 config("libgtk2ui_warnings") { |
| 88 if (is_clang) { |
| 89 cflags = [ |
| 90 # G_DEFINE_TYPE automatically generates a *get_instance_private inline |
| 91 # function after glib 2.37. That's unused. Prevent to complain about it. |
| 92 "-Wno-unused-function", |
| 93 |
| 94 # G_STATIC_ASSERT uses a typedef as a static_assert. |
| 95 "-Wno-unused-local-typedef", |
| 96 ] |
| 97 } |
| 98 } |
| 99 configs += [ ":libgtk2ui_warnings", ] |
| 100 |
| 90 deps = [ | 101 deps = [ |
| 91 "//base", | 102 "//base", |
| 92 "//base:i18n", | 103 "//base:i18n", |
| 93 "//base/third_party/dynamic_annotations", | 104 "//base/third_party/dynamic_annotations", |
| 94 "//chrome/app/theme:theme_resources", | 105 "//chrome/app/theme:theme_resources", |
| 95 "//chrome:extra_resources", | 106 "//chrome:extra_resources", |
| 96 "//chrome:resources", | 107 "//chrome:resources", |
| 97 "//chrome:strings", | 108 "//chrome:strings", |
| 98 "//components/resources", | 109 "//components/resources", |
| 99 "//skia", | 110 "//skia", |
| 100 "//ui/base", | 111 "//ui/base", |
| 101 "//ui/resources", | 112 "//ui/resources", |
| 102 "//ui/strings", | 113 "//ui/strings", |
| 103 "//ui/views", | 114 "//ui/views", |
| 104 ] | 115 ] |
| 105 } | 116 } |
| OLD | NEW |