Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2381)

Unified Diff: build/util/branding.gni

Issue 1930403003: [Mac/GN] Get chrome and chrome_framework building. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@gn-chrome-app-shim
Patch Set: Rebase Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « .gn ('k') | build/util/version.gni » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/util/branding.gni
diff --git a/build/util/branding.gni b/build/util/branding.gni
new file mode 100644
index 0000000000000000000000000000000000000000..b234b817c892b4da8a5c414eb15a51c7445bcb69
--- /dev/null
+++ b/build/util/branding.gni
@@ -0,0 +1,28 @@
+# Copyright 2016 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.
+
+# This exposes the Chrome branding as GN variables for use in build files.
+#
+# PREFER NOT TO USE THESE. The GYP build uses this kind of thing extensively.
+# However, it is far better to write an action to generate a file at
+# build-time with the information you need. This allows better dependency
+# checking and GN will run faster.
+#
+# These values should only be used if you REALLY need to depend on them at
+# build-time, for example, in the computation of output file names.
+
+import("//build/config/chrome_build.gni")
+
+_branding_file = "//chrome/app/theme/$branding_path_component/BRANDING"
+_result = exec_script("version.py",
+ [
+ "-f",
+ rebase_path(_branding_file, root_build_dir),
+ "-t",
+ "@PRODUCT_FULLNAME@",
+ ],
+ "trim string",
+ [ _branding_file ])
+
+chrome_product_full_name = _result
« no previous file with comments | « .gn ('k') | build/util/version.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698