# vim: set syn=sh et ai sw=2 st=2 ts=2 tw=0:
#Packager: JRD <jrd@enialis.net>

pkgname=libgit2
pkgver=0.17.0
pkgrel=1cp
source=(https://github.com/downloads/$pkgname/$pkgname/$pkgname-$pkgver.tar.gz)
sourcetemplate=http://people.salixos.org/jrd/salix/$pkgname/$pkgver-\$arch-$pkgrel/
docs=("readme" "install" "copying" "changelog" "authors" "news" "todo")
url=http://libgit2.github.com/

slackdesc=\
(
#|-----handy-ruler------------------------------------------------------|
"$pkgname (a linkable library for Git)"
"libgit2 is a portable, pure C implementation of the Git core methods"
"provided as a re-entrant linkable library with a solid API, allowing"
"you to write native speed custom Git applications in any language"
"which supports C bindings."
)


build() {
  cd $SRC/$pkgname-$pkgver || return 1
  mkdir build && cd build || return 1
  cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr || return 1
  make -j $numjobs || return 1
  make install DESTDIR=$PKG || return 1
}
