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
3 # found in the LICENSE file.
5 import("//chrome/version.gni")
9 # Path to the file used to override the version PATH level on iOS.
10 # Default to ios/build/util/VERSION.
11 ios_extra_version_path = "//ios/build/util/VERSION"
13 # Controls whether the extra version path should be overridden to
14 # use ios/build/util/CANARY_VERSION (legacy until the bots have
15 # been updated to override ios_extra_version_path instead).
16 # TODO(sdefresne): remove once http://crbug.com/514560 is fixed.
17 use_canary_version_file = false
21 source_set("version_info") {
29 "//components/strings",
31 ":generate_version_info",
35 process_version("generate_version_info") {
36 visibility = [ ":version_info" ]
37 template_file = "version_info_values.h.version"
38 output = "$target_gen_dir/version_info_values.h"
41 if (use_canary_version_file) {
42 extra_version_path = "//ios/build/util/CANARY_VERSION"
44 extra_version_path = ios_extra_version_path
47 # iOS overrides PATCH level of the version with the value from the file
48 # named by ios_version_path, however, this needs to be the last argument
49 # to the version.py script, so it cannot be added to the source variable
50 # and instead need to be managed manually.
52 inputs += [ extra_version_path ]
55 rebase_path(extra_version_path, root_build_dir),