leanify: support darwin
This commit is contained in:
parent
3f977c13dd
commit
49fc798b25
|
@ -1,6 +1,7 @@
|
||||||
{ lib
|
{ lib
|
||||||
, stdenv
|
, stdenv
|
||||||
, fetchFromGitHub
|
, fetchFromGitHub
|
||||||
|
, libiconv
|
||||||
}:
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
|
@ -14,6 +15,14 @@ stdenv.mkDerivation rec {
|
||||||
hash = "sha256-KxVV7AW9sEfH4YTPDfeJk7fMMGh0eSkECXM/Mv9XqBA=";
|
hash = "sha256-KxVV7AW9sEfH4YTPDfeJk7fMMGh0eSkECXM/Mv9XqBA=";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
postPatch = lib.optionalString stdenv.isDarwin ''
|
||||||
|
substituteInPlace Makefile \
|
||||||
|
--replace "-flto" "" \
|
||||||
|
--replace "lib/LZMA/Alloc.o" "lib/LZMA/CpuArch.o lib/LZMA/Alloc.o"
|
||||||
|
'';
|
||||||
|
|
||||||
|
buildInputs = lib.optionals stdenv.isDarwin [ libiconv ];
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
runHook preInstall
|
runHook preInstall
|
||||||
|
|
||||||
|
@ -35,6 +44,5 @@ stdenv.mkDerivation rec {
|
||||||
license = licenses.mit;
|
license = licenses.mit;
|
||||||
maintainers = [ maintainers.mynacol ];
|
maintainers = [ maintainers.mynacol ];
|
||||||
platforms = platforms.all;
|
platforms = platforms.all;
|
||||||
broken = stdenv.isDarwin;
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue