summaryrefslogtreecommitdiff
path: root/external/pdfium
diff options
context:
space:
mode:
Diffstat (limited to 'external/pdfium')
-rw-r--r--external/pdfium/Library_pdfium.mk2
-rw-r--r--external/pdfium/UnpackedTarball_pdfium.mk1
-rw-r--r--external/pdfium/build.patch.135
-rw-r--r--external/pdfium/visibility.patch.110
4 files changed, 22 insertions, 26 deletions
diff --git a/external/pdfium/Library_pdfium.mk b/external/pdfium/Library_pdfium.mk
index f98a2d11269b..e7618791bcb8 100644
--- a/external/pdfium/Library_pdfium.mk
+++ b/external/pdfium/Library_pdfium.mk
@@ -315,6 +315,7 @@ $(eval $(call gb_Library_add_generated_exception_objects,pdfium,\
UnpackedTarball/pdfium/core/fpdfdoc/cpdf_structtree \
UnpackedTarball/pdfium/core/fpdfdoc/cba_fontmap \
UnpackedTarball/pdfium/core/fpdfdoc/cpdf_color_utils \
+ UnpackedTarball/pdfium/core/fpdfdoc/cpdf_icon \
))
# fpdftext
@@ -552,6 +553,7 @@ $(eval $(call gb_Library_add_generated_exception_objects,pdfium,\
UnpackedTarball/pdfium/third_party/base/allocator/partition_allocator/partition_oom \
UnpackedTarball/pdfium/third_party/base/allocator/partition_allocator/partition_page \
UnpackedTarball/pdfium/third_party/base/allocator/partition_allocator/partition_root_base \
+ UnpackedTarball/pdfium/third_party/base/allocator/partition_allocator/random \
))
# skia_shared
diff --git a/external/pdfium/UnpackedTarball_pdfium.mk b/external/pdfium/UnpackedTarball_pdfium.mk
index 8f493ea3a0d6..2874bd72719f 100644
--- a/external/pdfium/UnpackedTarball_pdfium.mk
+++ b/external/pdfium/UnpackedTarball_pdfium.mk
@@ -44,6 +44,7 @@ $(eval $(call gb_UnpackedTarball_set_post_action,pdfium,\
mv third_party/base/allocator/partition_allocator/partition_oom.cc third_party/base/allocator/partition_allocator/partition_oom.cpp && \
mv third_party/base/allocator/partition_allocator/partition_page.cc third_party/base/allocator/partition_allocator/partition_page.cpp && \
mv third_party/base/allocator/partition_allocator/partition_root_base.cc third_party/base/allocator/partition_allocator/partition_root_base.cpp && \
+ mv third_party/base/allocator/partition_allocator/random.cc third_party/base/allocator/partition_allocator/random.cpp && \
mv third_party/base/win/win_util.cc third_party/base/win/win_util.cpp \
))
diff --git a/external/pdfium/build.patch.1 b/external/pdfium/build.patch.1
index 47316fe235a1..729d87f5ee8e 100644
--- a/external/pdfium/build.patch.1
+++ b/external/pdfium/build.patch.1
@@ -1,24 +1,3 @@
-diff --git a/core/fxge/dib/cfx_imagetransformer.cpp b/core/fxge/dib/cfx_imagetransformer.cpp
-index 8e01127b0..f4ce4d915 100644
---- a/core/fxge/dib/cfx_imagetransformer.cpp
-+++ b/core/fxge/dib/cfx_imagetransformer.cpp
-@@ -315,14 +315,14 @@ bool CFX_ImageTransformer::Continue(IFX_PauseIndicator* pPause) {
- } else if (pDestMask) {
- CalcData cdata = {
- pDestMask.Get(), result2stretch, pSrcMaskBuf,
-- m_Storer.GetBitmap()->m_pAlphaMask->GetPitch(),
-+ static_cast<uint32_t>(m_Storer.GetBitmap()->m_pAlphaMask->GetPitch()),
- };
- CalcMask(cdata);
- }
-
- CalcData cdata = {pTransformed.Get(), result2stretch,
- m_Storer.GetBitmap()->GetBuffer(),
-- m_Storer.GetBitmap()->GetPitch()};
-+ static_cast<uint32_t>(m_Storer.GetBitmap()->GetPitch())};
- if (m_Storer.GetBitmap()->IsAlphaMask()) {
- CalcAlpha(cdata);
- } else {
diff --git a/core/fpdfdoc/cpdf_metadata.cpp b/core/fpdfdoc/cpdf_metadata.cpp
index 323de4ffc..f11a0b0ad 100644
--- a/core/fpdfdoc/cpdf_metadata.cpp
@@ -58,3 +37,17 @@ index 0fb627ba8..dda1fc8bc 100644
: span(container.data(), container.size()) {}
template <
typename Container,
+--- a/core/fxcrt/fx_memory_wrappers.h.orig 2020-01-15 11:16:03.848760100 +0100
++++ b/core/fxcrt/fx_memory_wrappers.h 2020-01-15 11:16:44.050531200 +0100
+@@ -23,8 +23,11 @@
+ template <class T>
+ struct FxAllocAllocator {
+ public:
++#ifndef _WIN32
++ // MSVC thinks uint8_t is not an arithmetic type.
+ static_assert(std::is_arithmetic<T>::value,
+ "Only numeric types allowed in this partition");
++#endif
+
+ using value_type = T;
+ using pointer = T*;
diff --git a/external/pdfium/visibility.patch.1 b/external/pdfium/visibility.patch.1
index 835528794f4b..14a380bbfa16 100644
--- a/external/pdfium/visibility.patch.1
+++ b/external/pdfium/visibility.patch.1
@@ -1,16 +1,16 @@
diff --git a/public/fpdfview.h b/public/fpdfview.h
-index 2b84f07ba..b6c0a356b 100644
+index 0542b0541..2c9a37b4a 100644
--- a/public/fpdfview.h
+++ b/public/fpdfview.h
-@@ -168,7 +168,6 @@ typedef int FPDF_OBJECT_TYPE;
- // Text object enums.
- typedef int FPDF_TEXT_RENDERMODE;
+@@ -175,7 +175,6 @@ typedef int FPDF_ANNOT_APPEARANCEMODE;
+ // Dictionary value types.
+ typedef int FPDF_OBJECT_TYPE;
-#if defined(COMPONENT_BUILD)
// FPDF_EXPORT should be consistent with |export| in the pdfium_fuzzer
// template in testing/fuzzers/BUILD.gn.
#if defined(WIN32)
-@@ -184,9 +183,6 @@ typedef int FPDF_TEXT_RENDERMODE;
+@@ -191,9 +190,6 @@ typedef int FPDF_OBJECT_TYPE;
#define FPDF_EXPORT
#endif // defined(FPDF_IMPLEMENTATION)
#endif // defined(WIN32)