Commits

Taylor Venable committed 7357c86

Convert chicken-git to new PKGBUILD format

Comments (0)

Files changed (1)

chicken-git/PKGBUILD

 # Maintainer: Taylor Venable <taylor@metasyntax.net>
 
 pkgname='chicken-git'
-pkgver=20120103
+pkgver=4.5.0rc1.2185.g6edccb4
 pkgrel=1
 pkgdesc="A compiler for R5RS scheme, featuring handy extensions (git version)"
 arch=('i686' 'x86_64')
 makedepends=('git')
 provides=('chicken')
 conflicts=('chicken')
+source=('git://code.call-cc.org/chicken-core')
+sha256sums=('SKIP')
 
-_gitroot='git://code.call-cc.org/chicken-core'
 _gitname='chicken-core'
 
+pkgver() {
+    cd "${srcdir}/${_gitname}"
+    git describe --always | sed 's|-|.|g'
+}
+
 build() {
-  cd $startdir/src
-
-  if [[ -d $startdir/src/$_gitname ]]; then
-    cd $_gitname && git pull origin
-  else
-    git clone $_gitroot
-  fi
-
   # Make a copy of the source code so we can build there and keep the other
   # source directory (which we will update in subsequent builds) clean.