OLD | NEW |
1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 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/util/process_version.gni") | 6 import("//build/util/process_version.gni") |
7 import("//chrome/process_version_rc_template.gni") # For branding_file_path. | 7 import("//chrome/process_version_rc_template.gni") # For branding_file_path. |
8 | 8 |
9 declare_args() { | 9 declare_args() { |
10 use_unofficial_version_number = !is_chrome_branded | 10 use_unofficial_version_number = !is_chrome_branded |
11 } | 11 } |
12 | 12 |
13 static_library("version_info") { | 13 static_library("version_info") { |
14 sources = [ | 14 sources = [ |
15 "version_info.cc", | 15 "version_info.cc", |
16 "version_info.h", | 16 "version_info.h", |
17 ] | 17 ] |
18 | 18 |
19 deps = [ | 19 deps = [ |
20 ":generate_version_info", | 20 ":generate_version_info", |
21 "//base", | 21 "//base", |
22 "//components/strings", | 22 "//components/strings", |
23 ] | 23 ] |
24 | 24 |
| 25 public_deps = [ |
| 26 ":channel", |
| 27 ] |
| 28 |
25 if (use_unofficial_version_number) { | 29 if (use_unofficial_version_number) { |
26 defines = [ "USE_UNOFFICIAL_VERSION_NUMBER" ] | 30 defines = [ "USE_UNOFFICIAL_VERSION_NUMBER" ] |
27 deps += [ "//ui/base" ] | 31 deps += [ "//ui/base" ] |
28 } | 32 } |
29 } | 33 } |
30 | 34 |
| 35 source_set("channel") { |
| 36 sources = [ |
| 37 "channel.h", |
| 38 ] |
| 39 } |
| 40 |
31 process_version("generate_version_info") { | 41 process_version("generate_version_info") { |
32 template_file = "version_info_values.h.version" | 42 template_file = "version_info_values.h.version" |
33 sources = [ | 43 sources = [ |
34 "//build/util/LASTCHANGE", | 44 "//build/util/LASTCHANGE", |
35 "//chrome/VERSION", | 45 "//chrome/VERSION", |
36 branding_file_path, | 46 branding_file_path, |
37 ] | 47 ] |
38 output = "$target_gen_dir/version_info_values.h" | 48 output = "$target_gen_dir/version_info_values.h" |
39 } | 49 } |
OLD | NEW |