commit d1864112bd69432ba3c6d649ca4d304d09021388 Author: Tim Biermann <tbier@posteo.de> Date: Sun Nov 27 17:59:17 2022 +0000 tree-sitter-lua: initial commit, version 0.0.14 diff --git a/tree-sitter-lua/.footprint b/tree-sitter-lua/.footprint new file mode 100644 index 000000000..703e7b5de --- /dev/null +++ b/tree-sitter-lua/.footprint @@ -0,0 +1,8 @@ +drwxr-xr-x root/root usr/ +drwxr-xr-x root/root usr/lib/ +-rw-r--r-- root/root usr/lib/libtree-sitter-lua.so +drwxr-xr-x root/root usr/share/ +drwxr-xr-x root/root usr/share/nvim/ +drwxr-xr-x root/root usr/share/nvim/runtime/ +drwxr-xr-x root/root usr/share/nvim/runtime/parser/ +lrwxrwxrwx root/root usr/share/nvim/runtime/parser/lua.so -> /usr/lib/libtree-sitter-lua.so diff --git a/tree-sitter-lua/.signature b/tree-sitter-lua/.signature new file mode 100644 index 000000000..43ec60fde --- /dev/null +++ b/tree-sitter-lua/.signature @@ -0,0 +1,5 @@ +untrusted comment: verify with /etc/ports/contrib.pub +RWSagIOpLGJF3/2HddfbtV0aZ7e7aAYS8xhy/H3n82njbcQWSd8aZOh8P8garHUKXJ6kHpJi8uqghuTtcS16maJdr8mCwCddrwc= +SHA256 (Pkgfile) = c26c231e37defed422efcff135ab5945f09f027b5ddb96439c4a488f2ed079e5 +SHA256 (.footprint) = 89b6b143355e6434b0cf0971c05913f10b1b9589da2fd524b3ceef7e34571645 +SHA256 (tree-sitter-lua-0.0.14.tar.gz) = 930d0370dc15b66389869355c8e14305b9ba7aafd36edbfdb468c8023395016d diff --git a/tree-sitter-lua/Pkgfile b/tree-sitter-lua/Pkgfile new file mode 100644 index 000000000..f2a67ef25 --- /dev/null +++ b/tree-sitter-lua/Pkgfile @@ -0,0 +1,25 @@ +# Description: Lua grammar for tree-sitter +# URL: https://github.com/MunifTanjim/tree-sitter-lua +# Maintainer: Tim Biermann, tbier at posteo dot de +# Depends on: npm tree-sitter + +name=tree-sitter-lua +version=0.0.14 +release=1 +source=(https://github.com/MunifTanjim/tree-sitter-lua/archive/v$version/$name-$vers...) + +build() { + cd $name-$version + + tree-sitter generate --log + + cd src + export CFLAGS+=' -fPIC' + cc $CFLAGS -std=c99 -c parser.c + cc $CFLAGS -c scanner.c + cc $LDFLAGS -shared parser.o scanner.o -o parser.so + + install -Dm 644 parser.so $PKG/usr/lib/libtree-sitter-lua.so + install -d $PKG/usr/share/nvim/runtime/parser/ + ln -s /usr/lib/libtree-sitter-lua.so $PKG/usr/share/nvim/runtime/parser/lua.so +}