lima, lima-additional-guestagents: share source (#437460)

This commit is contained in:
Sandro
2025-09-24 07:35:39 +00:00
committed by GitHub
4 changed files with 33 additions and 26 deletions

View File

@@ -2,24 +2,17 @@
lib,
stdenv,
buildGoModule,
fetchFromGitHub,
nix-update-script,
callPackage,
apple-sdk_15,
findutils,
}:
buildGoModule (finalAttrs: {
pname = "lima-additional-guestagents";
version = "1.2.1";
src = fetchFromGitHub {
owner = "lima-vm";
repo = "lima";
tag = "v${finalAttrs.version}";
hash = "sha256-90fFsS5jidaovE2iqXfe4T2SgZJz6ScOwPPYxCsCk/k=";
};
vendorHash = "sha256-8S5tAL7GY7dxNdyC+WOrOZ+GfTKTSX84sG8WcSec2Os=";
# Because agents must use the same version as lima, lima's updateScript should also update the shared src.
# nixpkgs-update: no auto update
inherit (callPackage ./source.nix { }) version src vendorHash;
buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [
apple-sdk_15
@@ -63,10 +56,6 @@ buildGoModule (finalAttrs: {
runHook postInstallCheck
'';
passthru = {
updateScript = nix-update-script { };
};
meta = {
homepage = "https://github.com/lima-vm/lima";
description = "Lima Guest Agents for emulating non-native architectures";

View File

@@ -2,7 +2,7 @@
lib,
stdenv,
buildGoModule,
fetchFromGitHub,
callPackage,
installShellFiles,
qemu,
darwin,
@@ -22,16 +22,8 @@
buildGoModule (finalAttrs: {
pname = "lima";
version = "1.2.1";
src = fetchFromGitHub {
owner = "lima-vm";
repo = "lima";
tag = "v${finalAttrs.version}";
hash = "sha256-90fFsS5jidaovE2iqXfe4T2SgZJz6ScOwPPYxCsCk/k=";
};
vendorHash = "sha256-8S5tAL7GY7dxNdyC+WOrOZ+GfTKTSX84sG8WcSec2Os=";
inherit (callPackage ./source.nix { }) version src vendorHash;
nativeBuildInputs = [
makeWrapper
@@ -159,7 +151,12 @@ buildGoModule (finalAttrs: {
};
};
updateScript = nix-update-script { };
updateScript = nix-update-script {
extraArgs = [
"--override-filename"
./source.nix
];
};
};
meta = {

View File

@@ -0,0 +1,19 @@
{
fetchFromGitHub,
}:
let
version = "1.2.1";
in
{
inherit version;
src = fetchFromGitHub {
owner = "lima-vm";
repo = "lima";
tag = "v${version}";
hash = "sha256-90fFsS5jidaovE2iqXfe4T2SgZJz6ScOwPPYxCsCk/k=";
};
vendorHash = "sha256-8S5tAL7GY7dxNdyC+WOrOZ+GfTKTSX84sG8WcSec2Os=";
}

View File

@@ -5361,6 +5361,8 @@ with pkgs;
withQt = true;
};
lima-additional-guestagents = callPackage ../by-name/li/lima/additional-guestagents.nix { };
lld = llvmPackages.lld;
lldb = llvmPackages.lldb;