diff options
-rw-r--r-- | BUILD.gn | 2 | ||||
-rw-r--r-- | DEPS | 2 | ||||
-rw-r--r-- | pdfium.gyp | 2 | ||||
-rw-r--r-- | samples/BUILD.gn | 4 | ||||
-rw-r--r-- | samples/samples.gyp | 9 | ||||
-rw-r--r-- | third_party/BUILD.gn | 6 | ||||
-rw-r--r-- | third_party/third_party.gyp | 2 |
7 files changed, 21 insertions, 6 deletions
@@ -131,7 +131,7 @@ static_library("pdfium") { } if (pdfium_bundle_freetype) { - deps += [ "third_party:freetype" ] + deps += [ "third_party:fx_freetype" ] } else { libs += [ "freetype" ] } @@ -8,7 +8,7 @@ deps = { "https://chromium.googlesource.com/chromium/buildtools.git@46ce8cb60364e9e0b21a81136c7debdddfd063a8", "testing/corpus": - "https://pdfium.googlesource.com/pdfium_tests@4b9a1d593e5a101d034a4f1195174a22c179a42d", + "https://pdfium.googlesource.com/pdfium_tests@ab8b8db8660253962d8d624a85bf2c53fcf01097", "testing/gmock": "https://chromium.googlesource.com/external/googlemock.git@29763965ab52f24565299976b936d1265cb6a271", diff --git a/pdfium.gyp b/pdfium.gyp index a3697a3f7c..16d55d30d8 100644 --- a/pdfium.gyp +++ b/pdfium.gyp @@ -112,7 +112,7 @@ }], ['bundle_freetype==1', { 'dependencies': [ - 'third_party/third_party.gyp:freetype', + 'third_party/third_party.gyp:fx_freetype', ], }, { 'link_settings': { diff --git a/samples/BUILD.gn b/samples/BUILD.gn index 748a2af399..6f4518c17e 100644 --- a/samples/BUILD.gn +++ b/samples/BUILD.gn @@ -24,6 +24,10 @@ executable("pdfium_test") { ] deps = [ "//third_party/pdfium", + # Regardless of whether the library ships against system freetype, + # always link this binary against the bundled one for consistency + # of results across platforms. + "//third_party/pdfium/third_party:fx_freetype", "//v8:v8_libplatform", ":fx_lpng", ] diff --git a/samples/samples.gyp b/samples/samples.gyp index 4938ecb955..4b6c16bf2e 100644 --- a/samples/samples.gyp +++ b/samples/samples.gyp @@ -22,12 +22,21 @@ 'dependencies': [ 'fx_lpng', '../pdfium.gyp:pdfium', + # Regardless of whether the library ships against system freetype, + # always link this binary against the bundled one for consistency + # of results across platforms. + '../third_party/third_party.gyp:fx_freetype', '<(DEPTH)/v8/tools/gyp/v8.gyp:v8_libplatform', ], 'sources': [ 'pdfium_test.cc', 'image_diff_png.cc', ], + 'link_settings': { + 'libraries!': [ + '-lfreetype', + ], + }, }, { 'target_name': 'pdfium_diff', diff --git a/third_party/BUILD.gn b/third_party/BUILD.gn index 37e30ce06d..b1c8e262fc 100644 --- a/third_party/BUILD.gn +++ b/third_party/BUILD.gn @@ -5,7 +5,7 @@ group("third_party") { deps = [ ":bigint", - ":freetype", + ":fx_freetype", ":pdfium_base", ] } @@ -30,7 +30,9 @@ source_set("bigint") { ] } -source_set("freetype") { +# Tests may link against this even if the production library doesn't, +# so it needs to be separate from it. +static_library("fx_freetype") { configs -= [ "//build/config/compiler:chromium_code" ] configs += [ "//build/config/compiler:no_chromium_code", diff --git a/third_party/third_party.gyp b/third_party/third_party.gyp index 79368b5a68..4403f3cdac 100644 --- a/third_party/third_party.gyp +++ b/third_party/third_party.gyp @@ -30,7 +30,7 @@ ], }, { - 'target_name': 'freetype', + 'target_name': 'fx_freetype', 'type': 'static_library', 'defines': [ 'FT2_BUILD_LIBRARY', |