Skip to content
Snippets Groups Projects
Commit dc83ffa9 authored by Drew DeVault's avatar Drew DeVault Committed by Leo
Browse files

community/alertmanager: fix LDFLAGS issues

This should(?) fix the build on aarch64.
parent af5b1a89
No related merge requests found
# Maintainer: Drew DeVault <sir@cmpwn.com>
pkgname=alertmanager
pkgver=0.20.0
pkgrel=0
pkgrel=1
pkgdesc="Prometheus Alertmanager"
url="https://github.com/prometheus/alertmanager"
arch="all"
......@@ -18,22 +18,19 @@ builddir="$srcdir/$pkgname-$pkgver"
options="!check" # timing-sensitive upstream tests
build() {
ldflags="-extldflags $LDFLAGS \
-X github.com/prometheus/common/version.Version=$pkgver \
-X github.com/prometheus/common/version.Revision=$pkgrel \
-X github.com/prometheus/common/version.Branch=Alpine \
-X github.com/prometheus/common/version.BuildUser=Alpine \
-X github.com/prometheus/common/version.BuildDate=2020-01-08"
go build \
-trimpath \
-mod=vendor \
-ldflags "$ldflags" \
./cmd/alertmanager
go build \
-trimpath \
-mod=vendor \
-ldflags "$ldflags" \
./cmd/amtool
for cmd in amtool alertmanager
do
go build \
-trimpath \
-mod=vendor \
-ldflags "-extldflags \"$LDFLAGS\" \
-X github.com/prometheus/common/version.Version=$pkgver \
-X github.com/prometheus/common/version.Revision=$pkgrel \
-X github.com/prometheus/common/version.Branch=Alpine \
-X github.com/prometheus/common/version.BuildUser=Alpine \
-X github.com/prometheus/common/version.BuildDate=2020-01-08" \
./cmd/$cmd
done
}
check() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment