community/docker to 0.9.1-1, closes #797

This commit is contained in:
Kevin Mihelich 2014-04-08 22:33:13 +00:00
parent d990317071
commit 8094d4c84a

View file

@ -1,11 +1,11 @@
# $Id$ # $Id$
# Maintainer: Sébastien "Seblu" Luttringer # Maintainer: Sebastien "Seblu" Luttringer
# Add patch for ARM being a supported platform. # ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
# - ARM patches, adjustments
pkgname=docker pkgname=docker
_truever=0.9.0 pkgver=0.9.1
pkgver=${_truever%.*}
pkgrel=1 pkgrel=1
epoch=1 epoch=1
pkgdesc='Pack, ship and run any application as a lightweight container' pkgdesc='Pack, ship and run any application as a lightweight container'
@ -15,52 +15,45 @@ license=('Apache')
depends=('bridge-utils' 'iproute2' 'device-mapper' 'sqlite' 'systemd') depends=('bridge-utils' 'iproute2' 'device-mapper' 'sqlite' 'systemd')
makedepends=('git' 'go' 'btrfs-progs') makedepends=('git' 'go' 'btrfs-progs')
optdepends=('btrfs-progs: btrfs backend support' optdepends=('btrfs-progs: btrfs backend support'
'lxc: lxc driver support') 'lxc: lxc backend support')
# don't strip binaries! A sha1 is used to check binary consistency. # don't strip binaries! A sha1 is used to check binary consistency.
options=('!strip') options=('!strip')
install=$pkgname.install install=$pkgname.install
source=("git+https://github.com/dotcloud/docker.git#tag=v$_truever" source=("git+https://github.com/dotcloud/docker.git#tag=v$pkgver"
'docker-arm.patch' 'docker-arm.patch'
'btrfs-arm.patch') 'btrfs-arm.patch')
md5sums=('SKIP' md5sums=('SKIP'
'47cc1cdf900af66660bfa3402012ea71' '47cc1cdf900af66660bfa3402012ea71'
'1ec4b4b42eb80f2692cee757324370b0') '1ec4b4b42eb80f2692cee757324370b0')
# magic harcoded path
_magic=src/github.com/dotcloud
prepare() { prepare() {
mkdir -p "$_magic" cd "docker"
ln -sfn "../../../docker" "$_magic/docker" patch -p1 -i ../docker-arm.patch
cd "${srcdir}/docker" patch -p1 -i ../btrfs-arm.patch
patch -p1 <"${srcdir}/docker-arm.patch"
patch -p1 <"${srcdir}/btrfs-arm.patch"
find . -name '*.go' | xargs sed --in-place= -e 's/\/\/ +build amd64/\/\/ +build arm/' find . -name '*.go' | xargs sed --in-place= -e 's/\/\/ +build amd64/\/\/ +build arm/'
find . -name '*.go' | xargs sed --in-place= -e 's/\/\/ +build !linux !amd64/\/\/ +build !linux !arm/' find . -name '*.go' | xargs sed --in-place= -e 's/\/\/ +build !linux !amd64/\/\/ +build !linux !arm/'
find . -name '*.go' | xargs sed --in-place= -e 's/\/\/ +build linux,amd64/\/\/ +build linux,arm/' find . -name '*.go' | xargs sed --in-place= -e 's/\/\/ +build linux,amd64/\/\/ +build linux,arm/'
} }
build() { build() {
cd "$_magic/docker" cd docker
export GOPATH="$srcdir:$srcdir/$_magic/docker/vendor" export AUTO_GOPATH=1
./hack/make.sh dynbinary ./hack/make.sh dynbinary
} }
check() { #check() {
cd "$_magic/docker" # cd "$_magic/docker"
# Will be added upstream soon # # Will be added upstream soon
# ./hack/make.sh dyntest # ./hack/make.sh dyntest
} #}
package() { package() {
cd "$_magic/docker" cd docker
install -Dm755 "bundles/$_truever/dynbinary/docker-$_truever" "$pkgdir/usr/bin/docker" install -Dm755 "bundles/$pkgver/dynbinary/docker-$pkgver" "$pkgdir/usr/bin/docker"
install -Dm755 "bundles/$_truever/dynbinary/dockerinit-$_truever" "$pkgdir/usr/lib/docker/dockerinit" install -Dm755 "bundles/$pkgver/dynbinary/dockerinit-$pkgver" "$pkgdir/usr/lib/docker/dockerinit"
# completion # completion
install -Dm644 "contrib/completion/bash/docker" "$pkgdir/usr/share/bash-completion/completions/docker" install -Dm644 "contrib/completion/bash/docker" "$pkgdir/usr/share/bash-completion/completions/docker"
install -Dm644 "contrib/completion/zsh/_docker" "$pkgdir/usr/share/zsh/site-functions/_docker" install -Dm644 "contrib/completion/zsh/_docker" "$pkgdir/usr/share/zsh/site-functions/_docker"
# systemd # systemd
install -Dm644 "contrib/init/systemd/docker.service" "$pkgdir/usr/lib/systemd/system/docker.service" install -Dm644 "contrib/init/systemd/docker.service" "$pkgdir/usr/lib/systemd/system/docker.service"
} }
# vim:set ts=2 sw=2 et: