From 2b7c38d34e089b7bd7c5dee0a464d4bfc137d6ee Mon Sep 17 00:00:00 2001 From: Stefan Huber Date: Thu, 13 Jan 2011 22:44:32 +0100 Subject: [PATCH] media-gfx/ipe-7.0.13-r1: get rid of browser use flags --- media-gfx/ipe/Manifest | 1 + media-gfx/ipe/ipe-7.0.13-r1.ebuild | 95 ++++++++++++++++++++++++++++++ 2 files changed, 96 insertions(+) create mode 100644 media-gfx/ipe/ipe-7.0.13-r1.ebuild diff --git a/media-gfx/ipe/Manifest b/media-gfx/ipe/Manifest index 8c58f9c..fcfbf8b 100644 --- a/media-gfx/ipe/Manifest +++ b/media-gfx/ipe/Manifest @@ -4,4 +4,5 @@ DIST ipe-7.0.12-src.tar.gz 1304738 RMD160 2b70844cd8148e459fc9875fcc6923d0da899d DIST ipe-7.0.13-src.tar.gz 1318709 RMD160 a753fff1dcb7437adf3ce7bbb2a4b9be2aa7d077 SHA1 17471156d5becfd60147f94c765fbbf2c57e1782 SHA256 942335830bb1397a514b7eafdbb1929df4598a7b080296b05f8051f7c08ca295 EBUILD ipe-7.0.10.ebuild 2056 RMD160 c5ad5b0002cf557670353aec0bb9566253e35de2 SHA1 ce30d826bab989f4b6129cbe41a90a9cfddd376d SHA256 e0a1207c5f471cdded798cbeadc748f19805ce57adf9c3a6766785457a71e0ac EBUILD ipe-7.0.12.ebuild 2318 RMD160 5cb5185fb17319862f196078a355f5b74c604d46 SHA1 f8b136bc1f8dd1d09c31cfec54dbeb4150d66956 SHA256 b7274ac0975d384c5b73f83c580346eb2e68b684f6234c55c64bee5fe702be46 +EBUILD ipe-7.0.13-r1.ebuild 2568 RMD160 e0f62d77eaa84a4d8b5029552d6c6b9f29f90ebd SHA1 5970aad7f91c05a2cb52452072d89ba12fb7bbff SHA256 a2c93051a772cc1dfa89c9046c03172b81c33793295679693efb817105df4f6d EBUILD ipe-7.0.13.ebuild 2844 RMD160 25228c648129cce0c51da1b0e0819e87bba2bfdc SHA1 733af4d32fbe065a6d68308d9a1664447a7eb494 SHA256 4627036656d6aa6a4ce54b1fa86b5e94b8432048ec9591200a00e425c2e1eb60 diff --git a/media-gfx/ipe/ipe-7.0.13-r1.ebuild b/media-gfx/ipe/ipe-7.0.13-r1.ebuild new file mode 100644 index 0000000..8eb12ee --- /dev/null +++ b/media-gfx/ipe/ipe-7.0.13-r1.ebuild @@ -0,0 +1,95 @@ +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI="2" +inherit eutils toolchain-funcs qt4-r2 + +DESCRIPTION="A drawing editor which creates figures for inclusion in LaTeX documents and makes PDF presentations." +HOMEPAGE="http://ipe7.sourceforge.net/" +SRC_URI="mirror://sourceforge/ipe7/ipe/${P}-src.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~x86" +RESTRICT="mirror" +# highprec: applies patch in order to write coordinates with higher precision +IUSE="highprec" + +DEPEND=" + app-text/texlive-core + >=dev-lang/lua-5.1 + >=media-libs/freetype-2.1.8 + sys-libs/zlib + >=x11-libs/cairo-1.8.0 + >=x11-libs/qt-core-4.5:4 + >=x11-libs/qt-gui-4.5:4 + " + +S=${S}/src +COMMONDIR=/usr/share/ipe/common + + +search_urw_fonts() { + local texmfdist="$(kpsewhich -var-value=TEXMFDIST)" # colon-separated list of paths + local urwdir=fonts/type1/urw # according to TeX directory structure + local IFS="${IFS}:" # add colon as field separator + for dir in ${texmfdist}; do + if [[ -d "${dir}/${urwdir}" ]]; then + URWFONTDIR="${dir}/${urwdir}" + return 0 + fi + done + + return 1 +} + +src_prepare() { + if use highprec; then + einfo "Adding patch for higher output precision" + epatch "${FILESDIR}"/${PN}-outputprecision.patch + fi +} + +pkg_setup() { + if search_urw_fonts; then + einfo "URW fonts found in ${URWFONTDIR}." + else + ewarn "Could not find directory containing URW fonts. Ipe will not" + ewarn "function properly without them." + fi +} + +src_compile() { + # fix detection of lua + sed -i -e 's/lua5.1/lua/g' config.mak || die + # don't strip installed binaries + sed -i -e 's/install -s/install/' common.mak || die + # use moc instead of moc-qt4 + sed -i -e 's/moc-qt4/moc/' config.mak || die + + # -j1, since there are no deps in the Makefiles on libipe + emake -j1 CXX=$(tc-getCXX) IPEPREFIX="/usr" \ + IPEDOCDIR="/usr/share/doc/${PF}" || die "emake failed" +} + +src_install() { + emake install IPEPREFIX="/usr" IPEDOCDIR="/usr/share/doc/${PF}" \ + INSTALL_ROOT="${D}" || die "emake install failed" + dodoc ../{news,readme}.txt || die + + # Link style sheets + if [ -d $COMMONDIR/styles ]; then + einfo "Linking common style sheets from $COMMONDIR" + for f in $COMMONDIR/styles/*; do + einfo " Linking ${f##*/}" + dosym $f usr/share/ipe/${PV}/styles/${f##*/} + done + + elog "Style sheets from $COMMONDIR/styles have been symlinked to" + elog "the style sheet directory of ${P}. If you add additional" + elog "style sheets later to $COMMONDIR/styles you may symlink" + elog "them by hand to '/usr/share/ipe/${PV}/styles/'." + fi +} + -- 2.39.5