blob: b66eb7d29d31dc8e9e17902d216cc29e6fe679ab (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=lxd
pkgver=2.17
pkgrel=0
pkgdesc="a container hypervisor and a new user experience for LXC"
url="https://linuxcontainers.org/lxd/"
arch="all"
license="Apache-2.0"
depends="acl xz netcat-openbsd cgmanager squashfs-tools rsync shadow-uidmap lxc ip6tables dnsmasq ca-certificates"
makedepends="lxc-dev protobuf-dev rsync go gettext-dev linux-headers acl-dev"
install="$pkgname.pre-install"
options="!check"
source="https://linuxcontainers.org/downloads/$pkgname/$pkgname-$pkgver.tar.gz
lxd-dont-go-get.patch
$pkgname.confd
$pkgname.initd"
_project="github.com/lxc/lxd"
builddir="$srcdir"/lxd-$pkgver
prepare() {
cd "$builddir"
# symlink links to a path outside of $GOPATH
# copy src to project directory to replace the symlink
rm -f dist/src/"$_project"
rsync -a . --exclude="dist" dist/src/"$_project"
default_prepare
}
build() {
cd "$builddir"
export GOPATH="$builddir/dist"
#https://github.com/lxc/lxd/issues/496
export CGO_LDFLAGS=-lintl
make -C dist/src/"$_project"
}
package() {
cd "$builddir"
for i in fuidshift lxc ; do
install -Dm 755 "dist/bin/$i" \
"$pkgdir/usr/bin/$i"
done
install -Dm755 "dist/bin/lxd" "$pkgdir/usr/sbin/lxd"
install -Dm755 "$srcdir"/lxd.initd \
"$pkgdir"/etc/init.d/lxd
install -Dm644 "$srcdir"/lxd.confd \
"$pkgdir"/etc/conf.d/lxd
}
sha512sums="e30b2893e1f581e4774e3055a738d086175c0d3f35038d900daca5b37e7aed75bf33035dfbde58da14d3cc5d7895f5a3748608151ee0f0a14e084b86e5fda34f lxd-2.17.tar.gz
e2c0c96d0efc33e459cf14365f01d60b73ed03f028d36ca5ea27cd647f5d2a91ec61bcf2723437f7b930aec6ebabac3697e0e3adc6b2918817833c9f182aab49 lxd-dont-go-get.patch
bc32c71f2ce10f508433e1e4651c08c18e8a17e9419a7ce391c0f127fc7cf378c665178926b35eae8813e290d9c5eab3ceb605679fd32efdf2cf98a57cee4127 lxd.confd
94de0c0d5ab63463a929a4151359950b1117d0ada5ccf0944311cc70c6b6d4c437ccb4158734ab35db67bfb4abc437074c3f3515be4531f63adc74da21fefb5b lxd.initd"
|