[arch-commits] Commit in poppler/repos (8 files)

Jan de Groot jgc at archlinux.org
Mon Dec 19 11:45:18 UTC 2011


    Date: Monday, December 19, 2011 @ 06:45:17
  Author: jgc
Revision: 145182

archrelease: copy trunk to extra-i686, extra-x86_64

Added:
  poppler/repos/extra-i686/PKGBUILD
    (from rev 145181, poppler/trunk/PKGBUILD)
  poppler/repos/extra-i686/git-fixes.patch
    (from rev 145181, poppler/trunk/git-fixes.patch)
  poppler/repos/extra-x86_64/PKGBUILD
    (from rev 145181, poppler/trunk/PKGBUILD)
  poppler/repos/extra-x86_64/git-fixes.patch
    (from rev 145181, poppler/trunk/git-fixes.patch)
Deleted:
  poppler/repos/extra-i686/PKGBUILD
  poppler/repos/extra-i686/git-fixes.patch
  poppler/repos/extra-x86_64/PKGBUILD
  poppler/repos/extra-x86_64/git-fixes.patch

------------------------------+
 extra-i686/PKGBUILD          |  166 +++++++++++++++----------------
 extra-i686/git-fixes.patch   |  217 ++++++++++++++++++++---------------------
 extra-x86_64/PKGBUILD        |  166 +++++++++++++++----------------
 extra-x86_64/git-fixes.patch |  217 ++++++++++++++++++++---------------------
 4 files changed, 386 insertions(+), 380 deletions(-)

Deleted: extra-i686/PKGBUILD
===================================================================
--- extra-i686/PKGBUILD	2011-12-19 11:44:54 UTC (rev 145181)
+++ extra-i686/PKGBUILD	2011-12-19 11:45:17 UTC (rev 145182)
@@ -1,83 +0,0 @@
-# $Id$
-# Maintainer: Jan de Groot <jgc at archlinux.org>
-
-pkgbase=poppler
-pkgname=('poppler' 'poppler-glib' 'poppler-qt')
-pkgver=0.18.1
-pkgrel=1
-arch=(i686 x86_64)
-license=('GPL')
-makedepends=('libjpeg' 'gcc-libs' 'cairo' 'fontconfig' 'openjpeg' 'gtk2' 'qt' 'pkgconfig' 'lcms' 'gobject-introspection')
-options=('!libtool' '!emptydirs')
-url="http://poppler.freedesktop.org/"
-_testtag=0d2bfd4af4c76a3bac27ccaff793d9129df7b57a
-source=(http://poppler.freedesktop.org/${pkgbase}-${pkgver}.tar.gz
-        http://cgit.freedesktop.org/poppler/test/snapshot/test-${_testtag}.tar.bz2
-        git-fixes.patch)
-md5sums=('d30e883a27423c936ef338ce1d967e2d'
-         '9dc64c254a31e570507bdd4ad4ba629a'
-         'a73ba6515aa73cb20c480692da52c79e')
-
-build() {
-  cd "${srcdir}/${pkgbase}-${pkgver}"
-  sed -i -e '/AC_PATH_XTRA/d' configure.ac
-  patch -Np1 -i "${srcdir}/git-fixes.patch"
-
-  autoreconf -fi
-
-  ./configure --prefix=/usr --sysconfdir=/etc \
-      --localstatedir=/var --disable-static \
-      --enable-cairo-output \
-      --enable-xpdf-headers \
-      --enable-libjpeg --enable-zlib \
-      --enable-poppler-qt4 \
-      --enable-poppler-glib
-  make
-}
-
-check() {
-  cd "${srcdir}"
-  ln -sf test-${_testtag} test
-  cd ${pkgbase}-${pkgver}
-  make check
-}
-
-package_poppler() {
-  pkgdesc="PDF rendering library based on xpdf 3.0"
-  depends=('libjpeg' 'gcc-libs' 'cairo' 'fontconfig' 'openjpeg' 'lcms' 'poppler-data')
-  conflicts=("poppler-qt3<${pkgver}")
-
-  cd "${srcdir}/${pkgbase}-${pkgver}"
-  sed -e 's/^glib_subdir =.*/glib_subdir =/' \
-      -e 's/^qt4_subdir =.*/qt4_subdir =/' -i Makefile
-  make DESTDIR="${pkgdir}" install
-
-  rm -f "${pkgdir}"/usr/lib/pkgconfig/poppler-{glib,qt4}.pc
-}
-
-package_poppler-glib() {
-  pkgdesc="Poppler glib bindings"
-  depends=("poppler=${pkgver}" 'glib2')
-
-  cd "${srcdir}/${pkgbase}-${pkgver}/poppler"
-  make DESTDIR="${pkgdir}" install-libLTLIBRARIES
-  cd "${srcdir}/${pkgbase}-${pkgver}/glib"
-  make DESTDIR="${pkgdir}" install
-  install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
-  install -m644 ../poppler-glib.pc "${pkgdir}/usr/lib/pkgconfig/"
-  rm -f "${pkgdir}"/usr/lib/libpoppler.*
-  rm -f "${pkgdir}/usr/bin/poppler-glib-demo"
-}
-
-package_poppler-qt() {
-  pkgdesc="Poppler Qt bindings"
-  depends=("poppler=${pkgver}" 'qt')
-
-  cd "${srcdir}/${pkgbase}-${pkgver}/poppler"
-  make DESTDIR="${pkgdir}" install-libLTLIBRARIES
-  cd "${srcdir}/${pkgbase}-${pkgver}/qt4"
-  make DESTDIR="${pkgdir}" install
-  install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
-  install -m644 ../poppler-qt4.pc "${pkgdir}/usr/lib/pkgconfig/"
-  rm -f "${pkgdir}"/usr/lib/libpoppler.*
-}

