| OLD | NEW |
| (Empty) | |
| 1 # Copyright 2015 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 import("//tools/grit/grit_rule.gni") |
| 6 |
| 7 closure_out_dir = "$root_gen_dir/closure/components/resources/enhanced_bookmarks
" |
| 8 |
| 9 # GYP version: components/resources/enhanced_bookmarks/enhanced_bookmarks_resour
ces.gyp |
| 10 # (generate_enhanced_bookmarks_resources action) |
| 11 grit("enhanced_bookmarks_resources") { |
| 12 source = "enhanced_bookmarks_resources.grd" |
| 13 |
| 14 outputs = [ |
| 15 "grit/enhanced_bookmarks_resources.h", |
| 16 "enhanced_bookmarks_resources.pak", |
| 17 ] |
| 18 output_dir = "$root_gen_dir/components/resources/enhanced_bookmarks" |
| 19 deps = [ |
| 20 "//components/resources/enhanced_bookmarks:document_image_extractor", |
| 21 "//components/resources/enhanced_bookmarks:dom_initializer", |
| 22 ] |
| 23 |
| 24 get_salient_image_url_gen_js = "${closure_out_dir}/get_salient_image_url.js" |
| 25 dom_initializer_gen_js = "${closure_out_dir}/dom_initializer.js" |
| 26 |
| 27 grit_flags = [ |
| 28 "-E", |
| 29 "get_salient_image_url_gen_js=" + |
| 30 rebase_path(get_salient_image_url_gen_js, root_build_dir), |
| 31 "-E", |
| 32 "dom_initializer_gen_js=" + |
| 33 rebase_path(dom_initializer_gen_js, root_build_dir), |
| 34 ] |
| 35 } |
| 36 |
| 37 # GYP version: components/resources/enhanced_bookmarks/enhanced_bookmarks.gypi |
| 38 import("//third_party/document_image_extractor/document_image_extractor.gni") |
| 39 |
| 40 rebased_closure_out_dir = rebase_path(root_gen_dir, "../") + |
| 41 "/closure/components/resources/enhanced_bookmarks/" |
| 42 |
| 43 action("document_image_extractor") { |
| 44 script = "//third_party/closure_compiler/compile.py" |
| 45 sources = [ |
| 46 "get_salient_image_url.js", |
| 47 ] |
| 48 outputs = [ |
| 49 "${closure_out_dir}/get_salient_image_url.js", |
| 50 ] |
| 51 |
| 52 document_image_extractor_sources = |
| 53 rebase_path(document_image_extractor_js_files, "third_party/", "../") |
| 54 |
| 55 args = |
| 56 [ "../../components/resources/enhanced_bookmarks/get_salient_image_url.
js" ] + |
| 57 document_image_extractor_sources + |
| 58 [ |
| 59 "--out_file=${rebased_closure_out_dir}/get_salient_image_url.js", |
| 60 "--no-single-file", |
| 61 "--output_wrapper", |
| 62 "(function(){%output% return GetSalientImageUrl();})();", |
| 63 ] |
| 64 } |
| 65 |
| 66 action("dom_initializer") { |
| 67 script = "//third_party/closure_compiler/compile.py" |
| 68 sources = [ |
| 69 "dom_initializer.js", |
| 70 ] |
| 71 outputs = [ |
| 72 "${closure_out_dir}/dom_initializer.js", |
| 73 ] |
| 74 |
| 75 dom_controller_sources = |
| 76 rebase_path(dom_controller_js_files, "third_party/", "../") |
| 77 |
| 78 args = |
| 79 [ "../../components/resources/enhanced_bookmarks/dom_initializer.js" ] + |
| 80 dom_controller_sources + |
| 81 [ |
| 82 "--out_file=${rebased_closure_out_dir}/dom_initializer.js", |
| 83 "--no-single-file", |
| 84 "--output_wrapper", |
| 85 "(function(){%output%})();", |
| 86 ] |
| 87 } |
| OLD | NEW |