Update To 11.40.268.0
[platform/framework/web/crosswalk.git] / src / chrome / browser / ui / libgtk2ui / BUILD.gn
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
3 # found in the LICENSE file.
4
5 assert(is_linux, "This file should only be referenced on Linux")
6
7 import("//build/config/features.gni")
8 import("//build/config/linux/pkg_config.gni")
9
10 pkg_config("gtk") {
11   # Gtk requires gmodule, but it does not list it as a dependency in some
12   # misconfigured systems.
13   packages = [ "gmodule-2.0", "gtk+-2.0", "gthread-2.0" ]
14 }
15
16 pkg_config("gtkprint") {
17   packages = [ "gtk+-unix-print-2.0" ]
18 }
19
20 component("libgtk2ui") {
21   sources = [
22     "app_indicator_icon.cc",
23     "app_indicator_icon.h",
24     "app_indicator_icon_menu.cc",
25     "app_indicator_icon_menu.h",
26     "chrome_gtk_frame.cc",
27     "chrome_gtk_frame.h",
28     "chrome_gtk_menu_subclasses.cc",
29     "chrome_gtk_menu_subclasses.h",
30     "g_object_destructor_filo.cc",
31     "g_object_destructor_filo.h",
32     "gtk2_border.cc",
33     "gtk2_border.h",
34     "gtk2_event_loop.cc",
35     "gtk2_event_loop.h",
36     "gtk2_key_bindings_handler.cc",
37     "gtk2_key_bindings_handler.h",
38     "gtk2_signal_registrar.cc",
39     "gtk2_signal_registrar.h",
40     "gtk2_status_icon.cc",
41     "gtk2_status_icon.h",
42     "gtk2_ui.cc",
43     "gtk2_ui.h",
44     "gtk2_util.cc",
45     "gtk2_util.h",
46     "libgtk2ui_export.h",
47     "menu_util.cc",
48     "menu_util.h",
49     "native_theme_gtk2.cc",
50     "native_theme_gtk2.h",
51     "owned_widget_gtk2.cc",
52     "owned_widget_gtk2.h",
53     "print_dialog_gtk2.cc",
54     "print_dialog_gtk2.h",
55     "printing_gtk2_util.cc",
56     "printing_gtk2_util.h",
57     "select_file_dialog_impl.cc",
58     "select_file_dialog_impl.h",
59     "select_file_dialog_impl_gtk2.cc",
60     "select_file_dialog_impl_kde.cc",
61     "skia_utils_gtk2.cc",
62     "skia_utils_gtk2.h",
63     "unity_service.cc",
64     "unity_service.h",
65     "x11_input_method_context_impl_gtk2.cc",
66     "x11_input_method_context_impl_gtk2.h",
67   ]
68
69   if (use_gconf) {
70     sources += [
71       "gconf_listener.cc",
72       "gconf_listener.h",
73     ]
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" ]
82
83   configs += [
84     ":gtk",
85     ":gtkprint",
86     "//build/config/linux:gconf",
87     "//printing:cups",
88   ]
89
90   deps = [
91     "//base",
92     "//base:i18n",
93     "//base/third_party/dynamic_annotations",
94     "//chrome/app/theme:theme_resources",
95     "//chrome:extra_resources",
96     "//chrome:resources",
97     "//chrome:strings",
98     "//components/resources",
99     "//skia",
100     "//ui/base",
101     "//ui/resources",
102     "//ui/strings",
103     "//ui/views",
104   ]
105 }