aboutsummaryrefslogtreecommitdiffstats
path: root/community/hugo/APKBUILD
blob: 217239a1a986faaeaad1e781ca7d4920333be847 (plain) (blame)
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
# Contributor: Thomas Boerger <thomas@webhippie.de>
# Maintainer: Thomas Boerger <thomas@webhippie.de>
pkgname=hugo
pkgver=0.43
pkgrel=0
pkgdesc="A Fast and Flexible Static Site Generator built with love in GoLang"
url="http://gohugo.io/"
arch="all !x86" # tests fails on x86
license="Apache-2.0"
depends=""
makedepends="go dep"
install=""
source="${pkgname}-${pkgver}.tar.gz::https://github.com/gohugoio/hugo/archive/v$pkgver.tar.gz
	drop-git-tests.patch"
builddir="$srcdir/src/github.com/gohugoio/$pkgname"

prepare() {
	mkdir -p ${builddir%/*}
	mv "$srcdir"/$pkgname-$pkgver "$builddir"/
	default_prepare
}

build() {
	cd "$builddir"
	export GOPATH="$srcdir"
	dep ensure -v
	go build -v -o bin/$pkgname
}

check() {
	cd "$builddir"
	export GOPATH="$srcdir"
	go test ./...
}

package() {
	install -Dm755 "$builddir"/bin/$pkgname "$pkgdir"/usr/bin/$pkgname
}

sha512sums="e98a6fe0143fb16fd7e2815166b54be6e448580e50a343216a21a1cc09415475830f6735dd86f6d457e9e831bfcb2d6eab95dc561665ce5f47a261d56acf09a4  hugo-0.43.tar.gz
31f212a444998a582c5c71beb9522e665242cf973322a4cfce2f756a24fae03b194b8aa33fde233212b9624f311f6dc56f123183f61bf8cd7f3cbd695e7b86c5  drop-git-tests.patch"