OLD | NEW |
1 # Copyright 2016 The Chromium Authors. All rights reserved. | 1 # Copyright 2016 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/ui.gni") |
| 6 |
5 component("init") { | 7 component("init") { |
6 output_name = "gl_init" | 8 output_name = "gl_init" |
7 | 9 |
| 10 public = [ |
| 11 "gl_factory.h", |
| 12 ] |
| 13 |
8 sources = [ | 14 sources = [ |
9 "gl_factory.cc", | 15 "gl_factory.cc", |
10 "gl_factory.h", | |
11 "gl_init_export.h", | 16 "gl_init_export.h", |
| 17 "gl_initializer.h", |
12 ] | 18 ] |
13 defines = [ "GL_INIT_IMPLEMENTATION" ] | 19 defines = [ "GL_INIT_IMPLEMENTATION" ] |
14 | 20 |
15 deps = [ | 21 deps = [ |
16 "//base", | 22 "//base", |
17 "//ui/gfx", | 23 "//ui/gfx", |
18 ] | 24 ] |
19 | 25 |
20 public_deps = [ | 26 public_deps = [ |
21 "//ui/gl", | 27 "//ui/gl", |
22 ] | 28 ] |
| 29 |
| 30 if (is_android) { |
| 31 sources += [ "gl_initializer_android.cc" ] |
| 32 } else if (is_win) { |
| 33 sources += [ "gl_initializer_win.cc" ] |
| 34 } else if (is_mac) { |
| 35 sources += [ "gl_initializer_mac.cc" ] |
| 36 |
| 37 libs = [ "OpenGL.framework" ] |
| 38 } else if (use_x11) { |
| 39 sources += [ "gl_initializer_x11.cc" ] |
| 40 } else if (use_ozone) { |
| 41 sources += [ "gl_initializer_ozone.cc" ] |
| 42 } |
23 } | 43 } |
OLD | NEW |