mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 23:13:19 +00:00
neovim: cleanup a bit libluv related hacks
Remove unneeded cmakeFlags and explain more what is the difference between lua.pkgs.libluv and lua.pkgs.luv.
This commit is contained in:
parent
d3dcc106c8
commit
f80b906b3a
@ -21,14 +21,6 @@ let
|
||||
));
|
||||
|
||||
pyEnv = python3.withPackages(ps: with ps; [ pynvim msgpack ]);
|
||||
|
||||
# FIXME: this is verry messy and strange.
|
||||
# see https://github.com/NixOS/nixpkgs/pull/80528
|
||||
luv = lua.pkgs.luv;
|
||||
luvpath = with builtins ; if stdenv.isDarwin
|
||||
then "${luv.libluv}/lib/lua/${lua.luaversion}/libluv.${head (match "([0-9.]+).*" luv.version)}.dylib"
|
||||
else "${luv}/lib/lua/${lua.luaversion}/luv.so";
|
||||
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "neovim-unwrapped";
|
||||
@ -57,7 +49,11 @@ in
|
||||
libtermkey
|
||||
libuv
|
||||
libvterm-neovim
|
||||
luv.libluv
|
||||
# This is actually a c library, hence it's not included in neovimLuaEnv,
|
||||
# see:
|
||||
# https://github.com/luarocks/luarocks/issues/1402#issuecomment-1080616570
|
||||
# and it's definition at: pkgs/development/lua-modules/overrides.nix
|
||||
lua.pkgs.libluv
|
||||
msgpack
|
||||
ncurses
|
||||
neovimLuaEnv
|
||||
@ -97,12 +93,12 @@ in
|
||||
disallowedReferences = [ stdenv.cc ];
|
||||
|
||||
cmakeFlags = [
|
||||
"-DGPERF_PRG=${gperf}/bin/gperf"
|
||||
"-DLUA_PRG=${neovimLuaEnv.interpreter}"
|
||||
"-DLIBLUV_LIBRARY=${luvpath}"
|
||||
# Don't use downloaded dependencies. At the end of the configurePhase one
|
||||
# can spot that cmake says this option was "not used by the project".
|
||||
# That's because all dependencies were found and
|
||||
# third-party/CMakeLists.txt is not read at all.
|
||||
"-DUSE_BUNDLED=OFF"
|
||||
]
|
||||
++ optional doCheck "-DBUSTED_PRG=${neovimLuaEnv}/bin/busted"
|
||||
++ optional (!lua.pkgs.isLuaJIT) "-DPREFER_LUA=ON"
|
||||
;
|
||||
|
||||
|
@ -281,7 +281,7 @@ with prev;
|
||||
});
|
||||
|
||||
|
||||
# as advised in https://github.com/luarocks/luarocks/issues/1402
|
||||
# as advised in https://github.com/luarocks/luarocks/issues/1402#issuecomment-1080616570
|
||||
# we shouldn't use luarocks machinery to build complex cmake components
|
||||
libluv = pkgs.stdenv.mkDerivation {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user