diff options
author | Andreas K. Hüttel <dilfridge@gentoo.org> | 2014-04-30 23:46:58 +0000 |
---|---|---|
committer | Andreas K. Hüttel <dilfridge@gentoo.org> | 2014-04-30 23:46:58 +0000 |
commit | 558a7867884943907fff9c6efe0e7cb5ed3278b3 (patch) | |
tree | 4fa0140da538dc090965c288d4e3c76ff76711e1 /dev-tex | |
parent | Version bump. Ebuild by Arfrever. (diff) | |
download | gentoo-2-558a7867884943907fff9c6efe0e7cb5ed3278b3.tar.gz gentoo-2-558a7867884943907fff9c6efe0e7cb5ed3278b3.tar.bz2 gentoo-2-558a7867884943907fff9c6efe0e7cb5ed3278b3.zip |
Add patch for building against poppler-0.26, bug 508890; without keywords for testing
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key EBE6A336BE19039C!)
Diffstat (limited to 'dev-tex')
-rw-r--r-- | dev-tex/luatex/ChangeLog | 11 | ||||
-rw-r--r-- | dev-tex/luatex/files/poppler026.patch | 143 | ||||
-rw-r--r-- | dev-tex/luatex/luatex-0.76.0-r1.ebuild | 104 |
3 files changed, 256 insertions, 2 deletions
diff --git a/dev-tex/luatex/ChangeLog b/dev-tex/luatex/ChangeLog index 8e1f61604406..a553adb134ec 100644 --- a/dev-tex/luatex/ChangeLog +++ b/dev-tex/luatex/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for dev-tex/luatex -# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-tex/luatex/ChangeLog,v 1.136 2013/08/14 11:24:49 patrick Exp $ +# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/dev-tex/luatex/ChangeLog,v 1.137 2014/04/30 23:46:58 dilfridge Exp $ + +*luatex-0.76.0-r1 (30 Apr 2014) + + 30 Apr 2014; Andreas K. Huettel <dilfridge@gentoo.org> + +luatex-0.76.0-r1.ebuild, +files/poppler026.patch: + Add patch for building against poppler-0.26, bug 508890; without keywords for + testing 14 Aug 2013; Patrick Lauer <patrick@gentoo.org> luatex-0.70.1-r2.ebuild: Whitespace diff --git a/dev-tex/luatex/files/poppler026.patch b/dev-tex/luatex/files/poppler026.patch new file mode 100644 index 000000000000..f7b5ba35b488 --- /dev/null +++ b/dev-tex/luatex/files/poppler026.patch @@ -0,0 +1,143 @@ +Source: NetBSD CVS +http://mail-index.netbsd.org/pkgsrc-bugs/2014/04/29/msg053974.html +http://cvsweb.de.netbsd.org/cgi-bin/cvsweb.cgi/pkgsrc/print/luatex/patches/ + + +diff -ruN luatex-beta-0.76.0.orig/source/texk/web2c/luatexdir/image/epdf.h luatex-beta-0.76.0/source/texk/web2c/luatexdir/image/epdf.h +--- luatex-beta-0.76.0.orig/source/texk/web2c/luatexdir/image/epdf.h 2013-04-05 12:58:37.000000000 +0200 ++++ luatex-beta-0.76.0/source/texk/web2c/luatexdir/image/epdf.h 2014-05-01 01:39:39.838462783 +0200 +@@ -37,6 +37,7 @@ + # include <sys/stat.h> + # include <dirent.h> + # include <poppler-config.h> ++# include <StructTreeRoot.h> + # include <goo/GooString.h> + # include <goo/gmem.h> + # include <goo/gfile.h> +diff -ruN luatex-beta-0.76.0.orig/source/texk/web2c/luatexdir/lua/lepdflib.cc luatex-beta-0.76.0/source/texk/web2c/luatexdir/lua/lepdflib.cc +--- luatex-beta-0.76.0.orig/source/texk/web2c/luatexdir/lua/lepdflib.cc 2013-04-05 12:58:37.000000000 +0200 ++++ luatex-beta-0.76.0/source/texk/web2c/luatexdir/lua/lepdflib.cc 2014-05-01 01:40:15.698461067 +0200 +@@ -48,25 +48,26 @@ + + //********************************************************************** + +-#define M_Annot "Annot" +-#define M_Annots "Annots" +-#define M_Array "Array" +-#define M_Catalog "Catalog" +-#define M_Dict "Dict" +-#define M_EmbFile "EmbFile" +-#define M_FileSpec "FileSpec" +-#define M_GooString "GooString" +-#define M_LinkDest "LinkDest" +-#define M_Link "Link" +-#define M_Links "Links" +-#define M_Object "Object" +-#define M_Page "Page" +-#define M_PDFDoc "PDFDoc" +-#define M_PDFRectangle "PDFRectangle" +-#define M_Ref "Ref" +-#define M_Stream "Stream" +-#define M_XRefEntry "XRefEntry" +-#define M_XRef "XRef" ++#define M_Annot "epdf.Annot" /* ls-hh: epdf.* gives better protection in registry */ ++#define M_Annots "epdf.Annots" ++#define M_Array "epdf.Array" ++#define M_Catalog "epdf.Catalog" ++#define M_Dict "epdf.Dict" ++#define M_EmbFile "epdf.EmbFile" ++#define M_FileSpec "epdf.FileSpec" ++#define M_GooString "epdf.GooString" ++#define M_LinkDest "epdf.LinkDest" ++#define M_Link "epdf.Link" ++#define M_Links "epdf.Links" ++#define M_Object "epdf.Object" ++#define M_Page "epdf.Page" ++#define M_PDFDoc "epdf.PDFDoc" ++#define M_PDFRectangle "epdf.PDFRectangle" ++#define M_Ref "epdf.Ref" ++#define M_Stream "epdf.Stream" ++#define M_StructTreeRoot "epdf.StructTreeRoot" ++#define M_XRefEntry "epdf.XRefEntry" ++#define M_XRef "epdf.XRef" + + //********************************************************************** + +@@ -96,6 +97,7 @@ + new_poppler_userdata(PDFRectangle); + new_poppler_userdata(Ref); + new_poppler_userdata(Stream); ++new_poppler_userdata(StructTreeRoot); + new_poppler_userdata(XRef); + + //********************************************************************** +@@ -573,7 +575,11 @@ + + m_poppler_get_GOOSTRING(Catalog, getBaseURI); + m_poppler_get_GOOSTRING(Catalog, readMetadata); ++#ifdef GETSTRUCTTREEROOT_RETURNS_OBJECT + m_poppler_get_poppler(Catalog, Object, getStructTreeRoot); ++#else ++m_poppler_get_poppler(Catalog, StructTreeRoot, getStructTreeRoot); ++#endif + + static int m_Catalog_findPage(lua_State * L) + { +@@ -2146,14 +2152,22 @@ + + static int m_PDFDoc_getStructTreeRoot(lua_State * L) + { ++#ifdef GETSTRUCTTREEROOT_RETURNS_OBJECT + Object *obj; ++#else ++ StructTreeRoot *obj; ++#endif + udstruct *uin, *uout; + uin = (udstruct *) luaL_checkudata(L, 1, M_PDFDoc); + if (uin->pd != NULL && uin->pd->pc != uin->pc) + pdfdoc_changed_error(L); + if (((PdfDocument *) uin->d)->doc->getCatalog()->isOk()) { + obj = ((PdfDocument *) uin->d)->doc->getStructTreeRoot(); ++#ifdef GETSTRUCTTREEROOT_RETURNS_OBJECT + uout = new_Object_userdata(L); ++#else ++ uout = new_StructTreeRoot_userdata(L); ++#endif + uout->d = obj; + uout->pc = uin->pc; + uout->pd = uin->pd; +@@ -2617,6 +2631,15 @@ + + //********************************************************************** + ++#ifdef LuajitTeX ++#define setfuncs_meta(type) \ ++ luaL_newmetatable(L, M_##type); \ ++ lua_pushvalue(L, -1); \ ++ lua_setfield(L, -2, "__index"); \ ++ lua_pushstring(L, "no user access"); \ ++ lua_setfield(L, -2, "__metatable"); \ ++ luaL_register(L, NULL, type##_m) ++#else + #define setfuncs_meta(type) \ + luaL_newmetatable(L, M_##type); \ + lua_pushvalue(L, -1); \ +@@ -2624,6 +2647,7 @@ + lua_pushstring(L, "no user access"); \ + lua_setfield(L, -2, "__metatable"); \ + luaL_setfuncs(L, type##_m, 0) ++#endif + + int luaopen_epdf(lua_State * L) + { +@@ -2646,6 +2670,10 @@ + setfuncs_meta(XRef); + setfuncs_meta(XRefEntry); + ++#ifdef LuajitTeX ++ luaL_register(L, "epdf", epdflib_f); ++#else + luaL_newlib(L, epdflib_f); ++#endif + return 1; + } diff --git a/dev-tex/luatex/luatex-0.76.0-r1.ebuild b/dev-tex/luatex/luatex-0.76.0-r1.ebuild new file mode 100644 index 000000000000..a9a4ee044204 --- /dev/null +++ b/dev-tex/luatex/luatex-0.76.0-r1.ebuild @@ -0,0 +1,104 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-tex/luatex/luatex-0.76.0-r1.ebuild,v 1.1 2014/04/30 23:46:58 dilfridge Exp $ + +EAPI=5 + +inherit libtool eutils texlive-common + +MY_P=${PN}-beta-${PV} +DESCRIPTION="An extended version of pdfTeX using Lua as an embedded scripting language." +HOMEPAGE="http://www.luatex.org/" +SRC_URI=" + http://foundry.supelec.fr/frs/download.php/file/15745/${MY_P}-source.tar.bz2 + http://foundry.supelec.fr/frs/download.php/file/15747/${MY_P}-doc.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="" +IUSE="doc" + +RDEPEND="dev-libs/zziplib + >=media-libs/libpng-1.4:0= + >=x11-libs/cairo-1.12 + >x11-libs/pixman-0.18 + app-text/poppler:=[xpdf-headers(+)] + sys-libs/zlib + >=dev-libs/kpathsea-6.1.0_p20120701" +DEPEND="${RDEPEND} + virtual/pkgconfig" + +S="${WORKDIR}/${MY_P}/source" + +src_prepare() { + epatch "${FILESDIR}/remove-zlib-version-check.patch" \ + "${FILESDIR}/includes.patch" \ + "${FILESDIR}/poppler026.patch" + S="${S}/build-aux" elibtoolize --shallow +} + +src_configure() { + # Too many regexps use A-Z a-z constructs, what causes problems with locales + # that don't have the same alphabetical order than ascii. Bug #244619 + # So we set LC_ALL to C in order to avoid problems. + export LC_ALL=C + + cd "${S}/texk/web2c" + econf \ + --disable-cxx-runtime-hack \ + --disable-all-pkgs \ + --disable-mp \ + --disable-ptex \ + --disable-tex \ + --disable-mf \ + --disable-largefile \ + --disable-ipc \ + --disable-shared \ + --enable-luatex \ + --enable-dump-share \ + --without-mf-x-toolkit \ + --without-x \ + --with-system-kpathsea \ + --with-kpathsea-includes="${EPREFIX}"/usr/include \ + --with-system-cairo \ + --with-system-pixman \ + --with-system-gd \ + --with-system-libpng \ + --with-system-teckit \ + --with-system-zlib \ + --with-system-t1lib \ + --with-system-xpdf \ + --with-system-poppler \ + --with-system-zziplib \ + --with-system-ptexenc \ + --disable-multiplatform +} + +src_compile() { + texk/web2c/luatexdir/getluatexsvnversion.sh || die + cd "${WORKDIR}/${MY_P}/source/texk/web2c" + emake luatex +} + +src_install() { + cd "${WORKDIR}/${MY_P}/source/texk/web2c" + emake DESTDIR="${D}" bin_PROGRAMS="luatex" SUBDIRS="" nodist_man_MANS="" \ + install-exec-am + + dodoc "${WORKDIR}/${MY_P}/README" luatexdir/NEWS + cp source/texk/web2c/man + cp man/luatex.man "${T}/luatex.1" + doman "${T}/luatex.1" + use doc && dodoc "${WORKDIR}/${MY_P}/manual/"*.pdf +} + +pkg_postinst() { + if ! has_version '>=dev-texlive/texlive-basic-2008' ; then + elog "Note that this package does not install many files, mainly just the" + elog "${PN} executable, which needs other files in order to be" + elog "useful. Please consider installing a recent TeX distribution such as" + elog "TeX Live 2008 or later to take advantage of the full power of" + elog "${PN} ." + fi + efmtutil-sys +} |