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

Side by Side Diff: remoting/webapp/BUILD.gn

Issue 1312463005: Compile remoting client plugin with GN (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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 unified diff | Download patch
OLDNEW
1 # Copyright 2014 The Chromium Authors. All rights reserved. 1 # Copyright 2014 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 # Keep in sync with targets in remoting/remoting_client.gypi. 5 # Keep in sync with targets in remoting/remoting_client.gypi.
6 6
7 import("//build/config/features.gni") 7 import("//build/config/features.gni")
8 import("//remoting/webapp/build_template.gni") 8 import("//remoting/webapp/build_template.gni")
9 import("//remoting/webapp/files.gni") 9 import("//remoting/webapp/files.gni")
10 10
(...skipping 14 matching lines...) Expand all
25 args = [ 25 args = [
26 "credits", 26 "credits",
27 rebase_path(about_credits_file, root_build_dir), 27 rebase_path(about_credits_file, root_build_dir),
28 "--file-template", 28 "--file-template",
29 rebase_path("base/html/credits.tmpl", root_build_dir), 29 rebase_path("base/html/credits.tmpl", root_build_dir),
30 "--entry-template", 30 "--entry-template",
31 rebase_path("base/html/credits_entry.tmpl", root_build_dir), 31 rebase_path("base/html/credits_entry.tmpl", root_build_dir),
32 ] 32 ]
33 } 33 }
34 34
35 desktop_remoting_webapp("webapp") { 35 group("webapp") {
garykac 2015/08/31 23:27:10 Why expand this out as part of this CL? Previousl
Sergey Ulanov 2015/09/01 00:06:46 This was the only place where the desktop_remoting
garykac 2015/09/01 20:53:27 Even if we need to do this at some point, it doesn
Sergey Ulanov 2015/09/03 00:07:14 ok, returned the template back
36 webapp_type = "desktop" 36 locales_listfile_output = "$target_gen_dir/webapp_locales.txt"
37 output_dir = "$root_build_dir/remoting/remoting-webapp.v2" 37 build_locales_listfile("webapp_locales") {
38 zip_path = "$root_build_dir/remoting/remoting-webapp.v2.zip" 38 # Template uses locales_listfile_output from outer scope.
39 extra_files = [ 39 }
40 "crd/remoting_client_pnacl.nmf.jinja2", 40
41 # TODO(garykac): Get correct path to this. 41 background_html_output = "$target_gen_dir/html/webapp/background.html"
42 #"<(PRODUCT_DIR)/remoting_client_plugin_newlib.pexe", 42
43 build_webapp_html("webapp_background_html") {
44 html_template_file = remoting_webapp_template_background
45 html_template_include_files = []
46 js_files = remoting_webapp_background_html_all_js_files
47 html_output = background_html_output
48 }
49
50 message_window_html_output = "$target_gen_dir/html/webapp/message_window.html"
51
52 build_webapp_html("webapp_message_window_html") {
53 html_template_file = remoting_webapp_template_message_window
54 html_template_include_files = []
55 js_files = remoting_webapp_message_window_html_all_js_files
56 html_output = message_window_html_output
57 }
58
59 wcs_sandbox_html_output = "$target_gen_dir/html/webapp/wcs_sandbox.html"
60
61 build_webapp_html("webapp_wcs_sandbox_html") {
62 html_template_file = remoting_webapp_template_wcs_sandbox
63 html_template_include_files = []
64 js_files = remoting_webapp_wcs_sandbox_html_all_js_files
65 html_output = wcs_sandbox_html_output
66 }
67
68 main_html_output = "$target_gen_dir/html/webapp/main.html"
69
70 build_webapp_html("webapp_main_html") {
71 html_template_file = remoting_webapp_template_main
72 html_template_include_files = remoting_webapp_template_files
73 js_files = remoting_webapp_crd_main_html_all_js_files
74 html_output = main_html_output
75 }
76
77 action("build_webapp") {
78 script = "//remoting/webapp/build-webapp.py"
79
80 zip_path = "$root_build_dir/remoting/remoting-webapp.v2.zip"
81
82 dr_generated_html_files = [
83 background_html_output,
84 message_window_html_output,
85 wcs_sandbox_html_output,
86 main_html_output,
87 "$target_gen_dir/credits.html",
88 ]
89
90 pexe_dir = get_label_info(
91 "//remoting/client/plugin:remoting_client_plugin_newlib(//native_cli ent/build/toolchain/nacl:newlib_pnacl)",
92 "root_out_dir")
93 files_relative = [
94 "crd/manifest.json.jinja2",
95 "crd/remoting_client_pnacl.nmf.jinja2",
96 "$pexe_dir/remoting_client_plugin_newlib.pexe",
97 ] + dr_generated_html_files + remoting_webapp_crd_files
98 inputs = files_relative + remoting_version_files
99 files = rebase_path(files_relative, root_build_dir)
100
101 outputs = [
102 zip_path,
103 ]
104
105 deps = [
106 ":webapp_locales",
107 ":webapp_background_html",
108 ":webapp_message_window_html",
109 ":webapp_wcs_sandbox_html",
110 ":webapp_main_html",
111 "//remoting/resources",
112 "//remoting/webapp:credits",
113 "//remoting/client/plugin:remoting_client_plugin_newlib(//native_client/bu ild/toolchain/nacl:newlib_pnacl)",
114 ]
115
116 # Create a file that contains a list of all the resource files needed
117 # to build the webapp. This is needed to avoid problems on platforms that
118 # limit the size of a command line.
119 file_list = "$target_gen_dir/${target_name}_files.txt"
120 write_file(file_list, files)
121
122 args = [
123 buildtype,
124 chrome_version_full,
125 rebase_path("$root_build_dir/remoting/remoting-webapp.v2",
126 root_build_dir),
127 rebase_path(zip_path, root_build_dir),
128 rebase_path("crd/manifest.json.jinja2", root_build_dir),
129 "desktop",
130 "--files_listfile",
131 rebase_path(file_list, root_build_dir),
132 "--locales_listfile",
133 rebase_path(locales_listfile_output, root_build_dir),
134 "--use_gcd",
135 "$remoting_use_gcd",
136 ]
137 }
138
139 deps = [
140 ":build_webapp",
43 ] 141 ]
44 } 142 }
45 143
46 app_remoting_webapp("ar_sample_app") { 144 app_remoting_webapp("ar_sample_app") {
47 app_key = "Sample_App" 145 app_key = "Sample_App"
48 app_id = "ljacajndfccfgnfohlgkdphmbnpkjflk" 146 app_id = "ljacajndfccfgnfohlgkdphmbnpkjflk"
49 app_client_id = "sample_client_id" 147 app_client_id = "sample_client_id"
50 app_vendor = "" 148 app_vendor = ""
51 app_name = "sample_app" 149 app_name = "sample_app"
52 app_fullname = "App Remoting Client" 150 app_fullname = "App Remoting Client"
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 rebase_path(outputs, root_build_dir) + [ 235 rebase_path(outputs, root_build_dir) + [
138 rebase_path(remoting_webapp_unittests_template_main, root_build_dir), 236 rebase_path(remoting_webapp_unittests_template_main, root_build_dir),
139 "--exclude-js", 237 "--exclude-js",
140 ] + 238 ] +
141 rebase_path(remoting_webapp_unittests_exclude_js_files, root_build_dir) + 239 rebase_path(remoting_webapp_unittests_exclude_js_files, root_build_dir) +
142 [ 240 [
143 "--js-list-file", 241 "--js-list-file",
144 rebase_path(file_list, root_build_dir), 242 rebase_path(file_list, root_build_dir),
145 ] + [ "--instrument-js" ] + rebase_path(webapp_js_files, root_build_dir) 243 ] + [ "--instrument-js" ] + rebase_path(webapp_js_files, root_build_dir)
146 } 244 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698