Commits

Taylor Venable committed aa6a4e3

Add sagittarius-scheme-hg

Comments (0)

Files changed (1)

sagittarius-scheme-hg/PKGBUILD

+# Maintainer: Taylor Venable <taylor@metasyntax.net>
+
+pkgname='sagittarius-scheme-hg'
+pkgver='1.10'
+pkgrel=1
+pkgdesc='R6RS Scheme/R7RS Scheme system'
+arch=('i686' 'x86_64')
+url='https://code.google.com/p/sagittarius-scheme/'
+license=('MIT')
+depends=('gc' 'zlib' 'libffi')
+makedepends=('mercurial' 'cmake')
+conflicts=('sagittarius-scheme')
+provides=('sagittarius-scheme')
+
+_hgrepo='https://code.google.com/p/sagittarius-scheme/'
+_hgname='sagittarius-scheme'
+
+build() {
+  msg 'Connecting to Mercurial server....'
+
+  if [ -d "$_hgname" ] ; then
+    cd "$_hgname"
+    hg pull -u
+    msg 'The local files are updated.'
+  else
+    hg clone "$_hgrepo" "$_hgname"
+  fi
+
+  msg 'Mercurial checkout done or server timeout'
+  msg 'Starting make...'
+
+  cd "$srcdir"
+
+  rm -rf "${_hgname}-build"
+  hg clone "$_hgname" "${_hgname}-build"
+
+  cd "${_hgname}-build"
+
+  mkdir 'build'
+  cd 'build'
+
+  cmake ..
+  make
+}
+
+package() {
+  cd "${srcdir}/${_hgname}-build"
+  make DESTDIR="$pkgdir" install
+}