# Contributor: Sam Nystrom <sam@samnystrom.dev>
# Maintainer: Sam Nystrom <sam@samnystrom.dev>
pkgname=seaward
pkgver=1.0.3
pkgrel=0
pkgdesc="Crawler which searches for links or a specified word in a website"
url="https://github.com/M3nny/seaward"
# s390x: nix crate
arch="all !s390x"
license="MIT"
makedepends="cargo cargo-auditable openssl-dev"
source="$pkgname-$pkgver.tar.gz::https://github.com/M3nny/seaward/archive/refs/tags/$pkgver.tar.gz
	cargo-update-libc.patch
	cargo-update-version.patch
	"
options="!check" # no tests

prepare() {
	default_prepare

	cargo fetch --target="$CTARGET" --locked
}

build() {
	cargo auditable build --frozen --release
}

package() {
	install -Dm755 target/release/seaward -t "$pkgdir"/usr/bin/
}

sha512sums="
490c7fd725beb84b8ad5fdf77e806af7fb0370802d9098b5b299b18dc054111dbeac0df9cb03fe3ef2dac9d032611512b0e879bd1e58107c63d372c70b040b04  seaward-1.0.3.tar.gz
71c9509002516ed03f9e35aa3c56e51ca2e207c07a7b3ab68174f64899c261e8e59b101a5c1685df5da6284019561c00b69543c89166e152e4a3ba40bcd1393a  cargo-update-libc.patch
df953ba1898a3865bf47d3f3f51a32edcd74a690682dc606596730700d2f133471c6e0629353866a66b043dfc23e4abf64b30086e3bff82f2a6cdf8218d54ff6  cargo-update-version.patch
"
