# Maintainer: Developer <dev@opalos.org>
# Maintainer: Developer <dev@opalos.org>

pkgname=libmd
pkgver=%version%
pkgrel=%release%
pkgdesc="Message Digest functions from BSD systems"
arch=('x86_64')
url="https://www.hadrons.org/software/libmd/"
license=('BSD')
depends=('glibc')
source=("https://libbsd.freedesktop.org/releases/$pkgname-$pkgver.tar.xz"{,.asc})
sha256sums=('1bd6aa42275313af3141c7cf2e5b964e8b1fd488025caf2f971f43b00776b332'
            'SKIP')
validpgpkeys=('4F3E74F436050C10F5696574B972BF3EA4AE57A3') # Guillem Jover

build() {
    cd ${pkgname}-${pkgver}
    ./configure --prefix=/usr
    make
}

check() {
    cd ${pkgname}-${pkgver}
    make -k check
}

package() {
    cd ${pkgname}-${pkgver}
    make DESTDIR="${pkgdir}" install
    install -Dm644 COPYING -t "${pkgdir}"/usr/share/licenses/${pkgname}/
}
