From b5b4f0a633a23e9bb1d0e31cb08d408cc8dbecee Mon Sep 17 00:00:00 2001 From: Las Safin Date: Sun, 29 Aug 2021 19:58:10 +0000 Subject: [PATCH] unicorn, tutorial, kite, katabatic, bora --- flake.nix | 10 +++++----- nix/bora.nix | 42 +++++++++++++++++----------------------- nix/etesian.nix | 3 +++ nix/generic.nix | 2 ++ nix/katabatic.nix | 37 ++++++++++++++++------------------- nix/kite.nix | 40 ++++++++++++++++---------------------- nix/tutorial.nix | 37 ++++++++++++++++------------------- nix/unicorn.nix | 49 +++++++++++++++++++++-------------------------- 8 files changed, 99 insertions(+), 121 deletions(-) diff --git a/flake.nix b/flake.nix index bc106790..2235e16b 100644 --- a/flake.nix +++ b/flake.nix @@ -39,15 +39,15 @@ pythonComponents = [ "vlsisapd" "hurricane" "crlcore" "flute" "etesian" - "anabatic" "katana" + "anabatic" "katana" "bora" "katabatic" "kite" + "tutorial" "unicorn" ]; components = pythonComponents ++ [ "lefdef" "bootstrap" "cumulus" "coloquinte" - "bora" "equinox" "knik" "katabatic" "ispd" - "karakaze" "kite" "nimbus" "metis" "mauka" "oroshi" - "solstice" "stratus1" "tutorial" "unicorn" "documentation" - "unittests" + "equinox" "knik" "ispd" "karakaze" "nimbus" + "metis" "mauka" "oroshi" "solstice" "stratus1" + "documentation" "unittests" ]; commonArgs = { inherit version meta generic; }; diff --git a/nix/bora.nix b/nix/bora.nix index 216f5cfb..dc2be996 100644 --- a/nix/bora.nix +++ b/nix/bora.nix @@ -1,25 +1,19 @@ -{ version, meta }: +{ generic, ... }: -{ lib, stdenv, cmake, ninja, python2, boost -, coriolis-bootstrap, coriolis-vlsisapd, coriolis-hurricane -, coriolis-crlcore, qt4, coriolis-katana -, coriolis-flute, coriolis-anabatic -, coriolis-lefdef, qwt6_qt4, doxygen }: - -let boostWithPython = boost.override { enablePython = true; python = python2; }; in - -stdenv.mkDerivation { - pname = "coriolis-bora"; - - src = ../bora; - - buildInputs = [ - python2 boostWithPython coriolis-bootstrap - coriolis-vlsisapd coriolis-hurricane coriolis-crlcore - coriolis-katana qt4 coriolis-flute coriolis-anabatic - coriolis-lefdef qwt6_qt4 - ]; - nativeBuildInputs = [ cmake ninja doxygen ]; - - inherit version meta; -} +let pkg = + { coriolis-vlsisapd, coriolis-hurricane + , coriolis-crlcore, qt4, coriolis-katana + , coriolis-flute, coriolis-anabatic + , coriolis-lefdef, qwt6_qt4, doxygen }: + { + name = "bora"; + src = ../bora; + buildInputs = [ + coriolis-vlsisapd coriolis-hurricane coriolis-crlcore + coriolis-katana qt4 coriolis-flute coriolis-anabatic + coriolis-lefdef qwt6_qt4 + ]; + nativeBuildInputs = [ doxygen ]; + pythonImportsCheck = "Bora"; + }; +in generic pkg diff --git a/nix/etesian.nix b/nix/etesian.nix index 010c99da..e0b15b8e 100644 --- a/nix/etesian.nix +++ b/nix/etesian.nix @@ -8,6 +8,9 @@ let pkg = qt4 coriolis-coloquinte coriolis-vlsisapd coriolis-hurricane coriolis-crlcore ]; + propagatedBuildInputs = [ + coriolis-coloquinte + ]; nativeBuildInputs = [ doxygen ]; pythonImportsCheck = [ "Etesian" ]; }; diff --git a/nix/generic.nix b/nix/generic.nix index 60821641..62fcaee9 100644 --- a/nix/generic.nix +++ b/nix/generic.nix @@ -7,6 +7,7 @@ let f = , src , buildInputs ? [] , nativeBuildInputs ? [] + , propagatedBuildInputs ? [] , pythonImportsCheck }: let @@ -19,6 +20,7 @@ let f = coriolis-bootstrap cmake ninja python2Packages.pythonImportsCheckHook ] ++ nativeBuildInputs; + inherit propagatedBuildInputs; preInstall = '' export PYTHONPATH="$out/${python2Packages.python.sitePackages}:$PYTHONPATH" diff --git a/nix/katabatic.nix b/nix/katabatic.nix index 78aa1934..4a1d4e4f 100644 --- a/nix/katabatic.nix +++ b/nix/katabatic.nix @@ -1,23 +1,18 @@ -{ version, meta }: +{ generic, ... }: -{ lib, stdenv, cmake, ninja, python2, boost -, coriolis-bootstrap, coriolis-vlsisapd, coriolis-hurricane -, coriolis-crlcore, coriolis-flute, coriolis-knik -, qt4, doxygen }: +let pkg = + { coriolis-vlsisapd, coriolis-hurricane + , coriolis-crlcore, coriolis-flute, coriolis-knik + , qt4, doxygen }: + { + name = "katabatic"; + src = ../katabatic; -let boostWithPython = boost.override { enablePython = true; python = python2; }; in - -stdenv.mkDerivation { - pname = "coriolis-katabatic"; - - src = ../katabatic; - - buildInputs = [ - python2 boostWithPython coriolis-bootstrap - coriolis-vlsisapd coriolis-hurricane coriolis-crlcore - coriolis-flute coriolis-knik qt4 - ]; - nativeBuildInputs = [ cmake ninja doxygen ]; - - inherit version meta; -} + buildInputs = [ + coriolis-vlsisapd coriolis-hurricane coriolis-crlcore + coriolis-flute coriolis-knik qt4 + ]; + nativeBuildInputs = [ doxygen ]; + pythonImportsCheck = [ "Katabatic" ]; + }; +in generic pkg diff --git a/nix/kite.nix b/nix/kite.nix index 2f31edea..62b0a141 100644 --- a/nix/kite.nix +++ b/nix/kite.nix @@ -1,24 +1,18 @@ -{ version, meta }: +{ generic, ... }: -{ lib, stdenv, cmake, ninja, python2, boost -, coriolis-lefdef, coriolis-knik, coriolis-katabatic -, coriolis-bootstrap, coriolis-vlsisapd, coriolis-hurricane -, coriolis-crlcore, qt4, coriolis-flute, libxml2, doxygen }: - -let boostWithPython = boost.override { enablePython = true; python = python2; }; in - -stdenv.mkDerivation { - pname = "coriolis-kite"; - - src = ../kite; - - buildInputs = [ - python2 boostWithPython coriolis-bootstrap - coriolis-vlsisapd coriolis-hurricane coriolis-crlcore - coriolis-katabatic qt4 coriolis-flute coriolis-knik libxml2 - coriolis-lefdef - ]; - nativeBuildInputs = [ cmake ninja doxygen ]; - - inherit version meta; -} +let pkg = + { coriolis-lefdef, coriolis-knik, coriolis-katabatic + , coriolis-vlsisapd, coriolis-hurricane + , coriolis-crlcore, qt4, coriolis-flute, libxml2, doxygen }: + { + name = "kite"; + src = ../kite; + buildInputs = [ + coriolis-vlsisapd coriolis-hurricane coriolis-crlcore + coriolis-katabatic qt4 coriolis-flute coriolis-knik libxml2 + coriolis-lefdef + ]; + nativeBuildInputs = [ doxygen ]; + pythonImportsCheck = [ "Kite" ]; + }; +in generic pkg diff --git a/nix/tutorial.nix b/nix/tutorial.nix index bc925e2a..416e3839 100644 --- a/nix/tutorial.nix +++ b/nix/tutorial.nix @@ -1,23 +1,18 @@ -{ version, meta }: +{ generic, ... }: -{ lib, stdenv, cmake, ninja, python2, boost -, coriolis-bootstrap, coriolis-vlsisapd, coriolis-hurricane -, coriolis-crlcore, qt4, coriolis-lefdef, libxml2 -, doxygen }: +let pkg = + { coriolis-vlsisapd, coriolis-hurricane + , coriolis-crlcore, qt4, coriolis-lefdef, libxml2 + , doxygen }: + { + name = "tutorial"; + src = ../tutorial; -let boostWithPython = boost.override { enablePython = true; python = python2; }; in - -stdenv.mkDerivation { - pname = "coriolis-tutorial"; - - src = ../tutorial; - - buildInputs = [ - python2 boostWithPython coriolis-bootstrap - coriolis-vlsisapd coriolis-hurricane coriolis-crlcore - coriolis-lefdef libxml2 qt4 - ]; - nativeBuildInputs = [ cmake ninja doxygen ]; - - inherit version meta; -} + buildInputs = [ + coriolis-vlsisapd coriolis-hurricane coriolis-crlcore + coriolis-lefdef libxml2 qt4 + ]; + nativeBuildInputs = [ doxygen ]; + pythonImportsCheck = [ "Tutorial" ]; + }; +in generic pkg diff --git a/nix/unicorn.nix b/nix/unicorn.nix index 95bdfe8d..4f5deb2e 100644 --- a/nix/unicorn.nix +++ b/nix/unicorn.nix @@ -1,29 +1,24 @@ -{ version, meta }: +{ generic, ... }: -{ lib, stdenv, cmake, ninja, python2, boost -, coriolis-bootstrap, coriolis-vlsisapd, coriolis-hurricane -, coriolis-crlcore, qt4, coriolis-katana -, coriolis-flute, coriolis-anabatic, coriolis-coloquinte -, coriolis-lefdef, coriolis-knik, coriolis-kite -, coriolis-katabatic, coriolis-etesian, coriolis-equinox -, coriolis-solstice, libxml2, doxygen }: +let pkg = + { coriolis-vlsisapd, coriolis-hurricane + , coriolis-crlcore, qt4, coriolis-katana + , coriolis-flute, coriolis-anabatic, coriolis-coloquinte + , coriolis-lefdef, coriolis-knik, coriolis-kite + , coriolis-katabatic, coriolis-etesian, coriolis-equinox + , coriolis-solstice, libxml2, doxygen }: + { + name = "unicorn"; + src = ../unicorn; -let boostWithPython = boost.override { enablePython = true; python = python2; }; in - -stdenv.mkDerivation { - pname = "coriolis-unicorn"; - - src = ../unicorn; - - buildInputs = [ - python2 boostWithPython coriolis-bootstrap - coriolis-vlsisapd coriolis-hurricane coriolis-crlcore - coriolis-katana qt4 coriolis-flute coriolis-anabatic - coriolis-lefdef libxml2 coriolis-knik coriolis-kite - coriolis-katabatic coriolis-etesian coriolis-equinox - coriolis-solstice - ]; - nativeBuildInputs = [ cmake ninja doxygen ]; - - inherit version meta; -} + buildInputs = [ + coriolis-vlsisapd coriolis-hurricane coriolis-crlcore + coriolis-katana qt4 coriolis-flute coriolis-anabatic + coriolis-lefdef libxml2 coriolis-knik coriolis-kite + coriolis-katabatic coriolis-etesian coriolis-equinox + coriolis-solstice + ]; + nativeBuildInputs = [ doxygen ]; + pythonImportsCheck = [ "Unicorn" ]; + }; +in generic pkg