# $Id: PKGBUILD 111096 2014-05-13 17:47:05Z jsteel $ # Maintainer: Jonathan Steel # Contributor: Ido Rosen # Contributor: Brett Hoerner # Contributor: Jochen Schalanda # Contributor: Mathieu Clabaut # Contributor: helios # Contributor: George Ornbo # Contributor: Niklas Heer # Contributor: Steven Nance pkgname=vagrant pkgver=1.6.2 pkgrel=1 pkgdesc="Build and distribute virtualized development environments" arch=('i686' 'x86_64') url="http://vagrantup.com" license=('MIT') options=('!emptydirs') depends=('ruby' 'curl' 'lzo2' 'libidn' 'rtmpdump') makedepends=('git') source=(http://github.com/mitchellh/$pkgname/archive/v$pkgver.tar.gz http://pkgbuild.com/~jsteel/aur/$pkgname/substrate_archlinux_$CARCH.zip) md5sums=('99ee5b69d9e3966a8ed081e46d1844ba') [[ $CARCH == i686 ]] && md5sums[3]='c04042b24de56d18a041bc005e5ecaa4' [[ $CARCH == x86_64 ]] && md5sums[3]='53d8a137e0b50fee8509a7d1c15fd33b' build() { cd "$srcdir"/$pkgname-$pkgver EMBEDDED_DIR="$srcdir"/substrate/embedded echo -n $pkgver > "$srcdir"/substrate/${pkgname}_version "$EMBEDDED_DIR"/bin/gem build $pkgname.gemspec GEM_PATH="$EMBEDDED_DIR"/gems GEM_HOME="$GEM_PATH" \ GEMRC="$EMBEDDED_DIR"/etc/gemrc CPPFLAGS="-I$EMBEDDED_DIR"/include \ LDFLAGS="-L$EMBEDDED_DIR"/lib PATH="$EMBEDDED_DIR/bin:$PATH" \ "$EMBEDDED_DIR"/bin/gem install $pkgname-$pkgver.gem --no-ri --no-rdoc } package() { install -d "$pkgdir"/{opt/,usr/bin/,usr/share/bash-completion/completions/} cp -r "$srcdir"/substrate/ "$pkgdir"/opt/$pkgname/ ln -s /opt/$pkgname/bin/$pkgname "$pkgdir"/usr/bin/$pkgname ln -s /opt/$pkgname/embedded/gems/gems/$pkgname-$pkgver/contrib/bash/completion.sh \ "$pkgdir"/usr/share/bash-completion/completions/$pkgname install -Dm644 "$srcdir"/$pkgname-$pkgver/LICENSE \ "$pkgdir"/usr/share/licenses/$pkgname/LICENSE }