nixpkgs/pkgs/development/libraries/science/math/ecos/default.nix

39 lines
817 B
Nix
Raw Normal View History

2018-08-18 04:06:00 +01:00
{ stdenv, fetchFromGitHub }:
stdenv.mkDerivation rec {
pname = "ecos";
2020-02-03 22:24:54 +00:00
version = "2.0.7";
2018-08-18 04:06:00 +01:00
src = fetchFromGitHub {
owner = "embotech";
repo = "ecos";
2020-02-03 22:24:54 +00:00
rev = version;
sha256 = "1hsndim5kjvcwk5svqa4igawzahj982180xj1d7yd0dbjlgxc7w7";
2018-08-18 04:06:00 +01:00
};
buildPhase = ''
make all shared
'';
2018-08-18 17:11:06 +01:00
doCheck = true;
2018-08-18 04:06:00 +01:00
checkPhase = ''
make test
./runecos
'';
installPhase = ''
mkdir -p $out/lib
cp lib*.a lib*.so $out/lib
cp -r include $out/
'';
meta = with stdenv.lib; {
description = "A lightweight conic solver for second-order cone programming";
2020-02-03 22:24:54 +00:00
homepage = "https://www.embotech.com/ECOS";
downloadPage = "https://github.com/embotech/ecos/releases";
2018-08-18 04:06:00 +01:00
license = licenses.gpl3;
2018-08-18 17:11:06 +01:00
platforms = platforms.all;
2020-02-03 22:24:54 +00:00
maintainers = with maintainers; [ bhipple ];
2018-08-18 04:06:00 +01:00
};
}