OLD | NEW |
---|---|
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 import("//build/config/features.gni") | 5 import("//build/config/features.gni") |
6 import("//testing/test.gni") | 6 import("//testing/test.gni") |
7 import("//third_party/pdfium/pdfium.gni") | 7 import("//third_party/pdfium/pdfium.gni") |
8 | 8 |
9 assert(enable_pdf) | 9 assert(enable_pdf) |
10 | 10 |
11 pdf_engine = 0 # 0 PDFium | 11 pdf_engine = 0 # 0 PDFium |
12 | 12 |
13 static_library("pdf") { | 13 static_library("pdf") { |
14 deps = [ | 14 deps = [ |
15 "//base", | 15 "//base", |
16 "//gin", | 16 "//gin", |
17 "//net", | 17 "//net", |
18 "//ppapi/cpp:objects", | 18 "//ppapi/cpp:objects", |
19 "//ppapi/cpp/private:internal_module", | 19 "//ppapi/cpp/private:internal_module", |
20 "//ui/base", | 20 "//ui/base", |
21 "//ui/gfx/range", | |
21 ] | 22 ] |
22 | 23 |
23 sources = [ | 24 sources = [ |
24 "chunk_stream.cc", | |
25 "chunk_stream.h", | 25 "chunk_stream.h", |
26 "document_loader.cc", | 26 "document_loader.cc", |
27 "document_loader.h", | 27 "document_loader.h", |
28 "draw_utils.cc", | 28 "draw_utils.cc", |
29 "draw_utils.h", | 29 "draw_utils.h", |
30 "out_of_process_instance.cc", | 30 "out_of_process_instance.cc", |
31 "out_of_process_instance.h", | 31 "out_of_process_instance.h", |
32 "paint_aggregator.cc", | 32 "paint_aggregator.cc", |
33 "paint_aggregator.h", | 33 "paint_aggregator.h", |
34 "paint_manager.cc", | 34 "paint_manager.cc", |
35 "paint_manager.h", | 35 "paint_manager.h", |
36 "pdf.cc", | 36 "pdf.cc", |
37 "pdf.h", | 37 "pdf.h", |
38 "pdf_engine.h", | 38 "pdf_engine.h", |
39 "preview_mode_client.cc", | 39 "preview_mode_client.cc", |
40 "preview_mode_client.h", | 40 "preview_mode_client.h", |
41 "range_set.cc", | |
42 "range_set.h", | |
43 "timer.cc", | |
44 "timer.h", | |
45 "url_loader_wrapper.h", | |
46 "url_loader_wrapper_impl.cc", | |
47 "url_loader_wrapper_impl.h", | |
41 ] | 48 ] |
42 | 49 |
50 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations. | |
Lei Zhang
2016/10/31 18:52:34
I removed this in https://crrev.com/427947 - let's
snake
2016/10/31 19:08:28
Done.
| |
51 configs += [ "//build/config/compiler:no_size_t_to_int_warning" ] | |
52 | |
43 if (pdf_engine == 0) { | 53 if (pdf_engine == 0) { |
44 deps += [ | 54 deps += [ |
45 "//pdf/pdfium/fuzzers", | 55 "//pdf/pdfium/fuzzers", |
46 "//third_party/pdfium", | 56 "//third_party/pdfium", |
47 ] | 57 ] |
48 | 58 |
49 sources += [ | 59 sources += [ |
50 "pdfium/pdfium_api_string_buffer_adapter.cc", | 60 "pdfium/pdfium_api_string_buffer_adapter.cc", |
51 "pdfium/pdfium_api_string_buffer_adapter.h", | 61 "pdfium/pdfium_api_string_buffer_adapter.h", |
52 "pdfium/pdfium_assert_matching_enums.cc", | 62 "pdfium/pdfium_assert_matching_enums.cc", |
(...skipping 12 matching lines...) Expand all Loading... | |
65 | 75 |
66 defines = [ "PDFIUM_PRINT_TEXT_WITH_GDI" ] | 76 defines = [ "PDFIUM_PRINT_TEXT_WITH_GDI" ] |
67 if (pdf_enable_xfa) { | 77 if (pdf_enable_xfa) { |
68 defines += [ "PDF_ENABLE_XFA" ] | 78 defines += [ "PDF_ENABLE_XFA" ] |
69 } | 79 } |
70 } | 80 } |
71 | 81 |
72 test("pdf_unittests") { | 82 test("pdf_unittests") { |
73 sources = [ | 83 sources = [ |
74 "chunk_stream_unittest.cc", | 84 "chunk_stream_unittest.cc", |
85 "document_loader_unittest.cc", | |
86 "range_set_unittest.cc", | |
75 "run_all_unittests.cc", | 87 "run_all_unittests.cc", |
76 ] | 88 ] |
77 | 89 |
78 deps = [ | 90 deps = [ |
79 ":pdf", | 91 ":pdf", |
80 "//base", | 92 "//base", |
81 "//base/test:test_support", | 93 "//base/test:test_support", |
82 "//ppapi/c", | 94 "//ppapi/c", |
83 "//ppapi/cpp", | 95 "//ppapi/cpp", |
84 "//testing/gmock", | 96 "//testing/gmock", |
85 "//testing/gtest", | 97 "//testing/gtest", |
98 "//ui/gfx/range", | |
86 ] | 99 ] |
87 } | 100 } |
OLD | NEW |