updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / ttapi-git / PKGBUILD
blob70db039c3b4c55861caafda139c4f46719ee21f3
1 # Maintainer: Eduardo Sánchez Muñoz <eduardosanchezmunoz@gmail.com>
3 pkgname=ttapi-git
4 pkgver=20110930
5 pkgrel=1
6 pkgdesc="Library developed in C to access the Tuenti social network."
7 arch=('i686' 'x86_64')
8 url="http://code.google.com/p/ttapi/"
9 license=('LGPL')
10 depends=('libdojson-git' 'libbytechain-git' 'libtextchain-git')
11 makedepends=('gcc' 'git' 'cmake' 'libdojson-git' 'libbytechain-git' 'libtextchain-git')
12 options=()
13 conflicts=('ttapi_pm_extractor' 'libttapi')
14 provides=('ttapi_pm_extractor' 'libttapi')
15 source=()
16 md5sums=()
18 _gitroot="https://code.google.com/p/ttapi/"
19 _gitname="ttapi"
21 build() {
22         cd "$srcdir"
23         
24         msg "Connecting to GIT server..."
25         
26         if [ -d $_gitname ]; then
27                 cd $_gitname && git pull origin
28                 msg "The local files are updated."
29         else
30                 git clone $_gitroot $_gitname
31         fi
32         
33         msg "GIT checkout done or server timeout"
34         msg "Starting make..."
35         
36         rm -rf "$srcdir/$_gitname-build"
37         mkdir -p "$srcdir/$_gitname-build"
38         cd "$srcdir/$_gitname-build"
39         
40         cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr "$srcdir/$_gitname/ttapi"
41         make
44 package() {
45         cd "$srcdir/$_gitname-build"
46         make DESTDIR="$pkgdir" install