3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/virtualization/xhyve/default.nix

38 lines
999 B
Nix
Raw Normal View History

2019-10-23 19:10:18 +01:00
{ stdenv, lib, fetchFromGitHub, Hypervisor, vmnet, xpc, libobjc, zlib }:
stdenv.mkDerivation rec {
pname = "xhyve";
2019-10-23 19:10:18 +01:00
version = "20191001";
2019-10-23 19:10:18 +01:00
src = fetchFromGitHub {
owner = "machyve";
repo = "xhyve";
rev = "1f46a3d0bbeb6c90883f302425844fcc3800a776";
sha256 = "0mm9xa0v6n7xl2qypnppq5abdncd31vffiklrhcrlni5ymyh9ia5";
};
2019-02-15 22:10:19 +00:00
buildInputs = [ Hypervisor vmnet xpc libobjc zlib ];
2015-09-17 12:27:12 +01:00
# Don't use git to determine version
prePatch = ''
substituteInPlace Makefile \
--replace 'shell git describe --abbrev=6 --dirty --always --tags' "$version"
2015-09-17 12:27:12 +01:00
'';
makeFlags = [ "CFLAGS+=-Wno-shift-sign-overflow" ''CFLAGS+=-DVERSION=\"${version}\"'' ];
installPhase = ''
mkdir -p $out/bin
cp build/xhyve $out/bin
'';
2020-06-11 16:43:47 +01:00
meta = with lib; {
description = "Lightweight Virtualization on macOS Based on bhyve";
homepage = "https://github.com/mist64/xhyve";
2020-06-11 16:43:47 +01:00
maintainers = [ maintainers.lnl7 ];
license = licenses.bsd2;
platforms = platforms.darwin;
};
}