diff options
author | graysky | 2018-03-31 11:33:27 -0400 |
---|---|---|
committer | graysky | 2018-03-31 11:33:27 -0400 |
commit | 6c8563db982eb5e55121f255498df5e797f6de72 (patch) | |
tree | 621dc9b301152e7fa392924d2e37a5636b833738 | |
download | aur-6c8563db982eb5e55121f255498df5e797f6de72.tar.gz |
initial upload
-rw-r--r-- | .SRCINFO | 15 | ||||
-rw-r--r-- | PKGBUILD | 43 |
2 files changed, 58 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..cb5c2322213c --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,15 @@ +pkgbase = distrobuilder + pkgdesc = System container image builder for LXC and LXD + pkgver = 215.5c6ad30 + pkgrel = 1 + url = https://github.com/lxc/distrobuilder + arch = x86_64 + license = APACHE + makedepends = gcc-go + makedepends = git + depends = lxc + source = git://github.com/lxc/distrobuilder.git + md5sums = SKIP + +pkgname = distrobuilder + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..c1e176ca1dde --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,43 @@ +# Maintainer: graysky <graysky AT archlinux DOT us> +# Contributor: Stéphane Graber <stgraber AT ubuntu DOT com> + +pkgname=distrobuilder +pkgver=215.5c6ad30 +pkgrel=1 +pkgdesc="System container image builder for LXC and LXD" +arch=('x86_64') +url="https://github.com/lxc/distrobuilder" +license=('APACHE') +depends=('lxc') +makedepends=('gcc-go' 'git') +source=(git://github.com/lxc/distrobuilder.git) +md5sums=('SKIP') + +pkgver() { + cd "$pkgname" + echo "$(git rev-list --count HEAD).$(git describe --always)" +} + +prepare() { + mkdir .gopath + export GOPATH="${srcdir}/.gopath" + export PATH="${GOPATH}/bin:${PATH}" +} + +build() { + cd "$pkgname" + go get -v -x github.com/lxc/distrobuilder/distrobuilder +} + +package() { + cd "$pkgname" + _examples="$GOPATH/src/github.com/lxc/$pkgname/doc/examples" + + install -Dm755 "$GOPATH/bin/$pkgname" "$pkgdir/usr/bin/$pkgname" + install -d "$pkgdir/usr/share/$pkgname" + install -d "$pkgdir/var/cache/$pkgname" + + for i in alpine.md archlinux.md centos.md debian.md fedora.md ubuntu.md; do + install -m644 "$_examples/$i" "$pkgdir/usr/share/$pkgname/$i" + done +} |