archrelease: copy trunk to community-any
[ArchLinux/community.git] / cargo-update / repos / community-x86_64 / PKGBUILD
blob32b110ab099f373310c528a3235c08dad884e9a3
1 # Maintainer: Orhun Parmaksız <orhun@archlinux.org>
2 # Contributor: Jameson Pugh <imntreal@gmail.com>
3 # Contributor: Mikaela Szekely <qyriad@gmail.com>
5 pkgname=cargo-update
6 pkgver=13.0.2
7 pkgrel=1
8 pkgdesc="A cargo subcommand for checking and applying updates to installed executables"
9 arch=('x86_64')
10 url="https://github.com/nabijaczleweli/cargo-update"
11 license=('MIT')
12 depends=('gcc-libs' 'zlib' 'openssl')
13 makedepends=('cargo')
14 source=("$pkgname-$pkgver.tar.gz::$url/archive/v$pkgver.tar.gz"
15         "Cargo.lock")
16 sha256sums=('13d4f7998474761c6baf519c39c51b9a9974e3f690093bab42666e9342118525'
17             '88c37ef712be85ba112d0b537e8e2d3e80b762a630ff27ed31db8f5e8fa20afe')
18 options=('!lto')
20 prepare() {
21   cd "$pkgname-$pkgver"
22   cp "$srcdir/Cargo.lock" .
23   cargo fetch --locked --target "$CARCH-unknown-linux-gnu"
26 build() {
27   cd "$pkgname-$pkgver"
28   cargo build --release --frozen
31 check() {
32   cd "$pkgname-$pkgver"
33   cargo test --frozen
36 package() {
37   cd "$pkgname-$pkgver"
38   install -Dm755 "target/release/cargo-install-update" "$pkgdir/usr/bin/cargo-install-update"
39   install -Dm755 "target/release/cargo-install-update-config" "$pkgdir/usr/bin/cargo-install-update-config"
41   install -Dm644 "man/cargo-install-update.md" "$pkgdir/usr/share/doc/${pkgname}/cargo-install-update.md"
42   install -Dm644 "man/cargo-install-update-config.md" "$pkgdir/usr/share/doc/${pkgname}/cargo-install-update-config.md"
43   install -Dm644 "README.md" "$pkgdir/usr/share/doc/${pkgname}/README.md"
44   install -Dm644 "LICENSE" "$pkgdir/usr/share/licenses/${pkgname}/LICENSE"
47 # vim:set ts=2 sw=2 et: