| OLD | NEW |
| 1 # Copyright 2014 PDFium Authors. All rights reserved. | 1 # Copyright 2014 PDFium 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("../pdfium.gni") | 5 import("../pdfium.gni") |
| 6 | 6 |
| 7 group("samples") { | 7 group("samples") { |
| 8 testonly = true | 8 testonly = true |
| 9 deps = [ | 9 deps = [ |
| 10 ":pdfium_test", | 10 ":pdfium_test", |
| 11 ":pdfium_diff", |
| 11 ] | 12 ] |
| 12 } | 13 } |
| 13 | 14 |
| 14 config("pdfium_samples_config") { | 15 config("pdfium_samples_config") { |
| 15 defines = [ | 16 defines = [ |
| 16 "PNG_PREFIX", | 17 "PNG_PREFIX", |
| 17 "PNGPREFIX_H", | 18 "PNGPREFIX_H", |
| 18 "PNG_USE_READ_MACROS", | 19 "PNG_USE_READ_MACROS", |
| 19 ] | 20 ] |
| 21 include_dirs = [ ".." ] |
| 20 if (pdf_enable_v8) { | 22 if (pdf_enable_v8) { |
| 21 defines += [ "PDF_ENABLE_V8", ] | 23 defines += [ "PDF_ENABLE_V8", ] |
| 22 } | 24 } |
| 23 if (pdf_enable_xfa) { | 25 if (pdf_enable_xfa) { |
| 24 defines += [ "PDF_ENABLE_XFA", ] | 26 defines += [ "PDF_ENABLE_XFA", ] |
| 25 } | 27 } |
| 26 } | 28 } |
| 27 | 29 |
| 28 executable("pdfium_test") { | 30 executable("pdfium_test") { |
| 29 testonly = true | 31 testonly = true |
| 30 sources = [ | 32 sources = [ |
| 31 "image_diff_png.cc", | 33 "image_diff_png.cc", |
| 32 "pdfium_test.cc", | 34 "pdfium_test.cc", |
| 33 ] | 35 ] |
| 34 deps = [ | 36 deps = [ |
| 35 "//third_party/pdfium:pdfium", | 37 "//third_party/pdfium:pdfium", |
| 36 "//third_party/pdfium:test_support", | 38 "//third_party/pdfium:test_support", |
| 39 |
| 40 # Regardless of whether the library ships against system freetype, |
| 41 # always link this binary against the bundled one for consistency |
| 42 # of results across platforms. |
| 43 "//third_party/pdfium/third_party:fx_freetype", |
| 37 ] | 44 ] |
| 38 if (pdf_enable_v8) { | 45 if (pdf_enable_v8) { |
| 39 deps += [ | 46 deps += [ "//v8:v8_libplatform" ] |
| 40 "//v8:v8_libplatform", | |
| 41 ] | |
| 42 include_dirs = [ | 47 include_dirs = [ |
| 43 "//v8", | 48 "//v8", |
| 44 "//v8/include", | 49 "//v8/include", |
| 45 ] | 50 ] |
| 46 } | 51 } |
| 47 configs += [ ":pdfium_samples_config" ] | 52 configs += [ ":pdfium_samples_config" ] |
| 48 } | 53 } |
| 49 | 54 |
| 50 executable("pdfium_diff") { | 55 executable("pdfium_diff") { |
| 51 testonly = true | 56 testonly = true |
| 52 sources = [ | 57 sources = [ |
| 53 "image_diff.cc", | 58 "image_diff.cc", |
| 54 "image_diff_png.cc", | 59 "image_diff_png.cc", |
| 55 "image_diff_png.h", | 60 "image_diff_png.h", |
| 56 ] | 61 ] |
| 57 deps = [ | 62 deps = [ |
| 58 "//third_party/pdfium", | 63 "//third_party/pdfium", |
| 59 ] | 64 ] |
| 60 configs += [ ":pdfium_samples_config" ] | 65 configs -= [ "//build/config/compiler:chromium_code" ] |
| 66 configs += [ |
| 67 ":pdfium_samples_config", |
| 68 "//build/config/compiler:no_chromium_code", |
| 69 ] |
| 61 } | 70 } |
| OLD | NEW |