Files
nixpkgs/pkgs/by-name/vp/vpcs/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

56 lines
1.3 KiB
Nix

{
lib,
stdenv,
fetchFromGitHub,
testers,
vpcs,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "vpcs";
version = "0.8.3";
src = fetchFromGitHub {
owner = "GNS3";
repo = "vpcs";
tag = "v${finalAttrs.version}";
hash = "sha256-OKi4sC4fmKtkJkkpHZ6OfeIDaBafVrJXGXh1R6gLPFY=";
};
sourceRoot = "${finalAttrs.src.name}/src";
buildPhase = ''
runHook preBuild
MKOPT="CC=${stdenv.cc.targetPrefix}cc" ./mk.sh ${stdenv.buildPlatform.linuxArch}
runHook postBuild
'';
postInstall = ''
install -D -m555 vpcs $out/bin/vpcs
install -D -m444 ../man/vpcs.1 $out/share/man/man1/vpcs.1
'';
enableParallelBuilding = true;
passthru.tests.version = testers.testVersion {
package = vpcs;
command = "vpcs -v";
};
meta = with lib; {
description = "Simple virtual PC simulator";
longDescription = ''
The VPCS (Virtual PC Simulator) can simulate up to 9 PCs. You can
ping/traceroute them, or ping/traceroute the other hosts/routers from the
VPCS when you study the Cisco routers in the dynamips.
'';
inherit (finalAttrs.src.meta) homepage;
license = licenses.bsd2;
platforms = platforms.linux ++ platforms.darwin;
mainProgram = "vpcs";
maintainers = with maintainers; [ anthonyroussel ];
};
})