upgpkg: libversion 3.0.1-2

Add tests.
This commit is contained in:
George Rawlinson 2021-12-14 02:10:10 +00:00
parent c38d7c8503
commit 1db010ad2e
Signed by: grawlinson
GPG key ID: E0959FEA8B550539

View file

@ -1,27 +1,35 @@
# Maintainer: KokaKiwi <kokakiwi+aur at kokakiwi dot net>
# Maintainer: George Rawlinson <grawlinson@archlinux.org>
# Contributor: KokaKiwi <kokakiwi+aur at kokakiwi dot net>
pkgname=libversion
pkgver=3.0.1
pkgrel=1
pkgrel=2
pkgdesc='Advanced version string comparison library'
url='https://github.com/repology/libversion'
license=('MIT')
arch=('x86_64')
depends=('gcc-libs')
makedepends=('cmake')
provides=('libversion.so')
source=("$pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz")
sha512sums=('b7b10d2d71eba53972e51cf25b32ef429f703efc83810e4f480db34216bd0dc43382a492af947f6f3da65e1a3b939c9a61fe90f9d1d3b1737a5ba7615934d5b8')
b2sums=('d65f4d415e5c17abf49b641bb7ecee08ccd07c747bfddb43c6d0586a6d48bbb4e87b607f0812abb3da7c5696e928c79ebd1c0a00d7baaf5be75caffe7b18a2e7')
build() {
prepare() {
cmake \
-B build \
-S "$pkgname-$pkgver" \
-D CMAKE_INSTALL_PREFIX=/usr
}
build() {
cmake --build build
}
check() {
cd build
ctest --output-on-failure
}
package() {
DESTDIR="$pkgdir" cmake --install build