Skip to content

Instantly share code, notes, and snippets.

@Psirus
Created May 3, 2014 14:37
Show Gist options
  • Save Psirus/00d3e873c22e5ee6d8e7 to your computer and use it in GitHub Desktop.
Save Psirus/00d3e873c22e5ee6d8e7 to your computer and use it in GitHub Desktop.
PyMbs PKGBUILD
# Maintainer: Christoph Pohl <christoph.pohl1[at]mailbox[dot]tu-dresden[dot]de>
pkgname=PyMbs-hg
pkgver=0.2.2.r1752
pkgrel=1
pkgdesc="A Python tool to model multibody systems"
arch=('i686' 'x86_64')
url="http://www.bitbucket.org/pymbs/pymbs"
license=('LGPL')
depends=('python2-numpy' 'python2-scipy' 'python2-matplotlib' 'vtk' 'python2-pyqt4' 'python2-h5py' )
makedepends=('cmake' 'mercurial')
checkdepends=('python2-mock')
source=('hg+https://bitbucket.org/pymbs/pymbs')
md5sums=('SKIP')
_hgroot='https://bitbucket.org/pymbs/pymbs'
_hgrepo='pymbs'
build() {
cd "$srcdir"
msg "Connecting to Mercurial server...."
if [[ -d "$_hgrepo" ]]; then
cd "$_hgrepo"
hg pull -u
msg "The local files are updated."
else
hg clone "$_hgroot" "$_hgrepo"
fi
msg "Mercurial checkout done or server timeout"
msg "Starting build..."
rm -rf "$srcdir/$_hgrepo-build"
cp -r "$srcdir/$_hgrepo" "$srcdir/$_hgrepo-build"
}
package() {
cd "$srcdir/$_hgrepo-build"
python2 setup.py install --root="$pkgdir/" --optimize=1
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment