pkgbuilds/yay/PKGBUILD

38 lines
1021 B
Bash
Raw Permalink Normal View History

2023-08-30 19:27:59 -06:00
# Maintainer: Jguer <pkgbuilds at jguer.space>
pkgname=yay
pkgver=12.1.0
pkgrel=1
pkgdesc="Yet another yogurt. Pacman wrapper and AUR helper written in go."
arch=('i686' 'pentium4' 'x86_64' 'arm' 'armv7h' 'armv6h' 'aarch64' 'riscv64')
url="https://github.com/Jguer/yay"
options=(!lto)
license=('GPL3')
depends=(
'pacman>5'
'git'
)
optdepends=(
'sudo: privilege elevation'
'doas: privilege elevation'
)
makedepends=('go>=1.19')
source=("${pkgname}-${pkgver}.tar.gz::https://github.com/Jguer/yay/archive/v${pkgver}.tar.gz")
sha256sums=('a13d6c02eaaef7ed9ac77723d220fa6101aef129c6edb785d74cadba6547f6d0')
build() {
export GOPATH="$srcdir"/gopath
export CGO_CPPFLAGS="${CPPFLAGS}"
export CGO_CFLAGS="${CFLAGS}"
export CGO_CXXFLAGS="${CXXFLAGS}"
export CGO_LDFLAGS="${LDFLAGS}"
export CGO_ENABLED=1
cd "$srcdir/$pkgname-$pkgver"
make VERSION=$pkgver DESTDIR="$pkgdir" PREFIX="/usr" build
}
package() {
cd "$srcdir/$pkgname-$pkgver"
make VERSION=$pkgver DESTDIR="$pkgdir" PREFIX="/usr" install
}