summaryrefslogtreecommitdiff
path: root/community/lilypond/PKGBUILD
blob: 56849ac0b70277face0fef3ff20609d5b97146df (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# $Id: PKGBUILD 51540 2011-07-11 09:57:46Z spupykin $
# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Maintainer: Geoffroy Carrier <geoffroy@archlinux.org>
# Contributor: William Rea <sillywilly@gmail.com>
# Contributor: Robert Emil Berge <filoktetes@linuxophic.org>

pkgname=lilypond
pkgver=2.14.1
pkgrel=2
pkgdesc="An automated music engraving system"
arch=('i686' 'x86_64' 'mips64el')
url="http://lilypond.org"
license=('GPL')
depends=('guile' 'python2' 'texlive-core' 'ghostscript' 'pango' 'fontconfig')
makedepends=('flex' 'bison' 'gettext' 'mftrace' 'texinfo' 'fontforge' 't1utils'
	     'gsfonts' 'texi2html')
options=('emptydirs')
source=(http://download.linuxaudio.org/lilypond/sources/v2.14/$pkgname-$pkgver.tar.gz
	http://arch.p5n.pp.ru/~sergej/dl/lilypond-fonts.tar.bz2
	texlive-workaround.patch)
md5sums=('262cc7f92c907a7b479b55b3b37a9302'
         '2a0e18e5de17d740ada3861bf4d787ea'
         'ff32863f3eed67ac744e50bc4fc67a87')

build() {
  cd "$srcdir/$pkgname-$pkgver"

  # python2 fix
  for file in $(find . -name '*.py' -print); do
    sed -i 's_^#!.*/usr/bin/python_#!/usr/bin/python2_' $file
    sed -i 's_^#!.*/usr/bin/env.*python_#!/usr/bin/env python2_' $file
  done

  rm -rf python/out/
  patch -p1 <$srcdir/texlive-workaround.patch

  PYTHON=/usr/bin/python2 ./configure --prefix=/usr
  make
}

package() {
  cd "$srcdir/$pkgname-$pkgver"
  make DESTDIR="$pkgdir" install
  cp -a $srcdir/lilypond-fonts/usr/share/lilypond/current/fonts/* $pkgdir/usr/share/lilypond/$pkgver/fonts/
}