diff options
author | Fernando Rodrigues | 2024-08-04 18:09:30 +0000 |
---|---|---|
committer | Alyssa Ross | 2024-08-18 11:30:55 +0200 |
commit | 2d51a4d3062f63a0c6f164e9772e98c4f1b99d20 (patch) | |
tree | 6edf0140f0604c4d1126becf106dee69e4820945 /pkgs/by-name/xe | |
parent | 4c66fe4cb40272c7e5506b3517ffac63250d0bb8 (diff) |
xen-guest-agent: move to by-name
Signed-off-by: Fernando Rodrigues <alpha@sigmasquadron.net>
Diffstat (limited to 'pkgs/by-name/xe')
-rw-r--r-- | pkgs/by-name/xe/xen-guest-agent/package.nix | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/pkgs/by-name/xe/xen-guest-agent/package.nix b/pkgs/by-name/xe/xen-guest-agent/package.nix new file mode 100644 index 000000000000..1b9f637bf61a --- /dev/null +++ b/pkgs/by-name/xe/xen-guest-agent/package.nix @@ -0,0 +1,40 @@ +{ + lib, + fetchFromGitLab, + rustPlatform, + llvmPackages, + xen-slim, +}: +rustPlatform.buildRustPackage rec { + pname = "xen-guest-agent"; + version = "0.3.0"; + + src = fetchFromGitLab { + owner = "xen-project"; + repo = pname; + rev = version; + hash = "sha256-Csio24ofj+p0j/R0av/28P/KCNXhmcF+r8xGJEfoHjQ="; + }; + + cargoHash = "sha256-XWDDzSu88zCIwMuvkFjCb98DzXHvW2IP9u3EbpAMIgw="; + + env = { + LIBCLANG_PATH = "${llvmPackages.libclang.lib}/lib"; + BINDGEN_EXTRA_CLANG_ARGS = "-isystem ${xen-slim.dev}/include"; + RUSTFLAGS = "-L ${xen-slim.out}/lib"; + }; + + nativeBuildInputs = [llvmPackages.clang xen-slim.out]; + + postFixup = '' + patchelf $out/bin/xen-guest-agent --add-rpath ${xen-slim.out}/lib + ''; + + meta = with lib; { + description = "Xen agent running in Linux/BSDs (POSIX) VMs"; + homepage = "https://gitlab.com/xen-project/xen-guest-agent"; + license = licenses.agpl3Only; + platforms = platforms.unix; + maintainers = with maintainers; [matdibu]; + }; +} |