blob: 104deed5dc7212287f74699b3947d7a487df98b3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
# Maintainer: George Rawlinson <grawlinson@archlinux.com>
# Maintainer: Caleb Maclennan <caleb@alerque.com>
# Contributor: Daniel M. Capella <polyzen@archlinux.org>
# Contributor: Masato TOYOSHIMA <phoepsilonix@phoepsilonix.love>
pkgname=pulldown-cmark
pkgver=0.12.2
pkgrel=1
pkgdesc='Pull parser for CommonMark, written in Rust'
arch=(x86_64)
url="https://github.com/raphlinus/$pkgname"
license=(MIT)
depends=(gcc-libs
glibc)
makedepends=(cargo)
_archive="$pkgname-$pkgver"
source=("$_archive.tar.gz::https://static.crates.io/crates/$pkgname/$_archive.crate"
"$_archive-LICENSE::$url/raw/v$pkgver/LICENSE")
sha256sums=('f86ba2052aebccc42cbbb3ed234b8b13ce76f75c3551a303cb2bcffcff12bb14'
'c4f10f55904bdb9f27d3fbf94c354926d6cfe8b982276e556238c258941b243b')
prepare() {
cd "$_archive"
cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')"
cp ../$_archive-LICENSE LICENSE
}
_srcenv() {
cd "$_archive"
export RUSTUP_TOOLCHAIN=stable
export CARGO_TARGET_DIR=target
}
build() {
_srcenv
cargo build --frozen --release
}
check() {
_srcenv
cargo test --frozen
}
package() {
cd "$_archive"
install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/$pkgname"
install -Dm0644 -t "$pkgdir/usr/share/licenses/$pkgname/" LICENSE
}
|