Download raw body.
[update] textproc/tree-sitter 0.24.1
Hi,
update for textproc/tree-sitter to the latest version 0.24.1
Homepage: https://github.com/tree-sitter/tree-sitter
- update Makefile and distinfo for this version
- bump minor for SHARED_LIBS (new functions added in API)
- update patch for Makefile => fix path substitutions for pkgconfig/tree-sitter.pc
Build OK on current/amd64 and tests OK using Neovim with tree-sitter plugin.
Tests welcome and please commit if OK.
Laurent
Index: Makefile
===================================================================
RCS file: /cvs/ports/textproc/tree-sitter/Makefile,v
diff -u -p -r1.16 Makefile
--- Makefile 28 May 2024 19:05:21 -0000 1.16
+++ Makefile 4 Oct 2024 06:18:09 -0000
@@ -5,9 +5,9 @@ COMMENT = parser generator tool and incr
GH_ACCOUNT = tree-sitter
GH_PROJECT = tree-sitter
-GH_TAGNAME = v0.22.6
+GH_TAGNAME = v0.24.1
-SHARED_LIBS += tree-sitter 4.0 # 0.22.6
+SHARED_LIBS += tree-sitter 4.1 # 0.24.1
CATEGORIES = textproc
Index: distinfo
===================================================================
RCS file: /cvs/ports/textproc/tree-sitter/distinfo,v
diff -u -p -r1.8 distinfo
--- distinfo 28 May 2024 19:05:21 -0000 1.8
+++ distinfo 4 Oct 2024 06:18:09 -0000
@@ -1,2 +1,2 @@
-SHA256 (tree-sitter-0.22.6.tar.gz) = 4raH90NYq2QEcwt/saHO192zeAIC03WV7NeyCo9Bhh8=
-SIZE (tree-sitter-0.22.6.tar.gz) = 3036954
+SHA256 (tree-sitter-0.24.1.tar.gz) = ettbs7PCxPT9yYCpoT34+/NSaoK1w33Zzy7SneVqRoM=
+SIZE (tree-sitter-0.24.1.tar.gz) = 3020564
Index: patches/patch-Makefile
===================================================================
RCS file: /cvs/ports/textproc/tree-sitter/patches/patch-Makefile,v
diff -u -p -r1.4 patch-Makefile
--- patches/patch-Makefile 28 May 2024 19:05:21 -0000 1.4
+++ patches/patch-Makefile 4 Oct 2024 06:18:09 -0000
@@ -5,28 +5,38 @@ the pkg-config file
Index: Makefile
--- Makefile.orig
+++ Makefile
-@@ -38,8 +38,8 @@ else ifeq ($(shell uname),Darwin)
+@@ -7,7 +7,7 @@ DESCRIPTION := An incremental parsing system for progr
+ HOMEPAGE_URL := https://tree-sitter.github.io/tree-sitter/
+
+ # install directory layout
+-PREFIX ?= /usr/local
++PREFIX ?= ${LOCALBASE}
+ INCLUDEDIR ?= $(PREFIX)/include
+ LIBDIR ?= $(PREFIX)/lib
+ PCLIBDIR ?= $(LIBDIR)/pkgconfig
+@@ -42,8 +42,8 @@ ifneq ($(findstring darwin,$(shell $(CC) -dumpmachine)
else
SOEXT = so
- SOEXTVER_MAJOR = so.$(SONAME_MAJOR)
-- SOEXTVER = so.$(SONAME_MAJOR).$(SONAME_MINOR)
-- LINKSHARED += -shared -Wl,-soname,libtree-sitter.so.$(SONAME_MAJOR)
+ SOEXTVER_MAJOR = $(SOEXT).$(SONAME_MAJOR)
+- SOEXTVER = $(SOEXT).$(SONAME_MAJOR).$(SONAME_MINOR)
+- LINKSHARED += -shared -Wl,-soname,libtree-sitter.$(SOEXTVER)
+ SOEXTVER = so.${LIBtree-sitter_VERSION}
+ LINKSHARED += -shared
endif
ifneq ($(filter $(shell uname),FreeBSD NetBSD DragonFly),)
PCLIBDIR := $(PREFIX)/libdata/pkgconfig
-@@ -60,8 +60,7 @@ tree-sitter.pc: tree-sitter.pc.in
- sed -e 's|@VERSION@|$(VERSION)|' \
- -e 's|@LIBDIR@|$(LIBDIR)|' \
- -e 's|@INCLUDEDIR@|$(INCLUDEDIR)|' \
-- -e 's|=$(PREFIX)|=$${prefix}|' \
-- -e 's|@PREFIX@|$(PREFIX)|' $< > $@
-+ -e 's|@PREFIX@|$(LOCALBASE)|' $< > $@
+@@ -62,8 +62,8 @@ endif
- clean:
- $(RM) $(OBJ) tree-sitter.pc libtree-sitter.a libtree-sitter.$(SOEXT)
-@@ -72,8 +71,6 @@ install: all
+ tree-sitter.pc: lib/tree-sitter.pc.in
+ sed -e 's|@PROJECT_VERSION@|$(VERSION)|' \
+- -e 's|@CMAKE_INSTALL_LIBDIR@|$(LIBDIR)|' \
+- -e 's|@CMAKE_INSTALL_INCLUDEDIR@|$(INCLUDEDIR)|' \
++ -e 's|@CMAKE_INSTALL_LIBDIR@|lib|' \
++ -e 's|@CMAKE_INSTALL_INCLUDEDIR@|include|' \
+ -e 's|@PROJECT_DESCRIPTION@|$(DESCRIPTION)|' \
+ -e 's|@PROJECT_HOMEPAGE_URL@|$(HOMEPAGE_URL)|' \
+ -e 's|@CMAKE_INSTALL_PREFIX@|$(PREFIX)|' $< > $@
+@@ -77,8 +77,6 @@ install: all
install -m644 tree-sitter.pc '$(DESTDIR)$(PCLIBDIR)'/tree-sitter.pc
install -m644 libtree-sitter.a '$(DESTDIR)$(LIBDIR)'/libtree-sitter.a
install -m755 libtree-sitter.$(SOEXT) '$(DESTDIR)$(LIBDIR)'/libtree-sitter.$(SOEXTVER)
[update] textproc/tree-sitter 0.24.1