-# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~x86"
-IUSE=""
+IUSE="highprec"
RDEPEND="app-text/texlive-core
dev-lang/lua
virtual/pkgconfig"
S="${WORKDIR}/${P}/src"
+COMMONDIR=/usr/share/ipe/common
search_urw_fonts() {
# colon-separated list of paths
config.mak || die
sed -i -e 's/install -s/install/' common.mak || die
+ if use highprec; then
+ einfo "Adding patch for higher output precision"
+ epatch "${FILESDIR}"/${PN}-outputprecision.patch
+ fi
}
src_compile() {
dodoc ../{news,readme}.txt
doicon ipe/icons/ipe.png
make_desktop_entry ipe Ipe ipe
+ # 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
}