Thursday, August 03, 2023

Re: emacs and textroc/tree-sitter: drop tree-sittter cli program?

On 2023/08/03 18:47, Mikhail wrote:
> On Wed, Aug 02, 2023 at 08:49:10PM +0200, Jeremie Courreges-Anglas wrote:
> >
> > So emacs-29.1 introduced a tree-sitter backend to parse source code,
> > instead of the traditional bag of ugly regexes. I'd like to add
> > tree-sitter as a dep to the emacs port but the non-optional rust
> > dependency is in the way. rust isn't supported on all architectures but
> > emacs--no_x11 should be available everywhere. I initially went with
> > a PFRAG.rust, but thinking about it some more, I don't want people to
> > yell at me when they spot rust on the build dep list of emacs--no_x11. ;)
> >
> > Upstream says that "tree-sitter aims to be dependency-free so that the
> > runtime library (which is written in pure C) can be embedded in any
> > application.
> >
> > I propose to zap the rust build-dependency. Paco, you did the inital
> > import. Do you still care about shipping this tree-sitter program?
> > Edd, the only consumer of tree-sitter so far is neovim, which seems to
> > build/package without the tree-sitter cli program being available.
> > runtime/doc/treesitter.txt doesn't mention a requirement on the cli
> > tool. Maybe you'll want to check again?
> >
> > If people actually use and need the tree-sitter program, we can create
> > an additional tree-sitter-cli port (and maybe move the library to a
> > textproc/tree-sitter/tree-sitter subdirectory, etc).
> >
> > ok?
>
> > -
> > -.include "crates.inc"
> > -
>
> crates.inc is removed from Makefile, but not rm'ed from the port dir -
> is it intentional?
>
> > -SEPARATE_BUILD = Yes
>
> Mostly for educational purposes -
> https://www.openbsd.org/faq/ports/guide.html
> point 13 says "Try setting SEPARATE_BUILD" - is there a reason to remove
> it?
>

It doesn't build if that is set.

Also it's not unknown for SEPARATE_BUILD to quietly break things
(especially tests), I think this is obsolete advice in most cases

The main benefit IMO is for huge ports when you might want to re-run
"make configure" during development and it takes too long to "make
extract"...

No comments:

Post a Comment