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

Unified Diff: remoting/tools/build/message_compiler.gni

Issue 969173002: Add remoting and PPAPI tests to GN build (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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 | « remoting/resources/BUILD.gn ('k') | remoting/tools/build/message_compiler.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/tools/build/message_compiler.gni
diff --git a/remoting/tools/build/message_compiler.gni b/remoting/tools/build/message_compiler.gni
new file mode 100644
index 0000000000000000000000000000000000000000..9c7fdd1a04765815e659708dab2286d827d523f7
--- /dev/null
+++ b/remoting/tools/build/message_compiler.gni
@@ -0,0 +1,51 @@
+# Copyright 2015 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.
+
+assert(is_win, "This only runs on Windows.")
+
+# Runs mc.exe over a list of sources.
+#
+# sources
+# List of .mc files to process.
+template("message_compiler") {
+ action_name = "${target_name}_mc"
+ source_set_name = target_name
+
+ action_foreach(action_name) {
+ visibility = [ ":$source_set_name" ]
+ script = "//remoting/tools/build/message_compiler.py"
+
+ sources = invoker.sources
+
+ outputs = [
+ "$target_gen_dir/{{source_name_part}}.h",
+ "$target_gen_dir/{{source_name_part}}.rc",
+ ]
+
+ args = [
+ # Where to put the header.
+ "-h",
+ rebase_path(target_gen_dir, root_build_dir),
+
+ # Where to put the .rc file.
+ "-r",
+ rebase_path(target_gen_dir, root_build_dir),
+
+ # Input is Unicode.
+ "-u",
+ "{{source}}",
+ ]
+
+ if (defined(invoker.deps)) {
+ deps = invoker.deps
+ }
+ }
+
+ source_set(source_set_name) {
+ sources = get_target_outputs(":$action_name")
+ deps = [
+ ":$action_name",
+ ]
+ }
+}
« no previous file with comments | « remoting/resources/BUILD.gn ('k') | remoting/tools/build/message_compiler.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698