summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Ballier <aballier@gentoo.org>2008-09-03 18:48:18 +0000
committerAlexis Ballier <aballier@gentoo.org>2008-09-03 18:48:18 +0000
commit077e8871543aecc2d5039b63ee92fbe3131bd10e (patch)
treee350d929ab6979905c8592897f53ad92f0cc0cd3 /dev-tex/pdftex
parentstable ppc64, bug 213696 (diff)
downloadgentoo-2-077e8871543aecc2d5039b63ee92fbe3131bd10e.tar.gz
gentoo-2-077e8871543aecc2d5039b63ee92fbe3131bd10e.tar.bz2
gentoo-2-077e8871543aecc2d5039b63ee92fbe3131bd10e.zip
Initial import. Standalone pdftex patched to use poppler.
(Portage version: 2.2_rc8/cvs/Linux 2.6.26.3 x86_64)
Diffstat (limited to 'dev-tex/pdftex')
-rw-r--r--dev-tex/pdftex/ChangeLog10
-rw-r--r--dev-tex/pdftex/Manifest5
-rw-r--r--dev-tex/pdftex/files/pdftex-1.40.9-poppler.patch65
-rw-r--r--dev-tex/pdftex/metadata.xml13
-rw-r--r--dev-tex/pdftex/pdftex-1.40.9.ebuild100
5 files changed, 193 insertions, 0 deletions
diff --git a/dev-tex/pdftex/ChangeLog b/dev-tex/pdftex/ChangeLog
new file mode 100644
index 000000000000..4ff36d29ba0a
--- /dev/null
+++ b/dev-tex/pdftex/ChangeLog
@@ -0,0 +1,10 @@
+# ChangeLog for dev-tex/pdftex
+# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-tex/pdftex/ChangeLog,v 1.1 2008/09/03 18:48:17 aballier Exp $
+
+*pdftex-1.40.9 (03 Sep 2008)
+
+ 03 Sep 2008; Alexis Ballier <aballier@gentoo.org>
+ +files/pdftex-1.40.9-poppler.patch, +metadata.xml, +pdftex-1.40.9.ebuild:
+ Initial import. Standalone pdftex patched to use poppler.
+
diff --git a/dev-tex/pdftex/Manifest b/dev-tex/pdftex/Manifest
new file mode 100644
index 000000000000..47e85753ed44
--- /dev/null
+++ b/dev-tex/pdftex/Manifest
@@ -0,0 +1,5 @@
+AUX pdftex-1.40.9-poppler.patch 2829 RMD160 36842212fd1ef5ef086d245b6638dbca6c352056 SHA1 995cc0110b435c3385a505ee0636dae8ad6c6a5f SHA256 9c4a2544fb5d01bba2a7adfb47bc5a0add54b840c04983fb8fb3695ffbc08c7f
+DIST pdftex-1.40.9.tar.bz2 3899364 RMD160 09df8924b478a26a4816a55ae97822127bb1c476 SHA1 8302ef0c9651ff293916505b122ad59db955e318 SHA256 78e17e070c27b6645db291fa1d7b390d19bf090bca4326806ed292c9809dc27c
+EBUILD pdftex-1.40.9.ebuild 2386 RMD160 6e6031dc808b963578eb91d49122e49494c3fa07 SHA1 85e7cd888a582bdf7a28c97b926ced7e8740d5ab SHA256 ffbb3cca32f22f8dd950776303bd1c517b61951901bb7a06803fe28ff4bd1a84
+MISC ChangeLog 334 RMD160 a471ed0d12bd9c4a5a6f88bc6e5f92d482c4fcab SHA1 4d501d906b6988d718be4213e594cbbdec4c167b SHA256 5a3012b9e765a4d5933c77453ae1c079197d187c1ed93acd327499ba89988a37
+MISC metadata.xml 638 RMD160 59e3769086396359f1a50ee60b6702555770e33e SHA1 f9a566b850466987e74d5c16c345c54506ae4a0d SHA256 b28290517ed75fbaaa0282cdca3692f11635d173ee5dc5cb342f6071dbb3d3ea
diff --git a/dev-tex/pdftex/files/pdftex-1.40.9-poppler.patch b/dev-tex/pdftex/files/pdftex-1.40.9-poppler.patch
new file mode 100644
index 000000000000..eb8aa50bf94b
--- /dev/null
+++ b/dev-tex/pdftex/files/pdftex-1.40.9-poppler.patch
@@ -0,0 +1,65 @@
+Index: pdftex-1.40.9/src/texk/web2c/pdftexdir/pdftoepdf.cc
+===================================================================
+--- pdftex-1.40.9.orig/src/texk/web2c/pdftexdir/pdftoepdf.cc
++++ pdftex-1.40.9/src/texk/web2c/pdftexdir/pdftoepdf.cc
+@@ -24,8 +24,9 @@ Franklin Street, Fifth Floor, Boston, MA
+ #include <stdio.h>
+ #include <string.h>
+ #include <ctype.h>
+-#include <aconf.h>
+-#include <GString.h>
++#include <dirent.h>
++#include <poppler-config.h>
++#include <GooString.h>
+ #include <gmem.h>
+ #include <gfile.h>
+ #include <config.h>
+@@ -159,7 +160,7 @@ static PdfDocument *find_add_document(ch
+ fprintf(stderr, "\npdfTeX Debug: Creating %s (%d)\n", p->file_name,
+ p->occurences);
+ #endif
+- GString *docName = new GString(p->file_name);
++ GooString *docName = new GooString(p->file_name);
+ p->doc = new PDFDoc(docName); // takes ownership of docName
+ if (!p->doc->isOk() || !p->doc->okToPrint()) {
+ pdftex_fail("xpdf: reading PDF image failed");
+@@ -520,7 +521,7 @@ static void copyObject(Object * obj)
+ int i, l, c;
+ Ref ref;
+ char *p;
+- GString *s;
++ GooString *s;
+ if (obj->isBool()) {
+ pdf_printf("%s", obj->getBool()? "true" : "false");
+ } else if (obj->isInt()) {
+@@ -713,7 +714,7 @@ read_pdf_info(char *image_name, char *pa
+ epdf_num_pages = pdf_doc->doc->getCatalog()->getNumPages();
+ if (page_name) {
+ // get page by name
+- GString name(page_name);
++ GooString name(page_name);
+ LinkDest *link = pdf_doc->doc->findDest(&name);
+ if (link == 0 || !link->isOk())
+ pdftex_fail("PDF inclusion: invalid destination <%s>", page_name);
+Index: pdftex-1.40.9/src/texk/web2c/pdftexdir/utils.c
+===================================================================
+--- pdftex-1.40.9.orig/src/texk/web2c/pdftexdir/utils.c
++++ pdftex-1.40.9/src/texk/web2c/pdftexdir/utils.c
+@@ -35,7 +35,7 @@ Franklin Street, Fifth Floor, Boston, MA
+ #include "zlib.h"
+ #include "ptexlib.h"
+ #include "png.h"
+-#include "xpdf/config.h" /* just to get the xpdf version */
++#include <poppler/poppler-config.h> /* just to get the poppler version */
+
+ static const char _svn_version[] =
+ "$Id: pdftex-1.40.9-poppler.patch,v 1.1 2008/09/03 18:48:18 aballier Exp $ $URL: svn://192.168.0.1/svnroot/pdftex/branches/stable/source/src/texk/web2c/pdftexdir/utils.c $";
+@@ -1267,7 +1267,7 @@ void initversionstring(char **versions)
+ (void) asprintf(versions,
+ "Compiled with libpng %s; using libpng %s\n"
+ "Compiled with zlib %s; using zlib %s\n"
+- "Compiled with xpdf version %s\n",
++ "Compiled with poppler version %s\n",
+ PNG_LIBPNG_VER_STRING, png_libpng_ver,
+ ZLIB_VERSION, zlib_version, xpdfVersion);
+ }
diff --git a/dev-tex/pdftex/metadata.xml b/dev-tex/pdftex/metadata.xml
new file mode 100644
index 000000000000..ec725e3d2591
--- /dev/null
+++ b/dev-tex/pdftex/metadata.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>tex</herd>
+<longdescription lang="en">
+ An extended version of eTeX that can create PDF directly from TeX source
+ files and enhance the result of TeX typesetting with the help of PDF. When
+ PDF output is not selected, pdfTeX produces normal DVI output, otherwise
+ it produces PDF output that looks identical to the DVI output. An important
+ aspect of this project is to investigate alternative justification
+ algorithms, optionally making use of multiple master fonts.
+</longdescription>
+</pkgmetadata>
diff --git a/dev-tex/pdftex/pdftex-1.40.9.ebuild b/dev-tex/pdftex/pdftex-1.40.9.ebuild
new file mode 100644
index 000000000000..f51297df38ae
--- /dev/null
+++ b/dev-tex/pdftex/pdftex-1.40.9.ebuild
@@ -0,0 +1,100 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-tex/pdftex/pdftex-1.40.9.ebuild,v 1.1 2008/09/03 18:48:17 aballier Exp $
+
+inherit libtool toolchain-funcs eutils multilib
+
+DESCRIPTION="Standalone (patched to use poppler) version of pdftex"
+HOMEPAGE="http://www.pdftex.org/"
+SLOT="0"
+LICENSE="GPL-2"
+
+SRC_URI="http://sarovar.org/download.php/1240/${P}.tar.bz2"
+
+KEYWORDS="~amd64 ~x86-fbsd"
+IUSE=""
+
+RDEPEND=">=app-text/poppler-0.8
+ media-libs/libpng
+ sys-libs/zlib"
+DEPEND="${RDEPEND}
+ dev-util/pkgconfig"
+
+S="${WORKDIR}/${P}/src"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch "${FILESDIR}/${P}-poppler.patch"
+ elibtoolize
+}
+
+src_compile() {
+ tc-export CC CXX AR RANLIB
+
+ econf \
+ --without-cxx-runtime-hack \
+ --without-aleph \
+ --without-bibtex8 \
+ --without-cjkutils \
+ --without-detex \
+ --without-dialog \
+ --without-dtl \
+ --without-dvi2tty \
+ --without-dvidvi \
+ --without-dviljk \
+ --without-dvipdfm \
+ --without-dvipdfmx \
+ --without-dvipng \
+ --without-dvipos \
+ --without-dvipsk \
+ --without-etex \
+ --without-gsftopk \
+ --without-lacheck \
+ --without-lcdf-typetools \
+ --without-makeindexk \
+ --without-mkocp-default \
+ --without-mkofm-default \
+ --without-musixflx \
+ --without-omega \
+ --without-pdfopen \
+ --without-ps2eps \
+ --without-ps2pkm \
+ --without-psutils \
+ --without-sam2p \
+ --without-seetexk \
+ --without-t1utils \
+ --without-tetex \
+ --without-tex4htk \
+ --without-texi2html \
+ --without-texinfo \
+ --without-texlive \
+ --without-ttf2pk \
+ --without-tth \
+ --without-xdv2pdf \
+ --without-xdvik \
+ --without-xdvipdfmx \
+ --without-xetex \
+ --disable-largefile \
+ --with-system-zlib \
+ --with-system-pnglib \
+ --disable-multiplatform
+
+ cd "${S}/texk/web2c"
+ emake \
+ LIBXPDFDEP="" LDLIBXPDF="$(pkg-config --libs poppler)" \
+ LIBXPDFSRCDIR="/usr/include/poppler" LIBXPDFDIR="/usr/include/poppler" \
+ ZLIBSRCDIR="." \
+ pdftex || die "emake pdftex failed"
+}
+
+src_install() {
+ cd "${S}/texk/web2c"
+ emake bindir="${D}/usr/bin" \
+ LIBXPDFDEP="" LDLIBXPDF="$(pkg-config --libs poppler)" \
+ LIBXPDFSRCDIR="/usr/include/poppler" LIBXPDFDIR="/usr/include/poppler" \
+ ZLIBSRCDIR="." \
+ install-pdftex || die "install pdftex failed"
+ # Rename it
+ mv "${D}/usr/bin/pdftex" "${D}/usr/bin/pdftex-${P}" || die "renaming failed"
+}