diff options
author | Brett Wilson <brettw@chromium.org> | 2015-03-06 11:06:38 -0800 |
---|---|---|
committer | Brett Wilson <brettw@chromium.org> | 2015-03-06 11:06:38 -0800 |
commit | 8842c6214cf70fa4237d17684cc9f609536c0240 (patch) | |
tree | a91e5aeacdc7757df4e325aba68ab7045e99a326 /third_party | |
parent | 5a370d77d0db7550e91888f0ff50ee305f0f9f3d (diff) | |
download | pdfium-8842c6214cf70fa4237d17684cc9f609536c0240.tar.xz |
Fix the pdfium component build.
It has a component with no object files in it. When compiled as a shared library, this fails.
This changes the target to a source set which can handle empty sources. It also changes the other static libraries in pdfium to source_sets (it should be very rare to need real static libraries).
Runs "gn format" over the BUILD files.
Renames the arg bundle_freetype to pdfium_bundle_freetype which makes more sense in the context of a larger build like Chrome.
R=jam@chromium.org
Review URL: https://codereview.chromium.org/985543002
Diffstat (limited to 'third_party')
-rw-r--r-- | third_party/BUILD.gn | 41 |
1 files changed, 20 insertions, 21 deletions
diff --git a/third_party/BUILD.gn b/third_party/BUILD.gn index fcb09c4b47..c6de4535da 100644 --- a/third_party/BUILD.gn +++ b/third_party/BUILD.gn @@ -10,31 +10,31 @@ group("third_party") { ] } -static_library("bigint") { +source_set("bigint") { configs -= [ "//build/config/compiler:chromium_code" ] configs += [ - "//third_party/pdfium:pdfium_config", - "//build/config/compiler:no_chromium_code", + "//third_party/pdfium:pdfium_config", + "//build/config/compiler:no_chromium_code", ] sources = [ + "bigint/BigInteger.cc", "bigint/BigInteger.hh", "bigint/BigIntegerLibrary.hh", - "bigint/BigIntegerUtils.hh", - "bigint/BigUnsigned.hh", - "bigint/NumberlikeArray.hh", - "bigint/BigUnsignedInABase.hh", - "bigint/BigInteger.cc", "bigint/BigIntegerUtils.cc", + "bigint/BigIntegerUtils.hh", "bigint/BigUnsigned.cc", + "bigint/BigUnsigned.hh", "bigint/BigUnsignedInABase.cc", + "bigint/BigUnsignedInABase.hh", + "bigint/NumberlikeArray.hh", ] } -static_library("freetype") { +source_set("freetype") { configs -= [ "//build/config/compiler:chromium_code" ] configs += [ - "//third_party/pdfium:pdfium_config", - "//build/config/compiler:no_chromium_code", + "//third_party/pdfium:pdfium_config", + "//build/config/compiler:no_chromium_code", ] defines = [ "FT2_BUILD_LIBRARY" ] sources = [ @@ -43,13 +43,10 @@ static_library("freetype") { "freetype/include/ftmm.h", "freetype/include/ftotval.h", "freetype/include/ftoutln.h", - "freetype/include/tttables.h", "freetype/include/internal/ftobjs.h", "freetype/include/internal/ftstream.h", "freetype/include/internal/tttypes.h", - "freetype/src/cff/cffobjs.h", - "freetype/src/cff/cfftypes.h", - "freetype/src/cff/cff.c", + "freetype/include/tttables.h", "freetype/src/base/ftbase.c", "freetype/src/base/ftbitmap.c", "freetype/src/base/ftglyph.c", @@ -57,6 +54,10 @@ static_library("freetype") { "freetype/src/base/ftlcdfil.c", "freetype/src/base/ftmm.c", "freetype/src/base/ftsystem.c", + "freetype/src/cff/cff.c", + "freetype/src/cff/cffobjs.h", + "freetype/src/cff/cfftypes.h", + "freetype/src/cid/type1cid.c", "freetype/src/psaux/psaux.c", "freetype/src/pshinter/pshinter.c", "freetype/src/psnames/psmodule.c", @@ -65,24 +66,22 @@ static_library("freetype") { "freetype/src/smooth/smooth.c", "freetype/src/truetype/truetype.c", "freetype/src/type1/type1.c", - "freetype/src/cid/type1cid.c", ] } -component("pdfium_base") { +source_set("pdfium_base") { configs -= [ "//build/config/compiler:chromium_code" ] configs += [ - "//third_party/pdfium:pdfium_config", - "//build/config/compiler:no_chromium_code", + "//third_party/pdfium:pdfium_config", + "//build/config/compiler:no_chromium_code", ] sources = [ "base/logging.h", "base/macros.h", - "base/template_util.h", "base/numerics/safe_conversions.h", "base/numerics/safe_conversions_impl.h", "base/numerics/safe_math.h", "base/numerics/safe_math_impl.h", + "base/template_util.h", ] } - |