summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 0db67a27c680acb260802cdee985a3356893529e (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
# Maintainer: TheFeelTrain <the@feeltra.in>

_plug=fftspectrum-rs
pkgname=vapoursynth-plugin-${_plug}-git
pkgver=1.0.13.2.gdae5257
pkgrel=1
pkgdesc="Plugin for Vapoursynth: ${_plug} (GIT version)"
arch=('x86_64')
url="https://github.com/sgt0/vapoursynth-fftspectrum-rs"
license=('MIT')
depends=(
    'vapoursynth>=75'
)
makedepends=(
    'cargo'
)
provides=("vapoursynth-plugin-${_plug}")
conflicts=("vapoursynth-plugin-${_plug}")
source=("${_plug}::git+https://github.com/sgt0/vapoursynth-fftspectrum-rs.git")
sha256sums=('SKIP')
options=('debug')

pkgver() {
    cd "${_plug}"
    git describe --long --tags | tr - . | tr -d v
}

build() {
    cd "${_plug}"
    cargo build --release
}

package(){
    PLUGINDIR=$(python3 -c "import vapoursynth; print(vapoursynth.get_plugin_dir())")
    install -Dm755 "${_plug}/target/release/libfftspectrum_rs.so" "${pkgdir}${PLUGINDIR}/libfftspectrum_rs.so"
    install -Dm644 "${_plug}/LICENSE.md" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.md"
}