starpls-bin: fix linking on Linux

This commit is contained in:
Jan Olencki 2024-09-29 17:40:56 +02:00
parent a95f58cca4
commit 734b7fff35

View File

@ -1,4 +1,4 @@
{ lib, stdenv, fetchurl }:
{ lib, stdenv, fetchurl, autoPatchelfHook }:
stdenv.mkDerivation (finalAttrs: {
pname = "starpls-bin";
@ -19,6 +19,14 @@ stdenv.mkDerivation (finalAttrs: {
dontConfigure = true;
dontBuild = true;
nativeBuildInputs = lib.optionals stdenv.hostPlatform.isElf [
autoPatchelfHook
];
buildInputs = lib.optionals stdenv.hostPlatform.isElf [
stdenv.cc.cc.lib
];
installPhase = ''
install -D $src $out/bin/starpls
'';