updated on Mon Jan 16 00:01:41 UTC 2012
[aur-mirror.git] / kdevelop-git / PKGBUILD
blob06d6d7684b2f05c11909f2bea4984c8ff011562f
1 # Contributor: Jakub Schmidtke <sjakub-at-gmail-dot-com>
2 # Contributor: mosra <mosra@centrum.cz>
4 pkgname=kdevelop-git
5 pkgver=20110604
6 pkgrel=1
7 pkgdesc="A C/C++ development environment for KDE - GIT build"
8 arch=('i686' 'x86_64')
9 url="http://www.kdevelop.org/"
10 license=('GPL')
11 depends=('kdevplatform-git' 'kdebase-workspace')
12 makedepends=('cmake' 'automoc4' 'perl' 'git')
13 provides=('kdevelop')
14 conflicts=('kdevelop')
15 source=()
16 md5sums=()
18 _gitroot="git://anongit.kde.org/kdevelop"
19 _gitname="kdevelop"
21 build() {
22     cd "$srcdir"
23     msg "Connecting to GIT server...."
25     if [ -d $_gitname ] ; then
26         cd $_gitname
28         # Change remote url to anongit
29         if [ -z "$(git remote -v | grep anongit)" ] ; then
30             git remote set-url origin ${_gitroot}
31         fi
33         git pull origin
34         msg "The local files are updated."
35     else
36         git clone $_gitroot $_gitname
37     fi
39     msg "GIT checkout done or server timeout"
40     msg "Starting make..."
42     mkdir -p "$srcdir/build"
43     cd "$srcdir/build"
45     cmake ../${_gitname} \
46         -DCMAKE_INSTALL_PREFIX=/usr \
47         -DCMAKE_BUILD_TYPE=RELWITHDEBINFO
49     make
52 package() {
53     cd "$srcdir/build"
55     make DESTDIR="${pkgdir}" install