updated on Wed Jan 25 08:34:36 UTC 2012
[aur-mirror.git] / avogadro-git / PKGBUILD
blobc174bfc97061ad2d0bac9157b4b88926f6777da2
1 # $Id: PKGBUILD 100347 2010-11-22 23:25:14Z andrea $
2 # Maintainer: Andrea Scarpino <andrea@archlinux.org>
3 # Contributor: Nick B <Shirakawasuna at gmail _dot_com>
5 pkgname=avogadro-git
6 pkgver=20101219
7 pkgrel=2
8 pkgdesc="An advanced molecular editor based on Qt"
9 arch=('i686' 'x86_64')
10 url="http://avogadro.openmolecules.net/wiki/Main_Page"
11 license=('GPL2')
12 depends=('eigen' 'openbabel' 'python2-qt' 'boost-libs' 'glew' 'python-numpy')
13 makedepends=('cmake' 'boost' 'git')
14 conflicts=('avogadro')
15 provides=('avogadro')
16 source=('sip-4.11.patch' 'fix-pycapsule.patch')
17 md5sums=('e78c3f96d0dc702947f75de1c094f580'
18          '45b0f3be5913575311e92b74a5520966')
20 _gitroot="git://avogadro.git.sourceforge.net/gitroot/avogadro/avogadro"
21 _gitname="avogadro"
24 build() {
25   cd "$srcdir"
27   if [ -d "$srcdir/$_gitname" ] ; then
28     cd "$_gitname" && git pull origin
29    else
30     git clone "$_gitroot"
31   fi
33   cd "${srcdir}/$_gitname"
34   patch -Np1 -i ${srcdir}/sip-4.11.patch || true
35   patch -Np1 -i ${srcdir}/fix-pycapsule.patch || true
37   mkdir -p "${srcdir}/${_gitname}-build"
38   cd "${srcdir}/${_gitname}-build"
41   cmake "../${_gitname}" \
42     -DCMAKE_BUILD_TYPE=Release \
43     -DCMAKE_INSTALL_PREFIX=/usr
44   make
47 package() {
48   cd "${srcdir}/${_gitname}-build"
49   make DESTDIR="${pkgdir}" install