1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
6 PYTHON_COMPAT=( python2_7 )
8 inherit elisp-common autotools eutils git-r3 python-single-r1
10 EGIT_REPO_URI="git://git.sv.gnu.org/lilypond.git"
12 DESCRIPTION="GNU Music Typesetter"
13 HOMEPAGE="http://lilypond.org/"
15 LICENSE="GPL-3 FDL-1.3"
17 LANGS=" ca cs da de el eo es fi fr it ja nl ru sv tr uk vi zh_TW"
18 IUSE="debug emacs profile vim-syntax ${LANGS// / linguas_}"
19 REQUIRED_USE="${PYTHON_REQUIRED_USE}"
21 RDEPEND=">=app-text/ghostscript-gpl-8.15
22 >=dev-scheme/guile-1.8.2[deprecated,regex]
26 >=x11-libs/pango-1.12.3
27 emacs? ( virtual/emacs )
33 ( >=dev-texlive/texlive-metapost-2013 >=dev-tex/metapost-1.803 )
34 <dev-texlive/texlive-metapost-2013
38 >=sys-apps/texinfo-4.11
44 # Correct output data for tests isn't bundled with releases
48 # make sure >=metapost-1.803 is selected if it's installed, bug 498704
49 if [[ ${MERGE_TYPE} != binary ]] && has_version ">=dev-tex/metapost-1.803" ; then
50 if [[ $(readlink "${EROOT}"/usr/bin/mpost) =~ mpost-texlive-* ]] ; then
51 einfo "Updating metapost symlink"
52 eselect mpost update || die
56 python-single-r1_pkg_setup
60 if ! use vim-syntax ; then
61 sed -i 's/vim//' GNUmakefile.in || die
65 sed -i 's/OPTIMIZE -g/OPTIMIZE/' aclocal.m4 || die
67 for lang in ${LANGS}; do
68 use linguas_${lang} || rm po/${lang}.po || die
72 sed -i "s/^AR=ar/AR=$(tc-getAR)/" stepmake/stepmake/library-vars.make || die
74 # remove bundled texinfo file (fixes bug #448560)
75 rm tex/texinfo.tex || die
81 # documentation generation currently not supported since it requires a newer
82 # version of texi2html than is currently in the tree
85 --with-texgyre-dir=/usr/share/fonts/tex-gyre \
86 --disable-documentation \
87 --disable-optimising \
89 $(use_enable debug debugging) \
90 $(use_enable profile profiling)
97 elisp-compile elisp/lilypond-{font-lock,indent,mode,what-beat}.el \
98 || die "elisp-compile failed"
103 emake DESTDIR="${D}" vimdir=/usr/share/vim/vimfiles install
105 # remove elisp files since they are in the wrong directory
106 rm -r "${ED}"/usr/share/emacs || die
109 elisp-install ${PN} elisp/*.{el,elc} elisp/out/*.el \
110 || die "elisp-install failed"
111 elisp-site-file-install "${FILESDIR}"/50${PN}-gentoo.el
114 python_fix_shebang "${ED}"
116 dodoc HACKING README.txt
120 use emacs && elisp-site-regen
124 use emacs && elisp-site-regen