Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What are the necessary files? #3122

Open
pandasoli opened this issue Mar 16, 2025 · 1 comment
Open

What are the necessary files? #3122

pandasoli opened this issue Mar 16, 2025 · 1 comment

Comments

@pandasoli
Copy link

pandasoli commented Mar 16, 2025

After fixing some errors and managing to correctly compile lua-language-server I executed bin/lua-language-server and it works, but when coping this single executable to ~/.local/bin it stops working and give this error:

./lua-language-server: cannot open (bootstrap.lua): No such file or directory

I tried coping the whole bin folder to ~/.local/bin and when running lua-language-server it shows:

./lua-language-server: (bootstrap.lua):85: cannot open ~/.local/bin/main.lua: No such file or directory
stack traceback:
	[C]: in function 'assert'
	(bootstrap.lua):85: in main chunk
	[C]: in ?

If I move main.lua one directory back into ~/.local/bin it comes back to the first error.

What is the right way of install it? Running directly from the source folder doesn't seem like a good approach

@hinell
Copy link

hinell commented Mar 26, 2025

The right sequence of commands to build lls under Linux systems is following (run from project's root):

./3rd/luamake/luamake build bootstrap lua-language-server
./3rd/luamake/luamake build copy_bootstrap copy_lua-language-server
$ ls ./bin/
lua-language-server  main.lua

The code above basically builds and copies lls to bin/ folder and then copies make/bootstrap.lua to bin/main.lua. The latter actually pulls up files located in ./script/, so if you want to install it locally to $HOME/.local/bin/, you have to copy scripts folder as well.

There is probably ENVIRONMENT var that allows you to specify path to runtime script/ folder instead, but I didn't dig it up.

I've configured my Lazy.nvim to build lls by those two commands above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants