aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--community/caddy/APKBUILD9
1 files changed, 6 insertions, 3 deletions
diff --git a/community/caddy/APKBUILD b/community/caddy/APKBUILD
index e60dce9e24..8cbbb7a4c2 100644
--- a/community/caddy/APKBUILD
+++ b/community/caddy/APKBUILD
@@ -7,7 +7,10 @@ pkgdesc="Fast, cross-platform HTTP/2 web server with automatic HTTPS"
url="https://caddyserver.com/"
arch="all !s390x"
license="Apache-2.0"
-options="!check" # fails on builders due to containerization edge-cases
+# tests fail on x86 builders due to containerization edge-cases
+case $CARCH in
+ x86) options="!check";;
+esac
depends="ca-certificates"
makedepends="go libcap bash"
subpackages="$pkgname-openrc"
@@ -21,6 +24,8 @@ source="$pkgname-$pkgver.tar.gz::https://github.com/mholt/$pkgname/archive/v$pkg
"
builddir="$srcdir/src/github.com/mholt/$pkgname"
+export GOPATH="$srcdir"
+
prepare() {
mkdir -p ${builddir%/*}
mv "$srcdir"/$pkgname-$pkgver "$builddir"/
@@ -29,14 +34,12 @@ prepare() {
}
build() {
- export GOPATH="$srcdir"
GO111MODULE=on go build -v -o bin/caddy -ldflags \
"-X github.com/mholt/caddy/caddy/caddymain.gitTag=$pkgver" \
./caddy
}
check() {
- export GOPATH="$srcdir"
GO111MODULE=on go test ./...
}