blob: 358bf1c9b06357909cc40d531472ae7ad9666db7 (
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
56
57
58
59
60
61
62
63
|
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer:
pkgname=godep
pkgver=0_git20140825
pkgrel=0
pkgdesc="Dependency tool for go"
url="http://github.com/tools/godep"
arch="all"
license="BSD"
depends=""
depends_dev=""
makedepends="$depends_dev go mercurial"
install=""
subpackages=""
source="http://dev.alpinelinux.org/archive/$pkgname/$pkgname-$pkgver.tar.bz2"
disturl="dev.alpinelinux.org:/archive/$pkgname/"
_builddir="$srcdir"/src/github.com/tools/$pkgname.git
snapshot() {
local _date=$(date +%Y%m%d)
local _version=${verbase:-0}_git${_date}
abuild clean
mkdir -p "$srcdir" && cd "$srcdir"
hg clone http://code.google.com/p/go.tools \
"$srcdir"/src/code.google.com/p/go.tools || return 1
git clone git://github.com/tools/$pkgname.git \
"$srcdir"/src/github.com/tools/$pkgname.git || return 1
git clone git://github.com/kr/fs.git \
"$srcdir"/src/github.com/kr/fs || return 1
tar jcf $pkgname-$_version.tar.bz2 src || return 1
rsync --progress -La $pkgname-$_version.tar.bz2 $disturl || return 1
cd "$startdir"
sed -i -e "s/^pkgver=.*/pkgver=${_version}/" \
APKBUILD || return 1
abuild checksum
}
prepare() {
local i
cd "$_builddir"
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
esac
done
}
build() {
cd "$_builddir"
GOPATH="${srcdir}" go build
}
package() {
cd "$_builddir"
install -Dm755 godep.git \
"${pkgdir}/usr/bin/godep" || return 1
}
md5sums="9c26b522c2b9fbfe49afbf24b37cb943 godep-0_git20140825.tar.bz2"
sha256sums="0d5428715550af96fef003262bb010e8ed86721b6740a88fa3e566b3e66e74f5 godep-0_git20140825.tar.bz2"
sha512sums="842250d4359dcf812f58accb68305740d5a776b3f4f083420638ca12d7d5ee27c9f6b0eb252a46f8794c06926f6d739a5dd41a631499d42885af83ba190e79b9 godep-0_git20140825.tar.bz2"
|