# Maintainer: Drew DeVault pkgname=mdbook pkgver=0.3.4 pkgrel=0 pkgdesc="mdBook is a utility to create modern online books from Markdown files" url="https://rust-lang-nursery.github.io/mdBook" arch="x86_64 x86 armhf armv7 aarch64 ppc64le" # limited by cargo license="MPL-2.0" makedepends="rust cargo" source="$pkgname-$pkgver.tar.gz::https://github.com/rust-lang-nursery/mdBook/archive/v$pkgver.tar.gz" builddir="$srcdir/mdBook-$pkgver" export CARGO_HOME="$srcdir"/cargo build() { case "$CARCH" in x86) export CFLAGS="$CFLAGS -fno-stack-protector" ;; esac cargo build --release --verbose } check() { cargo test --all --release --verbose } package() { install -Dm755 target/release/mdbook "$pkgdir"/usr/bin/mdbook } sha512sums="593a09500c0f6a1f72855fd411de4c961b471565ee2029e03add5538d93cae0d73a67a808ade1ffc9834c21e518fae997076012084f01dc270564f1e55643169 mdbook-0.3.4.tar.gz"