blob: 57c3d09690601da7443b410789821245957509d0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
|
# Copyright 2015 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//chrome/version.gni")
if (is_ios) {
declare_args() {
# Path to the file used to override the version PATH level on iOS.
# Default to ios/build/util/VERSION.
ios_extra_version_path = "//ios/build/util/VERSION"
# Controls whether the extra version path should be overridden to
# use ios/build/util/CANARY_VERSION (legacy until the bots have
# been updated to override ios_extra_version_path instead).
# TODO(sdefresne): remove once http://crbug.com/514560 is fixed.
use_canary_version_file = false
}
}
source_set("version_info") {
sources = [
"version_info.cc",
"version_info.h",
]
deps = [
"//base",
"//components/strings",
"//ui/base",
":generate_version_info",
]
}
process_version("generate_version_info") {
visibility = [ ":version_info" ]
template_file = "version_info_values.h.version"
output = "$target_gen_dir/version_info_values.h"
if (is_ios) {
if (use_canary_version_file) {
extra_version_path = "//ios/build/util/CANARY_VERSION"
} else {
extra_version_path = ios_extra_version_path
}
# iOS overrides PATCH level of the version with the value from the file
# named by ios_version_path, however, this needs to be the last argument
# to the version.py script, so it cannot be added to the source variable
# and instead need to be managed manually.
inputs += [ extra_version_path ]
extra_args = [
"-f",
rebase_path(extra_version_path, root_build_dir),
]
}
}
|