[Libreoffice-commits] core.git: Branch 'private/swe/libreoffice-5-2+backports' - 2 commits - download.lst external/poppler

David Tardon dtardon at redhat.com
Thu Jun 21 15:39:34 UTC 2018


 download.lst                                              |    4 +-
 external/poppler/0001-Fix-building-with-old-clang.patch.1 |   25 ++++++++++++
 external/poppler/ExternalProject_poppler.mk               |    2 -
 external/poppler/UnpackedTarball_poppler.mk               |    1 
 external/poppler/ubsan.patch.0                            |   28 +++++++-------
 5 files changed, 44 insertions(+), 16 deletions(-)

New commits:
commit 4490513018868f1752c693c9480d28277920a3e0
Author: David Tardon <dtardon at redhat.com>
Date:   Thu Sep 7 15:50:09 2017 +0200

    upload poppler 0.59.0
    
    Change-Id: I21dfa3aa04bd960cb2fb87a53213ae4bbd510a24
    Reviewed-on: https://gerrit.libreoffice.org/42061
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: David Tardon <dtardon at redhat.com>
    (cherry picked from commit 1c983335116a6f09cabf0b3eae7f51951111341e)
    Reviewed-on: https://gerrit.libreoffice.org/56256
    Reviewed-by: Thorsten Behrens <Thorsten.Behrens at CIB.de>
    Tested-by: Thorsten Behrens <Thorsten.Behrens at CIB.de>

diff --git a/download.lst b/download.lst
index ccd5e8b3b1bd..5677ab58e433 100644
--- a/download.lst
+++ b/download.lst
@@ -129,8 +129,8 @@ export PAGEMAKER_TARBALL := libpagemaker-0.0.3.tar.bz2
 export PIXMAN_TARBALL := c63f411b3ad147db2bcce1bf262a0e02-pixman-0.24.4.tar.bz2
 export PNG_MD5SUM := 897ccec1ebfb0922e83c2bfaa1be8748
 export PNG_TARBALL := libpng-1.6.28.tar.gz
-export POPPLER_MD5SUM := f7a8230626b6d2061acfdc852930b7dd
-export POPPLER_TARBALL := poppler-0.55.0.tar.xz
+export POPPLER_MD5SUM := 6e44408a3b4f4a738f8a6770d0aea8a5
+export POPPLER_TARBALL := poppler-0.59.0.tar.xz
 export POSTGRESQL_TARBALL := c0b4799ea9850eae3ead14f0a60e9418-postgresql-9.2.1.tar.bz2
 
 ifeq ($(PYTHON_VERSION_MINOR),3)