Copied: poppler/repos/extra-i686/PKGBUILD (from rev 145181, poppler/trunk/PKGBUILD)
===================================================================
--- extra-i686/PKGBUILD	                        (rev 0)
+++ extra-i686/PKGBUILD	2011-12-19 11:45:17 UTC (rev 145182)
@@ -0,0 +1,83 @@
+# $Id$
+# Maintainer: Jan de Groot <jgc at archlinux.org>
+
+pkgbase=poppler
+pkgname=('poppler' 'poppler-glib' 'poppler-qt')
+pkgver=0.18.2
+pkgrel=1
+arch=(i686 x86_64)
+license=('GPL')
+makedepends=('libjpeg' 'gcc-libs' 'cairo' 'fontconfig' 'openjpeg' 'gtk2' 'qt' 'pkgconfig' 'lcms' 'gobject-introspection')
+options=('!libtool' '!emptydirs')
+url="http://poppler.freedesktop.org/"
+_testtag=0d2bfd4af4c76a3bac27ccaff793d9129df7b57a
+source=(http://poppler.freedesktop.org/${pkgbase}-${pkgver}.tar.gz
+        http://cgit.freedesktop.org/poppler/test/snapshot/test-${_testtag}.tar.bz2
+        git-fixes.patch)
+md5sums=('38616927823ef01937aab26872e957e4'
+         '9dc64c254a31e570507bdd4ad4ba629a'
+         'af56b7b1b24a08f7498a0c7f5e862b93')
+
+build() {
+  cd "${srcdir}/${pkgbase}-${pkgver}"
+  sed -i -e '/AC_PATH_XTRA/d' configure.ac
+  patch -Np1 -i "${srcdir}/git-fixes.patch"
+
+  autoreconf -fi
+
+  ./configure --prefix=/usr --sysconfdir=/etc \
+      --localstatedir=/var --disable-static \
+      --enable-cairo-output \
+      --enable-xpdf-headers \
+      --enable-libjpeg --enable-zlib \
+      --enable-poppler-qt4 \
+      --enable-poppler-glib
+  make
+}
+
+check() {
+  cd "${srcdir}"
+  ln -sf test-${_testtag} test
+  cd ${pkgbase}-${pkgver}
+  LANG=en_US.UTF8 make check
+}
+
+package_poppler() {
+  pkgdesc="PDF rendering library based on xpdf 3.0"
+  depends=('libjpeg' 'gcc-libs' 'cairo' 'fontconfig' 'openjpeg' 'lcms' 'poppler-data')
+  conflicts=("poppler-qt3<${pkgver}")
+
+  cd "${srcdir}/${pkgbase}-${pkgver}"
+  sed -e 's/^glib_subdir =.*/glib_subdir =/' \
+      -e 's/^qt4_subdir =.*/qt4_subdir =/' -i Makefile
+  make DESTDIR="${pkgdir}" install
+
+  rm -f "${pkgdir}"/usr/lib/pkgconfig/poppler-{glib,qt4}.pc
+}
+
+package_poppler-glib() {
+  pkgdesc="Poppler glib bindings"
+  depends=("poppler=${pkgver}" 'glib2')
+
+  cd "${srcdir}/${pkgbase}-${pkgver}/poppler"
+  make DESTDIR="${pkgdir}" install-libLTLIBRARIES
+  cd "${srcdir}/${pkgbase}-${pkgver}/glib"
+  make DESTDIR="${pkgdir}" install
+  install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
+  install -m644 ../poppler-glib.pc "${pkgdir}/usr/lib/pkgconfig/"
+  rm -f "${pkgdir}"/usr/lib/libpoppler.*
+  rm -f "${pkgdir}/usr/bin/poppler-glib-demo"
+}
+
+package_poppler-qt() {
+  pkgdesc="Poppler Qt bindings"
+  depends=("poppler=${pkgver}" 'qt')
+
+  cd "${srcdir}/${pkgbase}-${pkgver}/poppler"
+  make DESTDIR="${pkgdir}" install-libLTLIBRARIES
+  cd "${srcdir}/${pkgbase}-${pkgver}/qt4"
+  make DESTDIR="${pkgdir}" install
+  install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
+  install -m644 ../poppler-qt4.pc "${pkgdir}/usr/lib/pkgconfig/"
+  rm -f "${pkgdir}"/usr/lib/libpoppler.*
+}

