Closed anjos closed 1 month ago
This is maybe related to #17.
@danielnachun: I see you're the maintainer of conda-forge/libtree-sitter-feedstock. I think the way forward to avoid this from happening in the future would be to add proper run_exports
to that package as documented here. My current understanding is that library should have something lke (tune max_pin
to define what compatibility with libtree-sitter
upstream packages can expect):
build:
run_exports:
- {{ pin_subpackage('libtree-sitter', max_pin='x.x') }}
Then, in this package, one should only add a build dependency to libtree-sitter
on the host
section (and not anywhere else). This should make builds of this feedstock auto-depend on a pinned version of that dependency with some freedom (patch upgrades remain possible w/o changes to this build). Otherwise, a rebuild is required.
I further checked most of other dependencies.
These provide run_exports
(and we can use these in the host
section-only to leverage the auto-pins provided by maintainers):
libuv
: https://github.com/conda-forge/libuv-feedstock/blob/main/recipe/meta.yamllibiconv
: https://github.com/conda-forge/libiconv-feedstock/blob/main/recipe/meta.yamlmsgpack-c
: https://github.com/conda-forge/msgpack-c-feedstock/blob/main/recipe/meta.yamlgettext
: https://github.com/conda-forge/gettext-feedstock/blob/main/recipe/meta.yamlThese do not (and would need fixing to avoid issues in the future):
libtermkey
: https://github.com/conda-forge/libtermkey-feedstock/blob/main/recipe/meta.yamllibtree-sitter
: https://github.com/conda-forge/libtree-sitter-feedstock/blob/main/recipe/meta.yamllibvterm
: https://github.com/conda-forge/libvterm-feedstock/blob/main/recipe/meta.yamlunibilium
: https://github.com/conda-forge/unibilium-feedstock/blob/main/recipe/meta.yamlluv
: https://github.com/conda-forge/luv-feedstock/blob/main/recipe/meta.yamlI do not think the lua modules need any fixing. Only the libraries above. I'll try to provide PRs with run_exports to those first.
Thanks @anjos, you are right about missing run_exports
. I will work on adding these now!
Awesome 🙌 This will improve package usability!
@anjos I believe this is now fixed after I rebuilt the package. Can you check and close the issue as completed if so?
@danielnachun: thanks a lot for this effort! The update worked flawlessly on my setup. Also, looking for package I get the correctly pinned dependency set, whereas before it was not the case:
$ pixi search nvim
Using channels: conda-forge
nvim h5867d45_1
---------------
Name nvim
Version 0.10.2
Build h5867d45_1
Size 7211365
License Apache-2.0
Subdir osx-arm64
File Name nvim-0.10.2-h5867d45_1.conda
URL https://conda.anaconda.org/conda-forge/osx-arm64/nvim-0.10.2-h5867d45_1.conda
MD5 cef0e345d4ed66b71e7ee35bb558516d
SHA256 4205816ceed10a08787bd8eb2dab496c55e9d8918fb4911e3eeb22a946479cb0
Dependencies:
- __osx >=11.0
- libasprintf >=0.22.5,<1.0a0
- libgettextpo >=0.22.5,<1.0a0
- libiconv >=1.17,<2.0a0
- libintl >=0.22.5,<1.0a0
- libtermkey >=0.22,<0.23.0a0
- libtree-sitter >=0.24.1,<0.25.0a0
- libuv >=1.49.0,<2.0a0
- libvterm >=0.3.3,<0.4.0a0
- lua-lpeg
- luajit-openresty
- luv >=1.48.0,<1.49.0a0
- msgpack-c >=6.0.0,<7.0a0
- unibilium >=2.1.2,<2.2.0a0
Thanks again for the huge amount of work! 🚀
Thanks @anjos! I do hope to get lua-lpeg
to have a proper run export once the upstream URL issue is figured out, and I'm also going to look into making luajit-openresty
into a split package that has separate libluajit-openresty
and luajit-openresty
outputs so that we can eventually have a run export for that as well. Fortunately both of those packages hardly ever seem to make ABI breaking changes so I'm less concerned in the short term about them breaking nvim
.
Solution to issue cannot be found in the documentation.
Issue
Update of libtree-sitter from 0.23.2 to 0.24.1 broke the current package.
After installation, the editor cannot start anymore as it complains it cannot dynamically link against
libtree-sitter.0.23
.If a precise version of a library must be used at run-time, it needs to be somehow properly pinned during the build.
Temporary fix: add a dependency to
libtree-sitter = 0.23.*
to your environment. This will allow the editor to start correctly for now.Installed packages
Environment info