diff --git a/external/poppler/0001-Fix-building-with-old-clang.patch.1 b/external/poppler/0001-Fix-building-with-old-clang.patch.1
new file mode 100644
index 000000000000..dcddd11d2967
--- /dev/null
+++ b/external/poppler/0001-Fix-building-with-old-clang.patch.1
@@ -0,0 +1,25 @@
+From dd80c182cbcb188af0dd590f222ba9bbb31e3fb7 Mon Sep 17 00:00:00 2001
+From: Albert Astals Cid <aacid at kde.org>
+Date: Mon, 4 Sep 2017 19:36:06 +0200
+Subject: [PATCH] Fix building with old clang
+
+---
+ poppler/StructElement.cc | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/poppler/StructElement.cc b/poppler/StructElement.cc
+index 0fbd336a..451213f8 100644
+--- a/poppler/StructElement.cc
++++ b/poppler/StructElement.cc
+@@ -248,6 +248,8 @@ struct AttributeMapEntry {
+ };
+ 
+ struct AttributeDefaults {
++  AttributeDefaults() {}; // needed to support old clang
++
+   Object Inline  = Object(objName, "Inline");
+   Object LrTb = Object(objName, "LrTb");
+   Object Normal = Object(objName, "Normal");
+-- 
+2.13.5
+
diff --git a/external/poppler/UnpackedTarball_poppler.mk b/external/poppler/UnpackedTarball_poppler.mk
index f72c040c513b..94c8eb650dbc 100644
--- a/external/poppler/UnpackedTarball_poppler.mk
+++ b/external/poppler/UnpackedTarball_poppler.mk
@@ -17,6 +17,7 @@ $(eval $(call gb_UnpackedTarball_add_patches,poppler,\
 	external/poppler/poppler-mac-fake.patch.1 \
 	external/poppler/ubsan.patch.0 \
 	external/poppler/poppler-libjpeg.patch.1 \
+	external/poppler/0001-Fix-building-with-old-clang.patch.1 \
 ))
 
 # vim: set noet sw=4 ts=4:
diff --git a/external/poppler/ubsan.patch.0 b/external/poppler/ubsan.patch.0
index e0bf164ce7fc..f6e4667dc133 100644
--- a/external/poppler/ubsan.patch.0
+++ b/external/poppler/ubsan.patch.0
@@ -9,7 +9,7 @@
  {
    doc = docA;
    xref = doc->getXRef();
-   aobj->copy(&obj);
+   obj = aobj->copy();
 -  Dict* dict = obj.getDict();
    ref.num = ref.gen = 0;
    type = ty;
@@ -23,9 +23,9 @@
 +void FormField::init(std::set<int> *usedParents)
 +{
 +  Dict* dict = obj.getDict();
-   Object obj1;
    //childs
-   if (dict->lookup("Kids", &obj1)->isArray()) {
+   Object obj1 = dict->lookup("Kids");
+   if (obj1.isArray()) {
 @@ -803,9 +806,15 @@
  //------------------------------------------------------------------------
  // FormFieldButton
@@ -80,14 +80,16 @@
    numChoices = 0;
    choices = NULL;
    editedChoice = NULL;
-@@ -1379,9 +1400,15 @@
+@@ -1379,11 +1400,17 @@
  //------------------------------------------------------------------------
  // FormFieldSignature
  //------------------------------------------------------------------------
 -FormFieldSignature::FormFieldSignature(PDFDoc *docA, Object *dict, const Ref& ref, FormField *parent, std::set<int> *usedParents)
--  : FormField(docA, dict, ref, parent, usedParents, formSignature)
+-  : FormField(docA, dict, ref, parent, usedParents, formSignature),
 +FormFieldSignature::FormFieldSignature(PDFDoc *docA, Object *dict, const Ref& ref, FormField *parent)
-+  : FormField(docA, dict, ref, parent, formSignature)
++  : FormField(docA, dict, ref, parent, formSignature),
+     signature_type(adbe_pkcs7_detached),
+     signature(nullptr), signature_info(nullptr)
  {
 +}
 +
@@ -99,9 +101,9 @@
  
    signature_info = new SignatureInfo();
 @@ -1691,15 +1718,15 @@
-     FormField *field;
  
-     if (Form::fieldLookup(obj->getDict (), "FT", &obj2)->isName("Btn")) {
+     Object obj2 = Form::fieldLookup(obj->getDict (), "FT");
+     if (obj2.isName("Btn")) {
 -      field = new FormFieldButton(docA, obj, pref, parent, usedParents);
 +      field = FormFieldButton::create(docA, obj, pref, parent, usedParents);
      } else if (obj2.isName("Tx")) {
@@ -117,8 +119,8 @@
 -      field = new FormField(docA, obj, pref, parent, usedParents);
 +      field = FormField::create(docA, obj, pref, parent, usedParents);
      }
-     obj2.free();
  
+     return field;
 --- poppler/Form.h
 +++ poppler/Form.h
 @@ -264,8 +264,16 @@
@@ -198,9 +200,9 @@
    ~FormFieldChoice();
  
 @@ -491,8 +523,16 @@
- //------------------------------------------------------------------------
  
  class FormFieldSignature: public FormField {
+   friend class FormWidgetSignature;
 -public:
 -  FormFieldSignature(PDFDoc *docA, Object *dict, const Ref& ref, FormField *parent, std::set<int> *usedParents);
 +private:
@@ -214,8 +216,8 @@
 +    return f;
 +  }
  
-   SignatureInfo *validateSignature(bool doVerifyCert, bool forceRevalidation);
- 
+   // Use -1 for now as validationTime
+   SignatureInfo *validateSignature(bool doVerifyCert, bool forceRevalidation, time_t validationTime);
 --- poppler/XRef.cc
 +++ poppler/XRef.cc
 @@ -293,6 +293,7 @@
commit 6ce93fcb4bc3cbb4f00d2733a25c9f14cbcc0838
Author: David Tardon <dtardon at redhat.com>
Date:   Wed May 24 19:09:54 2017 +0200

    upload poppler 0.55.0
    
    Change-Id: I19b7d324a2dc50d006b4d255ddb6a5c1f15bc616
    Reviewed-on: https://gerrit.libreoffice.org/37998
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: David Tardon <dtardon at redhat.com>
    (cherry picked from commit b12e16f8fc186117cbb20cc3866bf052a3d75515)
    Signed-off-by: David Tardon <dtardon at redhat.com>
    (cherry picked from commit 51775f495f0399177edbcabb2ad881cdd9f57e0f)
    Reviewed-on: https://gerrit.libreoffice.org/56255
    Reviewed-by: Thorsten Behrens <Thorsten.Behrens at CIB.de>
    Tested-by: Thorsten Behrens <Thorsten.Behrens at CIB.de>

diff --git a/download.lst b/download.lst
index 18681926e860..ccd5e8b3b1bd 100644
--- a/download.lst
+++ b/download.lst
@@ -129,8 +129,8 @@ export PAGEMAKER_TARBALL := libpagemaker-0.0.3.tar.bz2
 export PIXMAN_TARBALL := c63f411b3ad147db2bcce1bf262a0e02-pixman-0.24.4.tar.bz2
 export PNG_MD5SUM := 897ccec1ebfb0922e83c2bfaa1be8748
 export PNG_TARBALL := libpng-1.6.28.tar.gz
-export POPPLER_MD5SUM := 9e057ed8eee1f9979fa75d8f044783b8
-export POPPLER_TARBALL := poppler-0.49.0.tar.xz
+export POPPLER_MD5SUM := f7a8230626b6d2061acfdc852930b7dd
+export POPPLER_TARBALL := poppler-0.55.0.tar.xz
 export POSTGRESQL_TARBALL := c0b4799ea9850eae3ead14f0a60e9418-postgresql-9.2.1.tar.bz2
 
 ifeq ($(PYTHON_VERSION_MINOR),3)
diff --git a/external/poppler/ExternalProject_poppler.mk b/external/poppler/ExternalProject_poppler.mk
index 2a83b164ce4d..83d51b9ea9e7 100644
--- a/external/poppler/ExternalProject_poppler.mk
+++ b/external/poppler/ExternalProject_poppler.mk
@@ -28,7 +28,7 @@ $(call gb_ExternalProject_get_state_target,poppler,build) :
 			--disable-shared \
 			--enable-xpdf-headers \
 			--disable-poppler-cpp \
-			--disable-libopenjpeg \
+			--enable-libopenjpeg=none \
 			--disable-libtiff \
 			--enable-libjpeg \
 			--disable-libpng \
diff --git a/external/poppler/ubsan.patch.0 b/external/poppler/ubsan.patch.0
index 67675253b5ad..e0bf164ce7fc 100644
--- a/external/poppler/ubsan.patch.0
+++ b/external/poppler/ubsan.patch.0
@@ -195,7 +195,7 @@
 +    return f;
 +  }
  
-   virtual ~FormFieldChoice();
+   ~FormFieldChoice();
  
 @@ -491,8 +523,16 @@
  //------------------------------------------------------------------------


More information about the Libreoffice-commits mailing list