Deleted: extra-i686/git-fixes.patch
===================================================================
--- extra-i686/git-fixes.patch	2011-12-19 11:44:54 UTC (rev 145181)
+++ extra-i686/git-fixes.patch	2011-12-19 11:45:17 UTC (rev 145182)
@@ -1,107 +0,0 @@
-From e4a2adb02969e872e37e408ced4c39131c6751ea Mon Sep 17 00:00:00 2001
-From: Carlos Garcia Campos <carlosgc at gnome.org>
-Date: Sun, 30 Oct 2011 15:02:19 +0000
-Subject: pdftocairo: Make sure beginDocument() is always called
-
-This fixes a crash when rendering only odd/even pages in a printing
-format.
----
-diff --git a/utils/pdftocairo.cc b/utils/pdftocairo.cc
-index e458ee5..1b67c90 100644
---- a/utils/pdftocairo.cc
-+++ b/utils/pdftocairo.cc
-@@ -903,6 +903,10 @@ int main(int argc, char *argv[]) {
-     lastPage = firstPage;
-   }
- 
-+  // Make sure firstPage is always used so that beginDocument() is called
-+  if ((printOnlyEven && pg % 2 == 0) || (printOnlyOdd && pg % 2 == 1))
-+    firstPage++;
-+
-   cairoOut = new CairoOutputDev();
-   cairoOut->startDoc(doc->getXRef(), doc->getCatalog());
-   if (sz != 0)
---
-cgit v0.9.0.2-2-gbebe
-From 61b1556d1c62bf090b2eadf93e4e7d0aff7b8015 Mon Sep 17 00:00:00 2001
-From: Carlos Garcia Campos <carlosgc at gnome.org>
-Date: Sun, 30 Oct 2011 15:08:46 +0000
-Subject: pdftocairo: Use fisrtPage instead of uninitialized pg variable
-
-This fixes an error in my previous commit.
----
-diff --git a/utils/pdftocairo.cc b/utils/pdftocairo.cc
-index 1b67c90..d0d1ec6 100644
---- a/utils/pdftocairo.cc
-+++ b/utils/pdftocairo.cc
-@@ -904,7 +904,7 @@ int main(int argc, char *argv[]) {
-   }
- 
-   // Make sure firstPage is always used so that beginDocument() is called
--  if ((printOnlyEven && pg % 2 == 0) || (printOnlyOdd && pg % 2 == 1))
-+  if ((printOnlyEven && firstPage % 2 == 0) || (printOnlyOdd && firstPage % 2 == 1))
-     firstPage++;
- 
-   cairoOut = new CairoOutputDev();
---
-cgit v0.9.0.2-2-gbebe
-From ebf7fbc74da10d1bc423d33b26e30166870642e4 Mon Sep 17 00:00:00 2001
-From: Rex Dieter <rdieter at math.unl.edu>
-Date: Tue, 01 Nov 2011 08:40:53 +0000
-Subject: Fix pkg-config files
-
-We were using $FOO_REQUIRED instead of @FOO_REQUIRED@
----
-diff --git a/configure.ac b/configure.ac
-index 3a120ca..c4f5b92 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -409,6 +409,7 @@ if test x$enable_cairo_output = xyes; then
-   POPPLER_GLIB_DISABLE_SINGLE_INCLUDES=""
- 
-   GLIB_REQUIRED=2.18
-+  AC_SUBST(GLIB_REQUIRED)
-   AC_ARG_ENABLE(poppler-glib,
- 	        AC_HELP_STRING([--disable-poppler-glib],
- 		               [Don't compile poppler glib wrapper.]),
-diff --git a/poppler-glib-uninstalled.pc.in b/poppler-glib-uninstalled.pc.in
-index 55a2278..5fcb6f2 100644
---- a/poppler-glib-uninstalled.pc.in
-+++ b/poppler-glib-uninstalled.pc.in
-@@ -1,7 +1,7 @@
- Name: poppler-glib
- Description: GLib wrapper for poppler - uninstalled
- Version: @VERSION@
--Requires: glib-2.0 >= $GLIB_REQUIRED gobject-2.0 >= $GLIB_REQUIRED cairo >= $CAIRO_VERSION
-+Requires: glib-2.0 >= @GLIB_REQUIRED@ gobject-2.0 >= @GLIB_REQUIRED@ cairo >= @CAIRO_VERSION@
- 
- Libs: ${pc_top_builddir}/${pcfiledir}/glib/libpoppler-glib.la
- Cflags: -I${pc_top_builddir}/${pcfiledir}/glib
-diff --git a/poppler-glib.pc.cmake b/poppler-glib.pc.cmake
-index 3264ed6..e15e669 100644
---- a/poppler-glib.pc.cmake
-+++ b/poppler-glib.pc.cmake
-@@ -6,7 +6,7 @@ includedir=${prefix}/include
- Name: poppler-glib
- Description: GLib wrapper for poppler
- Version: @POPPLER_VERSION@
--Requires: glib-2.0 >= $GLIB_REQUIRED gobject-2.0 >= $GLIB_REQUIRED cairo >= $CAIRO_VERSION
-+Requires: glib-2.0 >= @GLIB_REQUIRED@ gobject-2.0 >= @GLIB_REQUIRED@ cairo >= @CAIRO_VERSION@
- @PC_REQUIRES_PRIVATE@
- 
- Libs: -L${libdir} -lpoppler-glib
-diff --git a/poppler-glib.pc.in b/poppler-glib.pc.in
-index 04d9bb9..9ba8978 100644
---- a/poppler-glib.pc.in
-+++ b/poppler-glib.pc.in
-@@ -6,7 +6,7 @@ includedir=@includedir@
- Name: poppler-glib
- Description: GLib wrapper for poppler
- Version: @VERSION@
--Requires: glib-2.0 >= $GLIB_REQUIRED gobject-2.0 >= $GLIB_REQUIRED cairo >= $CAIRO_VERSION
-+Requires: glib-2.0 >= @GLIB_REQUIRED@ gobject-2.0 >= @GLIB_REQUIRED@ cairo >= @CAIRO_VERSION@
- @PC_REQUIRES_PRIVATE@
- 
- Libs: -L${libdir} -lpoppler-glib
---
-cgit v0.9.0.2-2-gbebe

Copied: poppler/repos/extra-i686/git-fixes.patch (from rev 145181, poppler/trunk/git-fixes.patch)
===================================================================
--- extra-i686/git-fixes.patch	                        (rev 0)
+++ extra-i686/git-fixes.patch	2011-12-19 11:45:17 UTC (rev 145182)
@@ -0,0 +1,110 @@
+From 74f4299e8f9e2d204979479f6579dd784db678a4 Mon Sep 17 00:00:00 2001
+From: Albert Astals Cid <aacid at kde.org>
+Date: Sun, 04 Dec 2011 16:29:45 +0000
+Subject: Do not fail if we are trying to save a file with Encrypt but that we have not modified at all
+
+Fixes KDE bug #288045
+(cherry picked from commit 63c942a45227ef28fb94ef4765171d9812fffafa)
+---
+diff --git a/poppler/PDFDoc.cc b/poppler/PDFDoc.cc
+index 01d2759..2758206 100644
+--- a/poppler/PDFDoc.cc
++++ b/poppler/PDFDoc.cc
+@@ -707,35 +707,44 @@ int PDFDoc::saveAs(GooString *name, PDFWriteMode mode) {
+ 
+ int PDFDoc::saveAs(OutStream *outStr, PDFWriteMode mode) {
+ 
+-  // we don't support files with Encrypt at the moment
++  // find if we have updated objects
++  GBool updated = gFalse;
++  for(int i=0; i<xref->getNumObjects(); i++) {
++    if (xref->getEntry(i)->updated) {
++      updated = gTrue;
++      break;
++    }
++  }
++
++  // we don't support rewriting files with Encrypt at the moment
+   Object obj;
+   xref->getTrailerDict()->getDict()->lookupNF("Encrypt", &obj);
+   if (!obj.isNull())
+   {
+     obj.free();
+-    return errEncrypted;
++    if (!updated && mode == writeStandard) {
++      // simply copy the original file
++      saveWithoutChangesAs (outStr);
++    } else {
++      return errEncrypted;
++    }
+   }
+-  obj.free();
++  else
++  {
++    obj.free();
+ 
+-  if (mode == writeForceRewrite) {
+-    saveCompleteRewrite(outStr);
+-  } else if (mode == writeForceIncremental) {
+-    saveIncrementalUpdate(outStr); 
+-  } else { // let poppler decide
+-    // find if we have updated objects
+-    GBool updated = gFalse;
+-    for(int i=0; i<xref->getNumObjects(); i++) {
+-      if (xref->getEntry(i)->updated) {
+-        updated = gTrue;
+-        break;
++    if (mode == writeForceRewrite) {
++      saveCompleteRewrite(outStr);
++    } else if (mode == writeForceIncremental) {
++      saveIncrementalUpdate(outStr); 
++    } else { // let poppler decide
++      if(updated) { 
++        saveIncrementalUpdate(outStr);
++      } else {
++        // simply copy the original file
++        saveWithoutChangesAs (outStr);
+       }
+     }
+-    if(updated) { 
+-      saveIncrementalUpdate(outStr);
+-    } else {
+-      // simply copy the original file
+-      saveWithoutChangesAs (outStr);
+-    }
+   }
+ 
+   return errNone;
+--
+cgit v0.9.0.2-2-gbebe
+From 03544e2f602319f0b381f5f357e14cc2cc77d2c1 Mon Sep 17 00:00:00 2001
+From: Albert Astals Cid <aacid at kde.org>
+Date: Tue, 06 Dec 2011 22:21:15 +0000
+Subject: include strings.h as we use memcpy
+
+Fixes bug 43558
+(cherry picked from commit 388d72ac27ae98fe3a1ebd21760f2b0fa0249a9b)
+---
+diff --git a/goo/PNGWriter.cc b/goo/PNGWriter.cc
+index f88c3a7..1fb8cab 100644
+--- a/goo/PNGWriter.cc
++++ b/goo/PNGWriter.cc
+@@ -6,7 +6,7 @@
+ //
+ // Copyright (C) 2009 Warren Toomey <wkt at tuhs.org>
+ // Copyright (C) 2009 Shen Liang <shenzhuxi at gmail.com>
+-// Copyright (C) 2009 Albert Astals Cid <aacid at kde.org>
++// Copyright (C) 2009, 2011 Albert Astals Cid <aacid at kde.org>
+ // Copyright (C) 2009 Stefan Thomas <thomas at eload24.com>
+ // Copyright (C) 2010, 2011 Adrian Johnson <ajohnson at redneon.com>
+ // Copyright (C) 2011 Thomas Klausner <wiz at danbala.tuwien.ac.at>
+@@ -19,6 +19,7 @@
+ 
+ #include <zlib.h>
+ #include <stdlib.h>
++#include <string.h>
+ 
+ #include "poppler/Error.h"
+ #include "goo/gmem.h"
+--
+cgit v0.9.0.2-2-gbebe

Deleted: extra-x86_64/PKGBUILD
===================================================================
--- extra-x86_64/PKGBUILD	2011-12-19 11:44:54 UTC (rev 145181)
+++ extra-x86_64/PKGBUILD	2011-12-19 11:45:17 UTC (rev 145182)
@@ -1,83 +0,0 @@
-# $Id$
-# Maintainer: Jan de Groot <jgc at archlinux.org>
-
-pkgbase=poppler
-pkgname=('poppler' 'poppler-glib' 'poppler-qt')
-pkgver=0.18.1
-pkgrel=1
-arch=(i686 x86_64)
-license=('GPL')
-makedepends=('libjpeg' 'gcc-libs' 'cairo' 'fontconfig' 'openjpeg' 'gtk2' 'qt' 'pkgconfig' 'lcms' 'gobject-introspection')
-options=('!libtool' '!emptydirs')
-url="http://poppler.freedesktop.org/"
-_testtag=0d2bfd4af4c76a3bac27ccaff793d9129df7b57a
-source=(http://poppler.freedesktop.org/${pkgbase}-${pkgver}.tar.gz
-        http://cgit.freedesktop.org/poppler/test/snapshot/test-${_testtag}.tar.bz2
-        git-fixes.patch)
-md5sums=('d30e883a27423c936ef338ce1d967e2d'
-         '9dc64c254a31e570507bdd4ad4ba629a'
-         'a73ba6515aa73cb20c480692da52c79e')
-
-build() {
-  cd "${srcdir}/${pkgbase}-${pkgver}"
-  sed -i -e '/AC_PATH_XTRA/d' configure.ac
-  patch -Np1 -i "${srcdir}/git-fixes.patch"
-
-  autoreconf -fi
-
-  ./configure --prefix=/usr --sysconfdir=/etc \
-      --localstatedir=/var --disable-static \
-      --enable-cairo-output \
-      --enable-xpdf-headers \
-      --enable-libjpeg --enable-zlib \
-      --enable-poppler-qt4 \
-      --enable-poppler-glib
-  make
-}
-
-check() {
-  cd "${srcdir}"
-  ln -sf test-${_testtag} test
-  cd ${pkgbase}-${pkgver}
-  make check
-}
-
-package_poppler() {
-  pkgdesc="PDF rendering library based on xpdf 3.0"
-  depends=('libjpeg' 'gcc-libs' 'cairo' 'fontconfig' 'openjpeg' 'lcms' 'poppler-data')
-  conflicts=("poppler-qt3<${pkgver}")
-
-  cd "${srcdir}/${pkgbase}-${pkgver}"
-  sed -e 's/^glib_subdir =.*/glib_subdir =/' \
-      -e 's/^qt4_subdir =.*/qt4_subdir =/' -i Makefile
-  make DESTDIR="${pkgdir}" install
-
-  rm -f "${pkgdir}"/usr/lib/pkgconfig/poppler-{glib,qt4}.pc
-}
-
-package_poppler-glib() {
-  pkgdesc="Poppler glib bindings"
-  depends=("poppler=${pkgver}" 'glib2')
-
-  cd "${srcdir}/${pkgbase}-${pkgver}/poppler"
-  make DESTDIR="${pkgdir}" install-libLTLIBRARIES
-  cd "${srcdir}/${pkgbase}-${pkgver}/glib"
-  make DESTDIR="${pkgdir}" install
-  install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
-  install -m644 ../poppler-glib.pc "${pkgdir}/usr/lib/pkgconfig/"
-  rm -f "${pkgdir}"/usr/lib/libpoppler.*
-  rm -f "${pkgdir}/usr/bin/poppler-glib-demo"
-}
-
-package_poppler-qt() {
-  pkgdesc="Poppler Qt bindings"
-  depends=("poppler=${pkgver}" 'qt')
-
-  cd "${srcdir}/${pkgbase}-${pkgver}/poppler"
-  make DESTDIR="${pkgdir}" install-libLTLIBRARIES
-  cd "${srcdir}/${pkgbase}-${pkgver}/qt4"
-  make DESTDIR="${pkgdir}" install
-  install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
-  install -m644 ../poppler-qt4.pc "${pkgdir}/usr/lib/pkgconfig/"
-  rm -f "${pkgdir}"/usr/lib/libpoppler.*
-}

Copied: poppler/repos/extra-x86_64/PKGBUILD (from rev 145181, poppler/trunk/PKGBUILD)
===================================================================
--- extra-x86_64/PKGBUILD	                        (rev 0)
+++ extra-x86_64/PKGBUILD	2011-12-19 11:45:17 UTC (rev 145182)
@@ -0,0 +1,83 @@
+# $Id$
+# Maintainer: Jan de Groot <jgc at archlinux.org>
+
+pkgbase=poppler
+pkgname=('poppler' 'poppler-glib' 'poppler-qt')
+pkgver=0.18.2
+pkgrel=1
+arch=(i686 x86_64)
+license=('GPL')
+makedepends=('libjpeg' 'gcc-libs' 'cairo' 'fontconfig' 'openjpeg' 'gtk2' 'qt' 'pkgconfig' 'lcms' 'gobject-introspection')
+options=('!libtool' '!emptydirs')
+url="http://poppler.freedesktop.org/"
+_testtag=0d2bfd4af4c76a3bac27ccaff793d9129df7b57a
+source=(http://poppler.freedesktop.org/${pkgbase}-${pkgver}.tar.gz
+        http://cgit.freedesktop.org/poppler/test/snapshot/test-${_testtag}.tar.bz2
+        git-fixes.patch)
+md5sums=('38616927823ef01937aab26872e957e4'
+         '9dc64c254a31e570507bdd4ad4ba629a'
+         'af56b7b1b24a08f7498a0c7f5e862b93')
+
+build() {
+  cd "${srcdir}/${pkgbase}-${pkgver}"
+  sed -i -e '/AC_PATH_XTRA/d' configure.ac
+  patch -Np1 -i "${srcdir}/git-fixes.patch"
+
+  autoreconf -fi
+
+  ./configure --prefix=/usr --sysconfdir=/etc \
+      --localstatedir=/var --disable-static \
+      --enable-cairo-output \
+      --enable-xpdf-headers \
+      --enable-libjpeg --enable-zlib \
+      --enable-poppler-qt4 \
+      --enable-poppler-glib
+  make
+}
+
+check() {
+  cd "${srcdir}"
+  ln -sf test-${_testtag} test
+  cd ${pkgbase}-${pkgver}
+  LANG=en_US.UTF8 make check
+}
+
+package_poppler() {
+  pkgdesc="PDF rendering library based on xpdf 3.0"
+  depends=('libjpeg' 'gcc-libs' 'cairo' 'fontconfig' 'openjpeg' 'lcms' 'poppler-data')
+  conflicts=("poppler-qt3<${pkgver}")
+
+  cd "${srcdir}/${pkgbase}-${pkgver}"
+  sed -e 's/^glib_subdir =.*/glib_subdir =/' \
+      -e 's/^qt4_subdir =.*/qt4_subdir =/' -i Makefile
+  make DESTDIR="${pkgdir}" install
+
+  rm -f "${pkgdir}"/usr/lib/pkgconfig/poppler-{glib,qt4}.pc
+}
+
+package_poppler-glib() {
+  pkgdesc="Poppler glib bindings"
+  depends=("poppler=${pkgver}" 'glib2')
+
+  cd "${srcdir}/${pkgbase}-${pkgver}/poppler"
+  make DESTDIR="${pkgdir}" install-libLTLIBRARIES
+  cd "${srcdir}/${pkgbase}-${pkgver}/glib"
+  make DESTDIR="${pkgdir}" install
+  install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
+  install -m644 ../poppler-glib.pc "${pkgdir}/usr/lib/pkgconfig/"
+  rm -f "${pkgdir}"/usr/lib/libpoppler.*
+  rm -f "${pkgdir}/usr/bin/poppler-glib-demo"
+}
+
+package_poppler-qt() {
+  pkgdesc="Poppler Qt bindings"
+  depends=("poppler=${pkgver}" 'qt')
+
+  cd "${srcdir}/${pkgbase}-${pkgver}/poppler"
+  make DESTDIR="${pkgdir}" install-libLTLIBRARIES
+  cd "${srcdir}/${pkgbase}-${pkgver}/qt4"
+  make DESTDIR="${pkgdir}" install
+  install -m755 -d "${pkgdir}/usr/lib/pkgconfig"
+  install -m644 ../poppler-qt4.pc "${pkgdir}/usr/lib/pkgconfig/"
+  rm -f "${pkgdir}"/usr/lib/libpoppler.*
+}

Deleted: extra-x86_64/git-fixes.patch
===================================================================
--- extra-x86_64/git-fixes.patch	2011-12-19 11:44:54 UTC (rev 145181)
+++ extra-x86_64/git-fixes.patch	2011-12-19 11:45:17 UTC (rev 145182)
@@ -1,107 +0,0 @@
-From e4a2adb02969e872e37e408ced4c39131c6751ea Mon Sep 17 00:00:00 2001
-From: Carlos Garcia Campos <carlosgc at gnome.org>
-Date: Sun, 30 Oct 2011 15:02:19 +0000
-Subject: pdftocairo: Make sure beginDocument() is always called
-
-This fixes a crash when rendering only odd/even pages in a printing
-format.
----
-diff --git a/utils/pdftocairo.cc b/utils/pdftocairo.cc
-index e458ee5..1b67c90 100644
---- a/utils/pdftocairo.cc
-+++ b/utils/pdftocairo.cc
-@@ -903,6 +903,10 @@ int main(int argc, char *argv[]) {
-     lastPage = firstPage;
-   }
- 
-+  // Make sure firstPage is always used so that beginDocument() is called
-+  if ((printOnlyEven && pg % 2 == 0) || (printOnlyOdd && pg % 2 == 1))
-+    firstPage++;
-+
-   cairoOut = new CairoOutputDev();
-   cairoOut->startDoc(doc->getXRef(), doc->getCatalog());
-   if (sz != 0)
---
-cgit v0.9.0.2-2-gbebe
-From 61b1556d1c62bf090b2eadf93e4e7d0aff7b8015 Mon Sep 17 00:00:00 2001
-From: Carlos Garcia Campos <carlosgc at gnome.org>
-Date: Sun, 30 Oct 2011 15:08:46 +0000
-Subject: pdftocairo: Use fisrtPage instead of uninitialized pg variable
-
-This fixes an error in my previous commit.
----
-diff --git a/utils/pdftocairo.cc b/utils/pdftocairo.cc
-index 1b67c90..d0d1ec6 100644
---- a/utils/pdftocairo.cc
-+++ b/utils/pdftocairo.cc
-@@ -904,7 +904,7 @@ int main(int argc, char *argv[]) {
-   }
- 
-   // Make sure firstPage is always used so that beginDocument() is called
--  if ((printOnlyEven && pg % 2 == 0) || (printOnlyOdd && pg % 2 == 1))
-+  if ((printOnlyEven && firstPage % 2 == 0) || (printOnlyOdd && firstPage % 2 == 1))
-     firstPage++;
- 
-   cairoOut = new CairoOutputDev();
---
-cgit v0.9.0.2-2-gbebe
-From ebf7fbc74da10d1bc423d33b26e30166870642e4 Mon Sep 17 00:00:00 2001
-From: Rex Dieter <rdieter at math.unl.edu>
-Date: Tue, 01 Nov 2011 08:40:53 +0000
-Subject: Fix pkg-config files
-
-We were using $FOO_REQUIRED instead of @FOO_REQUIRED@
----
-diff --git a/configure.ac b/configure.ac
-index 3a120ca..c4f5b92 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -409,6 +409,7 @@ if test x$enable_cairo_output = xyes; then
-   POPPLER_GLIB_DISABLE_SINGLE_INCLUDES=""
- 
-   GLIB_REQUIRED=2.18
-+  AC_SUBST(GLIB_REQUIRED)
-   AC_ARG_ENABLE(poppler-glib,
- 	        AC_HELP_STRING([--disable-poppler-glib],
- 		               [Don't compile poppler glib wrapper.]),
-diff --git a/poppler-glib-uninstalled.pc.in b/poppler-glib-uninstalled.pc.in
-index 55a2278..5fcb6f2 100644
---- a/poppler-glib-uninstalled.pc.in
-+++ b/poppler-glib-uninstalled.pc.in
-@@ -1,7 +1,7 @@
- Name: poppler-glib
- Description: GLib wrapper for poppler - uninstalled
- Version: @VERSION@
--Requires: glib-2.0 >= $GLIB_REQUIRED gobject-2.0 >= $GLIB_REQUIRED cairo >= $CAIRO_VERSION
-+Requires: glib-2.0 >= @GLIB_REQUIRED@ gobject-2.0 >= @GLIB_REQUIRED@ cairo >= @CAIRO_VERSION@
- 
- Libs: ${pc_top_builddir}/${pcfiledir}/glib/libpoppler-glib.la
- Cflags: -I${pc_top_builddir}/${pcfiledir}/glib
-diff --git a/poppler-glib.pc.cmake b/poppler-glib.pc.cmake
-index 3264ed6..e15e669 100644
---- a/poppler-glib.pc.cmake
-+++ b/poppler-glib.pc.cmake
-@@ -6,7 +6,7 @@ includedir=${prefix}/include
- Name: poppler-glib
- Description: GLib wrapper for poppler
- Version: @POPPLER_VERSION@
--Requires: glib-2.0 >= $GLIB_REQUIRED gobject-2.0 >= $GLIB_REQUIRED cairo >= $CAIRO_VERSION
-+Requires: glib-2.0 >= @GLIB_REQUIRED@ gobject-2.0 >= @GLIB_REQUIRED@ cairo >= @CAIRO_VERSION@
- @PC_REQUIRES_PRIVATE@
- 
- Libs: -L${libdir} -lpoppler-glib
-diff --git a/poppler-glib.pc.in b/poppler-glib.pc.in
-index 04d9bb9..9ba8978 100644
---- a/poppler-glib.pc.in
-+++ b/poppler-glib.pc.in
-@@ -6,7 +6,7 @@ includedir=@includedir@
- Name: poppler-glib
- Description: GLib wrapper for poppler
- Version: @VERSION@
--Requires: glib-2.0 >= $GLIB_REQUIRED gobject-2.0 >= $GLIB_REQUIRED cairo >= $CAIRO_VERSION
-+Requires: glib-2.0 >= @GLIB_REQUIRED@ gobject-2.0 >= @GLIB_REQUIRED@ cairo >= @CAIRO_VERSION@
- @PC_REQUIRES_PRIVATE@
- 
- Libs: -L${libdir} -lpoppler-glib
---
-cgit v0.9.0.2-2-gbebe

Copied: poppler/repos/extra-x86_64/git-fixes.patch (from rev 145181, poppler/trunk/git-fixes.patch)
===================================================================
--- extra-x86_64/git-fixes.patch	                        (rev 0)
+++ extra-x86_64/git-fixes.patch	2011-12-19 11:45:17 UTC (rev 145182)
@@ -0,0 +1,110 @@
+From 74f4299e8f9e2d204979479f6579dd784db678a4 Mon Sep 17 00:00:00 2001
+From: Albert Astals Cid <aacid at kde.org>
+Date: Sun, 04 Dec 2011 16:29:45 +0000
+Subject: Do not fail if we are trying to save a file with Encrypt but that we have not modified at all
+
+Fixes KDE bug #288045
+(cherry picked from commit 63c942a45227ef28fb94ef4765171d9812fffafa)
+---
+diff --git a/poppler/PDFDoc.cc b/poppler/PDFDoc.cc
+index 01d2759..2758206 100644
+--- a/poppler/PDFDoc.cc
++++ b/poppler/PDFDoc.cc
+@@ -707,35 +707,44 @@ int PDFDoc::saveAs(GooString *name, PDFWriteMode mode) {
+ 
+ int PDFDoc::saveAs(OutStream *outStr, PDFWriteMode mode) {
+ 
+-  // we don't support files with Encrypt at the moment
++  // find if we have updated objects
++  GBool updated = gFalse;
++  for(int i=0; i<xref->getNumObjects(); i++) {
++    if (xref->getEntry(i)->updated) {
++      updated = gTrue;
++      break;
++    }
++  }
++
++  // we don't support rewriting files with Encrypt at the moment
+   Object obj;
+   xref->getTrailerDict()->getDict()->lookupNF("Encrypt", &obj);
+   if (!obj.isNull())
+   {
+     obj.free();
+-    return errEncrypted;
++    if (!updated && mode == writeStandard) {
++      // simply copy the original file
++      saveWithoutChangesAs (outStr);
++    } else {
++      return errEncrypted;
++    }
+   }
+-  obj.free();
++  else
++  {
++    obj.free();
+ 
+-  if (mode == writeForceRewrite) {
+-    saveCompleteRewrite(outStr);
+-  } else if (mode == writeForceIncremental) {
+-    saveIncrementalUpdate(outStr); 
+-  } else { // let poppler decide
+-    // find if we have updated objects
+-    GBool updated = gFalse;
+-    for(int i=0; i<xref->getNumObjects(); i++) {
+-      if (xref->getEntry(i)->updated) {
+-        updated = gTrue;
+-        break;
++    if (mode == writeForceRewrite) {
++      saveCompleteRewrite(outStr);
++    } else if (mode == writeForceIncremental) {
++      saveIncrementalUpdate(outStr); 
++    } else { // let poppler decide
++      if(updated) { 
++        saveIncrementalUpdate(outStr);
++      } else {
++        // simply copy the original file
++        saveWithoutChangesAs (outStr);
+       }
+     }
+-    if(updated) { 
+-      saveIncrementalUpdate(outStr);
+-    } else {
+-      // simply copy the original file
+-      saveWithoutChangesAs (outStr);
+-    }
+   }
+ 
+   return errNone;
+--
+cgit v0.9.0.2-2-gbebe
+From 03544e2f602319f0b381f5f357e14cc2cc77d2c1 Mon Sep 17 00:00:00 2001
+From: Albert Astals Cid <aacid at kde.org>
+Date: Tue, 06 Dec 2011 22:21:15 +0000
+Subject: include strings.h as we use memcpy
+
+Fixes bug 43558
+(cherry picked from commit 388d72ac27ae98fe3a1ebd21760f2b0fa0249a9b)
+---
+diff --git a/goo/PNGWriter.cc b/goo/PNGWriter.cc
+index f88c3a7..1fb8cab 100644
+--- a/goo/PNGWriter.cc
++++ b/goo/PNGWriter.cc
+@@ -6,7 +6,7 @@
+ //
+ // Copyright (C) 2009 Warren Toomey <wkt at tuhs.org>
+ // Copyright (C) 2009 Shen Liang <shenzhuxi at gmail.com>
+-// Copyright (C) 2009 Albert Astals Cid <aacid at kde.org>
++// Copyright (C) 2009, 2011 Albert Astals Cid <aacid at kde.org>
+ // Copyright (C) 2009 Stefan Thomas <thomas at eload24.com>
+ // Copyright (C) 2010, 2011 Adrian Johnson <ajohnson at redneon.com>
+ // Copyright (C) 2011 Thomas Klausner <wiz at danbala.tuwien.ac.at>
+@@ -19,6 +19,7 @@
+ 
+ #include <zlib.h>
+ #include <stdlib.h>
++#include <string.h>
+ 
+ #include "poppler/Error.h"
+ #include "goo/gmem.h"
+--
+cgit v0.9.0.2-2-gbebe




More information about the arch-commits mailing list