Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{
2 blas,
3 lapack,
4 lib,
5 fetchFromGitHub,
6 stdenv,
7}:
8
9stdenv.mkDerivation (finalAttrs: {
10 pname = "superscs";
11 version = "1.3.3";
12
13 src = fetchFromGitHub {
14 owner = "kul-optec";
15 repo = "superscs";
16 #rev = "v${finalAttrs.version}";
17 # ref. https://github.com/kul-optec/superscs/pull/38
18 rev = "500070e807f92347a7c6cbdc96739521a256b71e";
19 hash = "sha256-Qu7RM6Ew4hEmoIXO0utDDVmjmNX3yt3FxWZXCQ/Xjp4=";
20 };
21
22 postPatch = lib.optionalString stdenv.hostPlatform.isDarwin ''
23 substituteInPlace Makefile --replace-fail \
24 ".so" \
25 ".dylib"
26 '';
27
28 buildInputs = [
29 blas
30 lapack
31 ];
32
33 makeFlags = [ "PREFIX=$(out)" ];
34
35 doCheck = true;
36
37 meta = {
38 description = "Fast conic optimization in C";
39 homepage = "https://github.com/kul-optec/superscs";
40 changelog = "https://github.com/kul-optec/superscs/blob/${finalAttrs.src.rev}/CHANGELOG.md";
41 license = lib.licenses.mit;
42 maintainers = with lib.maintainers; [ nim65s ];
43 };
44})