39 lines
1.1 KiB
Bash
39 lines
1.1 KiB
Bash
# Template file for 'tree-sitter'
|
|
pkgname=tree-sitter
|
|
version=0.22.6
|
|
revision=1
|
|
build_style=cargo
|
|
make_install_args="--path=cli"
|
|
short_desc="Parser generator tool and incremental parsing library"
|
|
maintainer="Érico Nogueira <ericonr@disroot.org>"
|
|
license="MIT"
|
|
homepage="https://tree-sitter.github.io"
|
|
changelog="https://raw.githubusercontent.com/tree-sitter/tree-sitter/master/CHANGELOG.md"
|
|
distfiles="https://github.com/tree-sitter/tree-sitter/archive/refs/tags/v${version}.tar.gz"
|
|
checksum=e2b687f74358ab6404730b7fb1a1ced7ddb3780202d37595ecd7b20a8f41861f
|
|
make_check=no # tests require generating fixtures from remote repositories
|
|
|
|
post_build() {
|
|
# Build libtree-sitter, since do_build builds the tree-sitter CLI.
|
|
make
|
|
}
|
|
|
|
post_install() {
|
|
# Install libtree-sitter, since do_install installs the tree-sitter CLI.
|
|
make STRIP=true PREFIX=/usr DESTDIR=${DESTDIR} install
|
|
|
|
vlicense LICENSE
|
|
}
|
|
|
|
tree-sitter-devel_package() {
|
|
short_desc+=" - development files"
|
|
depends="${sourcepkg}>=${version}_${revision}"
|
|
pkg_install() {
|
|
vmove usr/bin
|
|
vmove usr/include
|
|
vmove "usr/lib/*.a"
|
|
vmove "usr/lib/*.so"
|
|
vmove usr/lib/pkgconfig
|
|
}
|
|
}
|