summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas K. Hüttel <dilfridge@gentoo.org>2012-07-31 08:51:14 +0000
committerAndreas K. Hüttel <dilfridge@gentoo.org>2012-07-31 08:51:14 +0000
commitedbb06e8baace275546a1bacd11038ec6658f1c6 (patch)
tree56cec6f3f10b4d48dad71231edce40c2b27dbe04 /app-text
parentBackport upstream sax fix, needed for javatoolkit and possibly others. (diff)
downloadgentoo-2-edbb06e8baace275546a1bacd11038ec6658f1c6.tar.gz
gentoo-2-edbb06e8baace275546a1bacd11038ec6658f1c6.tar.bz2
gentoo-2-edbb06e8baace275546a1bacd11038ec6658f1c6.zip
Fix printing of some pdf files, bug 426674
(Portage version: 2.2.0_alpha120/cvs/Linux x86_64)
Diffstat (limited to 'app-text')
-rw-r--r--app-text/poppler/ChangeLog8
-rw-r--r--app-text/poppler/files/poppler-0.20.2-xyscale.patch46
-rw-r--r--app-text/poppler/poppler-0.20.2-r1.ebuild102
3 files changed, 155 insertions, 1 deletions
diff --git a/app-text/poppler/ChangeLog b/app-text/poppler/ChangeLog
index ed1ad480a699..e0a181f7dfc9 100644
--- a/app-text/poppler/ChangeLog
+++ b/app-text/poppler/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for app-text/poppler
# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-text/poppler/ChangeLog,v 1.327 2012/07/23 21:36:52 dilfridge Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-text/poppler/ChangeLog,v 1.328 2012/07/31 08:51:13 dilfridge Exp $
+
+*poppler-0.20.2-r1 (31 Jul 2012)
+
+ 31 Jul 2012; Andreas K. Huettel <dilfridge@gentoo.org>
+ +poppler-0.20.2-r1.ebuild, +files/poppler-0.20.2-xyscale.patch:
+ Fix printing of some pdf files, bug 426674
23 Jul 2012; Andreas K. Huettel <dilfridge@gentoo.org> poppler-0.20.2.ebuild:
Needs newer gobject-introspection, bug 379527
diff --git a/app-text/poppler/files/poppler-0.20.2-xyscale.patch b/app-text/poppler/files/poppler-0.20.2-xyscale.patch
new file mode 100644
index 000000000000..6602dc909c2f
--- /dev/null
+++ b/app-text/poppler/files/poppler-0.20.2-xyscale.patch
@@ -0,0 +1,46 @@
+From 36481939e3064de920e49d9d1742a85473a50963 Mon Sep 17 00:00:00 2001
+From: Thomas Freitag <Thomas.Freitag@alfa.de>
+Date: Sun, 22 Jul 2012 16:40:46 +0000
+Subject: Make sure xScale and yScale are always initialized
+
+Bug #52215
+---
+diff --git a/poppler/PSOutputDev.cc b/poppler/PSOutputDev.cc
+index a01a4b3..e15c2e9 100644
+--- a/poppler/PSOutputDev.cc
++++ b/poppler/PSOutputDev.cc
+@@ -3521,6 +3521,7 @@ void PSOutputDev::startPage(int pageNum, GfxState *state) {
+ saveState(NULL);
+ }
+
++ xScale = yScale = 1;
+ switch (mode) {
+
+ case psModePSOrigPageSizes:
+@@ -3631,8 +3632,6 @@ void PSOutputDev::startPage(int pageNum, GfxState *state) {
+ } else {
+ yScale = xScale;
+ }
+- } else {
+- xScale = yScale = 1;
+ }
+ // deal with odd bounding boxes or clipping
+ if (clipLLX0 < clipURX0 && clipLLY0 < clipURY0) {
+@@ -3694,7 +3693,6 @@ void PSOutputDev::startPage(int pageNum, GfxState *state) {
+ if (tx != 0 || ty != 0) {
+ writePSFmt("{0:.6g} {1:.6g} translate\n", tx, ty);
+ }
+- xScale = yScale = 1;
+ break;
+
+ case psModeForm:
+@@ -3702,7 +3700,6 @@ void PSOutputDev::startPage(int pageNum, GfxState *state) {
+ writePS("begin xpdf begin\n");
+ writePS("pdfStartPage\n");
+ tx = ty = 0;
+- xScale = yScale = 1;
+ rotate = 0;
+ break;
+ }
+--
+cgit v0.9.0.2-2-gbebe
diff --git a/app-text/poppler/poppler-0.20.2-r1.ebuild b/app-text/poppler/poppler-0.20.2-r1.ebuild
new file mode 100644
index 000000000000..468a0fcfe6c9
--- /dev/null
+++ b/app-text/poppler/poppler-0.20.2-r1.ebuild
@@ -0,0 +1,102 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-text/poppler/poppler-0.20.2-r1.ebuild,v 1.1 2012/07/31 08:51:14 dilfridge Exp $
+
+EAPI="4"
+
+inherit cmake-utils
+
+DESCRIPTION="PDF rendering library based on the xpdf-3.0 code base"
+HOMEPAGE="http://poppler.freedesktop.org/"
+SRC_URI="http://poppler.freedesktop.org/${P}.tar.gz"
+
+LICENSE="GPL-2"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x64-freebsd ~x86-freebsd ~amd64-linux ~ia64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+SLOT="0"
+IUSE="cairo cjk curl cxx debug doc +introspection jpeg jpeg2k +lcms png qt4 tiff +utils +xpdf-headers"
+
+# No test data provided
+RESTRICT="test"
+
+COMMON_DEPEND="
+ >=media-libs/fontconfig-2.6.0
+ >=media-libs/freetype-2.3.9
+ sys-libs/zlib
+ cairo? (
+ dev-libs/glib:2
+ >=x11-libs/cairo-1.10.0
+ introspection? ( >=dev-libs/gobject-introspection-1.32.1 )
+ )
+ curl? ( net-misc/curl )
+ jpeg? ( virtual/jpeg )
+ jpeg2k? ( media-libs/openjpeg )
+ lcms? ( media-libs/lcms:2 )
+ png? ( >=media-libs/libpng-1.4:0 )
+ qt4? (
+ x11-libs/qt-core:4
+ x11-libs/qt-gui:4
+ )
+ tiff? ( media-libs/tiff:0 )
+"
+DEPEND="${COMMON_DEPEND}
+ virtual/pkgconfig
+"
+RDEPEND="${COMMON_DEPEND}
+ !dev-libs/poppler
+ !dev-libs/poppler-glib
+ !dev-libs/poppler-qt3
+ !dev-libs/poppler-qt4
+ !app-text/poppler-utils
+ cjk? ( >=app-text/poppler-data-0.4.4 )
+"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-0.20.1-lcms-automagic.patch"
+ "${FILESDIR}/${PN}-0.20.2-xyscale.patch"
+)
+
+DOCS=(AUTHORS ChangeLog NEWS README README-XPDF TODO)
+
+src_configure() {
+ mycmakeargs=(
+ -DBUILD_GTK_TESTS=OFF
+ -DBUILD_QT4_TESTS=OFF
+ -DBUILD_CPP_TESTS=OFF
+ -DENABLE_SPLASH=ON
+ -DENABLE_ZLIB=ON
+ $(cmake-utils_use_enable curl LIBCURL)
+ $(cmake-utils_use_enable cxx CPP)
+ $(cmake-utils_use_enable jpeg2k LIBOPENJPEG)
+ $(cmake-utils_use_enable utils)
+ $(cmake-utils_use_enable xpdf-headers XPDF_HEADERS)
+ $(cmake-utils_use_with cairo)
+ $(cmake-utils_use_with introspection GObjectIntrospection)
+ $(cmake-utils_use_with jpeg)
+ $(cmake-utils_use_with png)
+ $(cmake-utils_use_with qt4)
+ $(cmake-utils_use_with tiff)
+ )
+ if use lcms; then
+ mycmakeargs+=(-DENABLE_CMS=lcms2)
+ else
+ mycmakeargs+=(-DENABLE_CMS=)
+ fi
+
+ cmake-utils_src_configure
+}
+
+src_install() {
+ cmake-utils_src_install
+
+ if use cairo && use doc; then
+ # For now install gtk-doc there
+ insinto /usr/share/gtk-doc/html/poppler
+ doins -r "${S}"/glib/reference/html/* || die 'failed to install API documentation'
+ fi
+}
+
+pkg_postinst() {
+ ewarn "After upgrading app-text/poppler you may need to reinstall packages"
+ ewarn "linking to it. If you're not a portage-2.2_rc user, you're advised"
+ ewarn "to run revdep-rebuild"
+}