summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 45f54afe7ed5cdc7aadafc015b4275db388c2ff6 (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
# Maintainer: Marti Raudsepp <marti@juffo.org>
# Contributor: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor: Angel 'angvp' Velasquez <angvp[at]archlinux.com.ve>
# Contributor: Douglas Soares de Andrade <dsa@aur.archlinux.org>

pkgname=python-psycopg2-git
pkgver=20101209
pkgrel=1
pkgdesc="A PostgreSQL database adapter for the Python programming language."
arch=('i686' 'x86_64')
url="http://initd.org/projects/psycopg2"
options=(!strip) # to facilitate debugging of git builds
license=('LGPL3')
depends=('python2' 'postgresql-libs>=8.4.1')
conflicts=('python-psycopg2')
provides=('python-psycopg2=2.3.2')

_gitroot=git://luna.dndg.it/public/psycopg2.git
_gitname=psycopg2
_gitbranch=python2

build() {
  cd "$srcdir"
  msg "Connecting to GIT server...."

  if [ -d $_gitname ] ; then
    cd $_gitname && git pull origin
    msg "The local files are updated."
  else
    git clone $_gitroot $_gitname -b $_gitbranch
  fi

  msg "GIT checkout done or server timeout"
  msg "Starting make..."

  rm -rf "$srcdir/$_gitname-build"
  git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
  cd "$srcdir/$_gitname-build"
  #git branch $_gitbranch

  export CFLAGS='-ggdb'
  python2 setup.py install --root="$pkgdir"
}