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

Unified Diff: components/policy/BUILD.gn

Issue 2083903005: Adds gn config for policy_templates.zip (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix trybot failure Created 4 years, 6 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 | « BUILD.gn ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/policy/BUILD.gn
diff --git a/components/policy/BUILD.gn b/components/policy/BUILD.gn
index bd3728ea5bd703a463c3da8fe2661a4124a5e053..5afd5bcbbc2ef57a8c277530b822722c38130386 100644
--- a/components/policy/BUILD.gn
+++ b/components/policy/BUILD.gn
@@ -133,8 +133,9 @@ if (enable_configuration_policy) {
]
}
+ policy_templates_grd_file = "resources/policy_templates.grd"
grit("policy_templates") {
- source = "resources/policy_templates.grd"
+ source = policy_templates_grd_file
use_qualified_include = true
output_dir = "$root_gen_dir/chrome"
outputs = policy_templates_doc_outputs
@@ -394,4 +395,50 @@ if (enable_configuration_policy) {
]
}
}
+
+ if (is_win) {
+ version_file = "VERSION"
+ version_path = "$policy_templates_base_dir/$version_file"
+
+ copy("add_version") {
+ sources = [
+ "//chrome/VERSION",
+ ]
+ outputs = [
+ version_path,
+ ]
+ }
+
+ action("pack_policy_templates") {
+ output_zip_file = "$root_out_dir/policy_templates.zip"
+ script = "tools/make_policy_zip.py"
+ inputs =
+ [
+ version_path,
+ policy_templates_grd_file,
+ grit_info_script,
+ ] + policy_templates_windows_outputs + policy_templates_doc_outputs
+ outputs = [
+ output_zip_file,
+ ]
+ args = [
+ "--output",
+ rebase_path(output_zip_file, root_build_dir),
+ "--basedir",
+ rebase_path(policy_templates_base_dir, root_build_dir),
+ "--grd_input",
+ rebase_path(policy_templates_grd_file, root_build_dir),
+ "--grd_strip_path_prefix",
+ "app/policy",
+ "--extra_input",
+ version_file,
+ "--grit_info",
+ rebase_path(grit_info_script, root_build_dir),
+ ] + grit_defines
+ deps = [
+ ":add_version",
+ ":policy_templates",
+ ]
+ }
+ }
}
« no previous file with comments | « BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698