st: enable build on darwin (#98668)

This commit is contained in:
Ben Siraphob 2020-09-25 04:57:19 +07:00 committed by GitHub
parent 4b64ea7e4f
commit 34133d5425
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -15,6 +15,9 @@ stdenv.mkDerivation rec {
inherit patches;
configFile = optionalString (conf!=null) (writeText "config.def.h" conf);
patchPhase = optionalString stdenv.isDarwin ''
substituteInPlace config.mk --replace "-lrt" ""
'';
postPatch = optionalString (conf!=null) "cp ${configFile} config.def.h";
nativeBuildInputs = [ pkgconfig ncurses ];