xplr.nvim icon indicating copy to clipboard operation
xplr.nvim copied to clipboard

unable to make luv

Open prncss-xyz opened this issue 3 years ago • 3 comments

This seems really promising, unfortunately, automatic install did not work for me, and when I tried manual installation, the problematic step seemed to be cd xplr/src/luv && make, where I get:

cmake -H. -Bbuild -DBUILD_MODULE=ON -DBUILD_SHARED_LIBS=OFF -DBUILD_STATIC_LIBS=OFF -DWITH_SHARED_LIBUV=OFF -DWITH_LUA_ENGINE=LuaJIT -DLUA_BUILD_TYPE=Static -DLUA_COMPAT53_DIR=deps/lua-compat-5.3 -DCMAKE_BUILD_TYPE=RelWithDebInfo
make: cmake: Permission denied
make: *** [Makefile:55: build/Makefile] Error 12

I've tryed to sudo it with the same results.

(Working with an up to date Arch Linux system.)

I don't have experience with cmake. Do you have an idea where I should look? Thank you.

prncss-xyz avatar Dec 16 '21 02:12 prncss-xyz

Hey @prncss-xyz My experience with cmake doesn't go that far, other than compiling programs. However, looks like Makefile is erroring here

so maybe: chmod 777 on luv submodule folder inside xplr repo or $(BUILD_DIR)

There is also the option of installing the dependencies with Luarocks, and then manually adding the Luarocks library paths to the xplr environment:

pacman -s luarocks
luarocks install luv
luarocks path

my luarocks path output:

export LUA_PATH='/usr/local/share/lua/5.1/?.lua;./?.lua;/usr/share/lua/5.1/?.lua;/usr/share/lua/5.1/?/init.lua;/usr/lib/lua/5.1/?.lua;/usr/lib/lua/5.1/?/init.lua;/home/f1/.luarocks/share/lua/5.1/?.lua;/home/f1/.luarocks/share/lua/5.1/?/init.lua;/usr/local/share/lua/5.1/?/init.lua'
export LUA_CPATH='./?.so;/usr/lib/lua/5.1/?.so;/usr/lib/lua/5.1/loadall.so;/home/f1/.luarocks/lib/lua/5.1/?.so;/usr/local/lib/lua/5.1/?.so'

the output from luarocks path can be added to the xplr.nvim init script that loads when xplr starts up inside nvim:

delete line 3-12 from xplr.nvim init script and change to:

package.path = package.path .. "<paste output from luarocks path export LUA_PATH var>"
package.cpath = package.cpath .. "<add output from luarocks path export LUA_CPATH var>"

unfortunately xplr doesnt load these variables from the environment so they have to be added into the startup file like this.

fhill2 avatar Dec 16 '21 11:12 fhill2

Thank you so much. Successfully installed the lua rocks (also needed to add lua51 pacakge for files other than the binary). Still cannot get it to work properly, but at least I have things I can work with. Will give some feedback here if I get somewhere.

prncss-xyz avatar Dec 17 '21 22:12 prncss-xyz

Thank you so much. Successfully installed the lua rocks (also needed to add lua51 pacakge for files other than the binary). Still cannot get it to work properly, but at least I have things I can work with. Will give some feedback here if I get somewhere.

That's great to hear.

To debug, using cat $XPLR_PIPE_LOGS_OUT method I've found is helpful. The process can be found here.

Let me know what isn't working or any error messages from the xplr.nvim lua environment output and I can suggest something to try.

fhill2 avatar Dec 17 '21 22:12 fhill2