summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Weber <xmw@gentoo.org>2010-09-09 00:36:57 +0000
committerMichael Weber <xmw@gentoo.org>2010-09-09 00:36:57 +0000
commit451b308da948e725a4641e2809d8c5237babc290 (patch)
tree94963722145e943f9c0db9807115bddc40a1fc81 /app-text
parentadded ppp-2.4.5 support, redesigned pppd version detection. (diff)
downloadgentoo-2-451b308da948e725a4641e2809d8c5237babc290.tar.gz
gentoo-2-451b308da948e725a4641e2809d8c5237babc290.tar.bz2
gentoo-2-451b308da948e725a4641e2809d8c5237babc290.zip
Revision bump to add zoom keys and fix documentation issues
(Portage version: 2.1.8.3/cvs/Linux x86_64)
Diffstat (limited to 'app-text')
-rw-r--r--app-text/mupdf/ChangeLog8
-rw-r--r--app-text/mupdf/files/mupdf-0.7-zoom.patch65
-rw-r--r--app-text/mupdf/mupdf-0.7-r1.ebuild63
3 files changed, 135 insertions, 1 deletions
diff --git a/app-text/mupdf/ChangeLog b/app-text/mupdf/ChangeLog
index ff22f048f604..a6f457f3a4af 100644
--- a/app-text/mupdf/ChangeLog
+++ b/app-text/mupdf/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for app-text/mupdf
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-text/mupdf/ChangeLog,v 1.2 2010/08/30 12:03:38 xmw Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-text/mupdf/ChangeLog,v 1.3 2010/09/09 00:36:57 xmw Exp $
+
+*mupdf-0.7-r1 (09 Sep 2010)
+
+ 09 Sep 2010; Michael Weber <xmw@gentoo.org> +mupdf-0.7-r1.ebuild,
+ +files/mupdf-0.7-zoom.patch:
+ Revision bump to add zoom keys and fix documentation issues.
*mupdf-0.7 (30 Aug 2010)
diff --git a/app-text/mupdf/files/mupdf-0.7-zoom.patch b/app-text/mupdf/files/mupdf-0.7-zoom.patch
new file mode 100644
index 000000000000..0f33e2aa0743
--- /dev/null
+++ b/app-text/mupdf/files/mupdf-0.7-zoom.patch
@@ -0,0 +1,65 @@
+Michael Weber <xmw at gentoo dot org> 09/09/2010
+
+--- apps/pdfapp.c.orig 2010-09-09 01:59:16.820000053 +0200
++++ apps/pdfapp.c 2010-09-09 02:02:32.400000054 +0200
+@@ -602,6 +602,20 @@
+ pdfapp_showpage(app, 0, 1);
+ break;
+
++ case '_': // zoom to default resolution
++ app->resolution = 72;
++ pdfapp_showpage(app, 0, 1);
++ break;
++
++ case 'z': // zoom to fit window
++ case 'Z': // zoom to fill window
++ if ( ( c == 'Z' ) ^ ( app->image->w * app->winh > app->winw * app->image->h ) )
++ app->resolution = ( app->resolution * app->winw ) / app->image->w;
++ else
++ app->resolution = ( app->resolution * app->winh ) / app->image->h;
++ pdfapp_showpage(app, 0, 1);
++ break;
++
+ case 'L':
+ app->rotate -= 90;
+ pdfapp_showpage(app, 0, 1);
+@@ -725,6 +739,7 @@
+ break;
+
+ case 'b':
++ case '\b': //backspace
+ panto = DONT_PAN;
+ if (app->numberlen > 0)
+ app->pageno -= atoi(app->number);
+@@ -733,6 +748,7 @@
+ break;
+
+ case ' ':
++ case 'f':
+ panto = DONT_PAN;
+ if (app->numberlen > 0)
+ app->pageno += atoi(app->number);
+--- debian/mupdf.1.orig 2010-09-09 02:05:07.573000045 +0200
++++ debian/mupdf.1 2010-09-09 02:14:25.744000054 +0200
+@@ -1,4 +1,4 @@
+-.TH MUPDF 1 "March 15, 2010"
++.TH MUPDF 1 "September 9, 2010"
+ .\" Please adjust this date whenever revising the manpage.
+ .SH NAME
+ mupdf \- MuPDF is a lightweight PDF viewer written in portable C
+@@ -96,6 +96,15 @@
+ .B \-
+ Zoom out.
+ .TP
++.B _
++Reset zoom to default (72dpi).
++.TP
++.B z
++Zoom page size to fit into the window frame.
++.TP
++.B Z
++Zoom page size to fill the window frame.
++.TP
+ .B <
+ Rotate page counter-clockwise or left by 90\(de.
+ .TP
diff --git a/app-text/mupdf/mupdf-0.7-r1.ebuild b/app-text/mupdf/mupdf-0.7-r1.ebuild
new file mode 100644
index 000000000000..e6a2eb556bdf
--- /dev/null
+++ b/app-text/mupdf/mupdf-0.7-r1.ebuild
@@ -0,0 +1,63 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-text/mupdf/mupdf-0.7-r1.ebuild,v 1.1 2010/09/09 00:36:57 xmw Exp $
+
+EAPI=2
+
+inherit eutils flag-o-matic multilib toolchain-funcs
+
+DESCRIPTION="a lightweight PDF viewer and toolkit written in portable C"
+HOMEPAGE="http://mupdf.com/"
+SRC_URI="http://${PN}.com/download/${P}.tar.gz"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="X"
+
+RDEPEND="media-libs/freetype:2
+ media-libs/jbig2dec
+ media-libs/jpeg
+ media-libs/openjpeg
+ X? ( x11-libs/libX11
+ x11-libs/libXext )"
+DEPEND="${RDEPEND}
+ dev-util/pkgconfig"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-buildsystem.patch
+
+ epatch "${FILESDIR}"/${P}-zoom.patch
+
+ sed -i -e '/CFLAGS/s: -DNDEBUG : :' Makerules || die
+}
+
+src_compile() {
+ my_pdfexe=
+ use X || my_pdfexe="PDFVIEW_EXE="
+
+ emake build=release ${my_pdfexe} CC="$(tc-getCC)" verbose=true || die
+}
+
+src_install() {
+ emake build=release ${my_pdfexe} prefix="${D}usr" \
+ libprefix="${D}usr/$(get_libdir)" verbose=true install || die
+
+ insinto /usr/$(get_libdir)/pkgconfig
+ doins debian/mupdf.pc || die
+
+ if use X ; then
+ domenu debian/mupdf.desktop || die
+ doicon debian/mupdf.xpm || die
+ doman debian/mupdf.1 || die
+ fi
+ doman debian/pdf{clean,draw,show}.1 || die
+ dodoc README || die
+
+ # avoid collision with app-text/poppler-utils
+ mv "${D}"usr/bin/pdfinfo "${D}"usr/bin/mupdf_pdfinfo || die
+}
+
+pkg_postinst() {
+ elog "pdfinfo was renamed to mupdf_pdfinfo"
+}