From c49d97a9c13fc9e3d012acb16e5ca511e4b04ca7 Mon Sep 17 00:00:00 2001 From: Claudius Holeksa Date: Tue, 23 May 2023 18:09:32 +0200 Subject: nix: Adding initial setup --- .nix/derivation.nix | 24 ++++++++++++++++++++++++ default.nix | 18 ++++++++++++++++++ 2 files changed, 42 insertions(+) create mode 100644 .nix/derivation.nix create mode 100644 default.nix diff --git a/.nix/derivation.nix b/.nix/derivation.nix new file mode 100644 index 0000000..6b1f4f7 --- /dev/null +++ b/.nix/derivation.nix @@ -0,0 +1,24 @@ +{ lib +, stdenvNoCC +, scons +, clang +, forstio +, kel-unit +}: + +stdenvNoCC.mkDerivation { + pname = "kel-lbm"; + version = "0.0.0"; + src = ./..; + + nativeBuildInputs = [ + scons + clang + ]; + + buildInputs = [ + kel-unit + ]; + + outputs = [ "out" ]; +} diff --git a/default.nix b/default.nix new file mode 100644 index 0000000..f93b364 --- /dev/null +++ b/default.nix @@ -0,0 +1,18 @@ +{ pkgs ? import {} +}: + +let + forstio = (import ((builtins.fetchGit { + url = "git@git.keldu.de:forstio/forstio"; + ref = "dev"; + }).outPath + "/default.nix"){}).forstio; + + kel-unit = (import ((builtins.fetchGit { + url = "git@git.keldu.de:libs/unit"; + ref = "dev"; + }).outPath + "/default.nix"){}); + +in pkgs.callPackage ./.nix/derivation.nix { + inherit forstio; + inherit kel-unit; +} -- cgit v1.2.3