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

luarocks-nix: bump #166162

Merged
merged 7 commits into from
Mar 31, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 9 additions & 13 deletions pkgs/applications/editors/neovim/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -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";
Expand Down Expand Up @@ -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
Expand Down Expand Up @@ -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"
teto marked this conversation as resolved.
Show resolved Hide resolved
++ optional (!lua.pkgs.isLuaJIT) "-DPREFER_LUA=ON"
;

Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/lua-modules/overrides.nix
Original file line number Diff line number Diff line change
Expand Up @@ -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 {

Expand Down