From 360edebb1889e16d5084f2a3081ffdcfc0f60efa Mon Sep 17 00:00:00 2001 From: Lei Zhang Date: Tue, 19 Dec 2017 18:06:35 +0000 Subject: Fix some nits in build configs. Mostly to sort build rules. Change-Id: I2ee4d24089f9e51b0a61b1f30b424f5f7aab7d0a Reviewed-on: https://pdfium-review.googlesource.com/21730 Reviewed-by: Henrique Nakashima Commit-Queue: Lei Zhang --- BUILD.gn | 16 ++++++++-------- build_overrides/pdfium.gni | 10 +++++----- pdfium.gni | 4 ++-- samples/BUILD.gn | 3 ++- 4 files changed, 17 insertions(+), 16 deletions(-) diff --git a/BUILD.gn b/BUILD.gn index 20c51c61a0..975071a654 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -25,14 +25,6 @@ config("pdfium_common_config") { "PNG_USE_READ_MACROS", ] - if (pdf_use_skia) { - defines += [ "_SKIA_SUPPORT_" ] - } - - if (pdf_use_skia_paths) { - defines += [ "_SKIA_SUPPORT_PATHS_" ] - } - if (pdf_enable_v8) { defines += [ "PDF_ENABLE_V8" ] } @@ -53,6 +45,14 @@ config("pdfium_common_config") { } } + if (pdf_use_skia) { + defines += [ "_SKIA_SUPPORT_" ] + } + + if (pdf_use_skia_paths) { + defines += [ "_SKIA_SUPPORT_PATHS_" ] + } + if (pdf_use_win32_gdi) { defines += [ "PDFIUM_PRINT_TEXT_WITH_GDI" ] } diff --git a/build_overrides/pdfium.gni b/build_overrides/pdfium.gni index e42888f55f..ab89cd997b 100644 --- a/build_overrides/pdfium.gni +++ b/build_overrides/pdfium.gni @@ -4,6 +4,11 @@ # This file contains PDFium-related build overrides. +# Build PDFium either using a bundled FreeType library, or using the FreeType +# target defined in //build/config/freetype. +# Default: Use a bundled FreeType. +pdf_bundle_freetype_override = true + # Build PDFium either with or without v8 support. # Default: With V8 support. pdf_enable_v8_override = true @@ -12,11 +17,6 @@ pdf_enable_v8_override = true # Default: Without XFA support. pdf_enable_xfa_override = false -# Build PDFium either using a bundled FreeType library, or using the FreeType -# target defined in //build/config/freetype. -# Default: Use a bundled FreeType. -pdf_bundle_freetype_override = true - # Build PDFium against skia (experimental) rather than agg, replacing all PDFium # graphics. # Default: Use agg. diff --git a/pdfium.gni b/pdfium.gni index f05623af77..e48750e5f0 100644 --- a/pdfium.gni +++ b/pdfium.gni @@ -33,11 +33,11 @@ declare_args() { # If XFA, also support png codec. Ignored if not XFA. pdf_enable_xfa_tiff = true - # Build PDFium against skia (experimental) rather than agg. Use Skia to draw + # Build PDFium against Skia (experimental) rather than AGG. Use Skia to draw # everything. pdf_use_skia = pdf_use_skia_override - # Build PDFium against skia (experimental) rather than agg. Use Skia to draw + # Build PDFium against Skia (experimental) rather than AGG. Use Skia to draw # paths. pdf_use_skia_paths = pdf_use_skia_paths_override diff --git a/samples/BUILD.gn b/samples/BUILD.gn index 8fbf5d552f..66b02f6528 100644 --- a/samples/BUILD.gn +++ b/samples/BUILD.gn @@ -59,6 +59,8 @@ executable("pdfium_test") { "//build/config:exe_and_shlib_deps", "//build/win:default_exe_manifest", ] + configs += [ ":pdfium_samples_config" ] + if (pdf_enable_v8) { deps += [ "//v8:v8_libplatform" ] include_dirs = [ @@ -70,5 +72,4 @@ executable("pdfium_test") { if (pdf_use_skia || pdf_use_skia_paths) { deps += [ "//skia" ] } - configs += [ ":pdfium_samples_config" ] } -- cgit v1.2.3