| 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 # This exposes the Chrome version as GN variables for use in build files. | 5 # This exposes the Chrome version as GN variables for use in build files. |
| 6 # | 6 # |
| 7 # PREFER NOT TO USE THESE. The GYP build uses this kind of thing extensively. | 7 # PREFER NOT TO USE THESE. The GYP build uses this kind of thing extensively. |
| 8 # However, it is far better to write an action (or use the process_version | 8 # However, it is far better to write an action (or use the process_version |
| 9 # wrapper in chrome/version.gni) to generate a file at build-time with the | 9 # wrapper in build/util/version.gni) to generate a file at build-time with the |
| 10 # information you need. This allows better dependency checking and GN will | 10 # information you need. This allows better dependency checking and GN will |
| 11 # run faster. | 11 # run faster. |
| 12 # | 12 # |
| 13 # These values should only be used if you REALLY need to depend on them at | 13 # These values should only be used if you REALLY need to depend on them at |
| 14 # build-time, for example, in the computation of output file names. | 14 # build-time, for example, in the computation of output file names. |
| 15 | 15 |
| 16 # Give version.py a pattern that will expand to a GN scope consisting of | 16 # Give version.py a pattern that will expand to a GN scope consisting of |
| 17 # all values we need at once. | 17 # all values we need at once. |
| 18 _version_dictionary_template = "full = \"@MAJOR@.@MINOR@.@BUILD@.@PATCH@\" " + | 18 _version_dictionary_template = "full = \"@MAJOR@.@MINOR@.@BUILD@.@PATCH@\" " + |
| 19 "major = \"@MAJOR@\" minor = \"@MINOR@\" " + | 19 "major = \"@MAJOR@\" minor = \"@MINOR@\" " + |
| (...skipping 30 matching lines...) Expand all Loading... |
| 50 "@BUILD@.@PATCH_HI@.@PATCH_LO@", | 50 "@BUILD@.@PATCH_HI@.@PATCH_LO@", |
| 51 "-e", | 51 "-e", |
| 52 "PATCH_HI=int(PATCH)/256", | 52 "PATCH_HI=int(PATCH)/256", |
| 53 "-e", | 53 "-e", |
| 54 "PATCH_LO=int(PATCH)%256", | 54 "PATCH_LO=int(PATCH)%256", |
| 55 ], | 55 ], |
| 56 "trim string", | 56 "trim string", |
| 57 [ chrome_version_file ]) | 57 [ chrome_version_file ]) |
| 58 chrome_dylib_version = _result | 58 chrome_dylib_version = _result |
| 59 } | 59 } |
| OLD | NEW |