udpspeeder: fix crash

This commit is contained in:
Stzx
2025-12-24 18:38:54 +08:00
parent 9ca21a51d4
commit 06a3aaa51c
+4 -8
View File
@@ -2,7 +2,6 @@
lib,
stdenv,
fetchFromGitHub,
cmake,
versionCheckHook,
nix-update-script,
}:
@@ -18,15 +17,12 @@ stdenv.mkDerivation (finalAttrs: {
hash = "sha256-hrwkPSxY1DTEXt9vxDECDEJaoTDzBUS7rVI609uZwdU=";
};
preBuild = ''
echo "const char *gitversion = \"${finalAttrs.version}\";" > git_version.h # From Makefile
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -I$PWD"
postPatch = ''
substituteInPlace makefile \
--replace-fail " -static " " " \
--replace-fail "\$(shell git rev-parse HEAD)" ${finalAttrs.version}
'';
nativeBuildInputs = [
cmake
];
installPhase = ''
runHook preInstall