blob: 11d62e49e04eba0dd40f21eee4bf5657f45d4107 (
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
|
# Maintainer: Ruben Kharel <aur-at-rubenk-dot-dev>
pkgname=talecast-git
_pkgname=TaleCast
pkgver=r102.885ea21
pkgrel=2
pkgdesc="Simple CLI podcatcher"
arch=(
"x86_64"
"i686"
"armv7h"
"aarch64"
)
url="https://github.com/TBS1996/TaleCast"
license=("MIT")
makedepends=("cargo" "git")
depends=()
provides=("talecast")
conflict=("talecast")
sha256sums=("SKIP")
source=("git+${url}.git")
pkgver() {
cd "${_pkgname}"
# https://wiki.archlinux.org/title/VCS_package_guidelines#The_pkgver()_function
# check which method to use from above docs
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
prepare() {
# Set CARGO_HOME to "${srcdir}/cargo"
export CARGO_HOME="${srcdir}/cargo"
if [ ! -d "${_pkgname}/dist" ]; then
mkdir "${_pkgname}/dist"
fi
# Download Rust dependencies
cd "${_pkgname}"
cargo fetch --locked
}
build() {
cd "${_pkgname}"
export RUSTUP_TOOLCHAIN=stable
export CARGO_TARGET_DIR=target
cargo build --release --all-features
# --frozen removed forzen for now
}
package() {
# Set CARGO_HOME to "${srcdir}/cargo"
export CARGO_HOME="${srcdir}/cargo"
# Install binary
install -Dm755 "${srcdir}/${_pkgname}/target/release/talecast" \
"${pkgdir}/usr/bin/talecast"
}
pkgpostrm() {
echo "To run talecast, execute 'talecast' in your terminal."
}
|