From cad129bd04023e9d5cc7ad4c5b273875a1662e86 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Milan=20P=C3=A4ssler?= Date: Mon, 20 Jul 2020 21:27:32 +0200 Subject: [PATCH] shell.nix: nimble -> nim --- shell.nix | 27 +++++---------------------- 1 file changed, 5 insertions(+), 22 deletions(-) diff --git a/shell.nix b/shell.nix index 287518c..29471af 100644 --- a/shell.nix +++ b/shell.nix @@ -2,32 +2,15 @@ with pkgs; -let - nimlibs = stdenv.mkDerivation { - pname = "nimlibs"; - version = nim.version; - src = nim; - nativeBuildInputs = [ nim ]; - buildPhase = '' - nim c -d:release --nimcache:$PWD -o:libnimrtl.so lib/nimrtl.nim - nim c -d:release --nimcache:$PWD -o:libnimhcr.so lib/nimhcr.nim - ''; - installPhase = '' - install -Dm644 libnimrtl.so $out/lib/libnimrtl.so - install -Dm644 libnimhcr.so $out/lib/libnimhcr.so - ''; - }; - -in stdenv.mkDerivation { - pname = "oeffisearch"; - version = "0.1.0"; +mkShell { + name = "oeffisearch-shell"; nativeBuildInputs = [ nim ]; - LD_LIBRARY_PATH = lib.makeLibraryPath [ openssl nim nimlibs ]; + LD_LIBRARY_PATH = lib.makeLibraryPath [ openssl ]; CACHE_PATH = toString ./cache; NIX_ENFORCE_PURITY = 0; shellHook = '' - #nimble run --hotcodereloading:on oeffisearch - nimble run oeffisearch + nim c src/oeffisearch.nim + ./src/oeffisearch exit ''; }