Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 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 | |
| 3 # found in the LICENSE file. | |
| 4 | |
| 5 # This exposes the Chrome branding as GN variables for use in build files. | |
| 6 # | |
| 7 # PREFER NOT TO USE THESE. The GYP build uses this kind of thing extensively. | |
|
Robert Sesek
2016/04/29 16:45:53
I know this is not ideal, but the bundle packaging
| |
| 8 # However, it is far better to write an action to generate a file at | |
| 9 # build-time with the information you need. This allows better dependency | |
| 10 # checking and GN will run faster. | |
| 11 # | |
| 12 # These values should only be used if you REALLY need to depend on them at | |
| 13 # build-time, for example, in the computation of output file names. | |
| 14 | |
| 15 import("//build/config/chrome_build.gni") | |
| 16 | |
| 17 _branding_file = "//chrome/app/theme/$branding_path_component/BRANDING" | |
| 18 _result = exec_script("version.py", | |
| 19 [ | |
| 20 "-f", | |
| 21 rebase_path(_branding_file, root_build_dir), | |
| 22 "-t", | |
| 23 "@PRODUCT_FULLNAME@", | |
| 24 ], | |
| 25 "trim string", | |
| 26 [ _branding_file ]) | |
| 27 | |
| 28 chrome_product_full_name = _result | |
| OLD | NEW |