updated on Wed Jan 18 16:10:53 UTC 2012
[aur-mirror.git] / lyx-ng / PKGBUILD
blob8ba16a0a90e40434cb2e9fba5ab812373c5c1fd6
1 # Maintainer: Martin F. Schumann <mfs@mfs.name>
3 pkgname=lyx-ng
4 pkgver=2.0.2
5 pkgrel=2
6 pkgdesc="An advanced open-source document processor. Newest stable version."
7 arch=('i686' 'x86_64')
8 url="http://www.lyx.org"
9 depends=('qt' 'texlive-core' 'python2' 'perl' 'imagemagick' 'enchant' 'boost-libs' 'libmythes')
10 makedepends=('boost')
11 conflicts=('lyx')
12 license=('GPL')
13 source=(ftp://ftp.lip6.fr/pub/lyx/stable/2.0.x/lyx-$pkgver.tar.xz
14         lyx.desktop lyxrc.dist)
15 backup=('etc/lyx/lyxrc.dist')
16 install=lyx.install
17 sha1sums=('47b9c7fa73ef827907622cefe78421a356481ca9'
18           'e2b8f6d6cdeec41e1d5795167f5557e4a6ea28ad'
19           '56416642cc3da2a13b87b84e6b87c1a239f3d09a')
20         
21 build() {
22   cd "${srcdir}/lyx-${pkgver}"
23   find . -type f -exec sed -i 's|#!.*python|#!/usr/bin/env python2|' {} +
24   sed -i 's|"python|"python2|' lib/configure.py src/support/os.cpp
25   export CXXFLAGS="$CXXFLAGS -fpermissive"
26   ./configure --prefix=/usr \
27     --with-frontend=qt4 --without-included-boost \
28     --without-included-mythes
29   make
32 package() {
33   cd "${srcdir}/lyx-${pkgver}"
35   make DESTDIR="${pkgdir}" install
37   # install desktop entry
38   install -Dm644 "${srcdir}/lyx.desktop" \
39     "${pkgdir}/usr/share/applications/lyx.desktop"
40   install -Dm644 "lib/images/lyx.png" \
41     "${pkgdir}/usr/share/pixmaps/lyx.png"
43   # install default config file
44   install -Dm644 "${srcdir}/lyxrc.dist" "${pkgdir}/etc/lyx/lyxrc.dist"
45   ln -sf /etc/lyx/lyxrc.dist "${pkgdir}/usr/share/lyx/lyxrc.dist"