ldm: fix build

There were two problems:
- because buildPhase is specified directly, preBuild ends up never being
  executed; and
- the source is missing a header, resulting in an undefined reference error
This commit is contained in:
Joachim Fasting 2016-03-20 16:46:50 +01:00
parent 3273605aef
commit f59998055b

View File

@ -19,9 +19,10 @@ stdenv.mkDerivation rec {
buildInputs = [ udev utillinux ];
preBuild = ''
postPatch = ''
substituteInPlace ldm.c \
--replace "/mnt/" "${mountPath}"
sed '16i#include <sys/stat.h>' -i ldm.c
'';
buildPhase = "make ldm";