The build system for tree-sitters now generates a much better
Makefile we can use to build the parser and grammar into a good C
library.
This also matches the build procedure used by upstream, making our
reports easier for them to debug (we hit this issue in an old bug
report on memory leak with tree-sitter-bash).
Signed-off-by: Arthur Zamarin <
arthurzam@gentoo.org>
---
eclass/tree-sitter-grammar.eclass | 64 +++++++++++++++++++++----------
1 file changed, 43 insertions(+), 21 deletions(-)
diff --git a/eclass/tree-sitter-grammar.eclass b/eclass/tree-sitter-grammar.eclass
index b2563220cfc..13539daf7e6 100644
--- a/eclass/tree-sitter-grammar.eclass
+++ b/eclass/tree-sitter-grammar.eclass
@@ -1,10 +1,11 @@
-# Copyright 1999-2023 Gentoo Authors
+# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
# @ECLASS: tree-sitter-grammar.eclass
# @MAINTAINER:
# Matthew Smith <
matthew@gentoo.org>
# Nick Sarnie <
sarnex@gentoo.org>
+# Arthur Zamarin <
arthurzam@gentoo.org>
# @AUTHOR:
# Matthew Smith <
matthew@gentoo.org>
# @SUPPORTED_EAPIS: 8
@@ -22,7 +23,7 @@ inherit edo multilib toolchain-funcs
SRC_URI="
https://github.com/tree-sitter/${PN}/archive/${TS_PV:-v${PV}}.tar.gz
-> ${P}.tar.gz"
-S="${WORKDIR}"/${PN}-${TS_PV:-${PV}}/src
+S="${WORKDIR}"/${PN}-${TS_PV:-${PV}}
BDEPEND+=" test? ( dev-util