depot/third_party/nixpkgs/pkgs/applications/science/math/eigenmath/default.nix
Default email 587713944a Project import generated by Copybara.
GitOrigin-RevId: 6143fc5eeb9c4f00163267708e26191d1e918932
2024-04-21 17:54:59 +02:00

49 lines
1 KiB
Nix

{ lib
, stdenv
, fetchFromGitHub
, buildPackages
, unstableGitUpdater
}:
stdenv.mkDerivation rec {
pname = "eigenmath";
version = "unstable-2024-04-08";
src = fetchFromGitHub {
owner = "georgeweigt";
repo = pname;
rev = "c0be6c47309aa40d44784a3a4c4c07bc4e8fb6fa";
hash = "sha256-UVCazX0P03+e1exnpXrGNc/1vHxLH04Xtvgsy00UAoI=";
};
checkPhase = let emulator = stdenv.hostPlatform.emulator buildPackages; in ''
runHook preCheck
for testcase in selftest1 selftest2; do
${emulator} ./eigenmath "test/$testcase"
done
runHook postCheck
'';
installPhase = ''
runHook preInstall
install -Dm555 eigenmath "$out/bin/eigenmath"
runHook postInstall
'';
doCheck = true;
passthru = {
updateScript = unstableGitUpdater { };
};
meta = with lib;{
description = "Computer algebra system written in C";
mainProgram = "eigenmath";
homepage = "https://georgeweigt.github.io";
license = licenses.bsd2;
maintainers = with maintainers; [ nickcao ];
platforms = platforms.unix;
};
}