luaPackages: remove unneeded build inputs hack (#494598)

This commit is contained in:
Matthieu Coudron
2026-02-27 18:55:32 +00:00
committed by GitHub
2 changed files with 10 additions and 36 deletions
@@ -27,6 +27,9 @@
# These are added to nativeBuildInputs when doCheck = true.
nativeCheckInputs ? [ ],
# Rockspec `build_dependencies` generated by `luarocks nix`).
nativeBuildInputs ? [ ],
# propagate build dependencies so in case we have A -> B -> C,
# C can import package A propagated by B
propagatedBuildInputs ? [ ],
@@ -101,6 +104,7 @@ let
wrapLua
luarocks_bootstrap
]
++ nativeBuildInputs
++ lib.optionals self.doCheck self.nativeCheckInputs;
inherit
+6 -36
View File
@@ -452,7 +452,7 @@ in
# ld: symbol(s) not found for architecture arm64
# clang-16: error: linker command failed with exit code 1 (use -v to see invocation)
meta.broken = stdenv.hostPlatform.isDarwin;
meta.broken = stdenv.hostPlatform.isDarwin || luaAtLeast "5.5";
});
lua-subprocess = prev.lua-subprocess.overrideAttrs {
@@ -1071,6 +1071,10 @@ in
cargo
rustPlatform.cargoSetupHook
];
meta = old.meta // {
broken = luaAtLeast "5.5";
};
});
tl = prev.tl.overrideAttrs (old: {
@@ -1100,51 +1104,17 @@ in
});
tree-sitter-http = prev.tree-sitter-http.overrideAttrs (old: {
strictDeps = false;
propagatedBuildInputs =
let
# HACK: luarocks-nix puts rockspec build dependencies in the nativeBuildInputs,
# but that doesn't seem to work
lua = lib.head old.propagatedBuildInputs;
in
old.propagatedBuildInputs
++ [
lua.pkgs.luarocks-build-treesitter-parser
tree-sitter
];
nativeBuildInputs = old.nativeBuildInputs or [ ] ++ [
tree-sitter
writableTmpDirAsHomeHook
];
});
tree-sitter-norg = prev.tree-sitter-norg.overrideAttrs (old: {
propagatedBuildInputs =
let
# HACK: luarocks-nix puts rockspec build dependencies in the nativeBuildInputs,
# but that doesn't seem to work
lua = lib.head old.propagatedBuildInputs;
in
old.propagatedBuildInputs
++ [
lua.pkgs.luarocks-build-treesitter-parser-cpp
];
meta.broken = lua.luaversion != "5.1";
});
tree-sitter-orgmode = prev.tree-sitter-orgmode.overrideAttrs (old: {
strictDeps = false;
propagatedBuildInputs =
let
# HACK: luarocks-nix puts rockspec build dependencies in the nativeBuildInputs,
# but that doesn't seem to work
lua = lib.head old.propagatedBuildInputs;
in
old.propagatedBuildInputs
++ [
lua.pkgs.luarocks-build-treesitter-parser
];
nativeBuildInputs = old.nativeBuildInputs or [ ] ++ [
writableTmpDirAsHomeHook
tree-sitter