# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=easy-rsa
pkgver=3.0.3
pkgrel=0
pkgdesc="Simple shell based CA utility"
url="https://github.com/OpenVPN/easy-rsa"
arch="noarch"
license="GPL2"
depends="openssl"
subpackages="$pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/OpenVPN/easy-rsa/archive/v$pkgver.tar.gz"
builddir="$srcdir/$pkgname-$pkgver"

package() {
	cd "$builddir"
	mkdir -p "$pkgdir"/usr/share/easy-rsa \
		"$pkgdir"/usr/share/doc/easy-rsa
	cp -rp easyrsa3/* "$pkgdir"/usr/share/easy-rsa/ \
		&& cp -rp doc/* "$pkgdir"/usr/share/doc/easy-rsa/
}

sha512sums="edc097936bc2400f131e17fe8a94b81d009befa21622d51064262b2ea2f39b28774c51224353f8b1cba790bfc53b9184e5a39abf85aee0a9310f5e08380019d2  easy-rsa-3.0.3.tar.gz"