diff options
author | Philipp Gesang <phg@phi-gamma.net> | 2018-09-08 23:53:17 +0200 |
---|---|---|
committer | Philipp Gesang <phg@phi-gamma.net> | 2018-09-08 23:53:17 +0200 |
commit | 84deebeb4d714e5f8a6cac1829fed5ec4aa63418 (patch) | |
tree | 5539ace7f45edf6b5a420edc80a03dc548af3a6d /misc | |
parent | 1aaa67daf4db00bb3a6e494c40b2fbe375ec4f56 (diff) | |
download | caldr-84deebeb4d714e5f8a6cac1829fed5ec4aa63418.tar.gz |
misc: add nix-shell that provides all dependencies
Diffstat (limited to 'misc')
-rw-r--r-- | misc/nix-lua-shell.nix | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/misc/nix-lua-shell.nix b/misc/nix-lua-shell.nix new file mode 100644 index 0000000..1bf881e --- /dev/null +++ b/misc/nix-lua-shell.nix @@ -0,0 +1,20 @@ +with import <nixpkgs> {}; +with lua53Packages; + +let + libs = [ + lua5_3 + lua53Packages.lpeg + lua53Packages.cjson + lua53Packages.luaposix + ]; +in +stdenv.mkDerivation rec { + name = "lua-env"; + buildInputs = libs; + + shellHook = '' + export LUA_CPATH="${lib.concatStringsSep ";" (map getLuaCPath libs)};./?.so" + export LUA_PATH="${lib.concatStringsSep ";" (map getLuaPath libs)};./?.lua" + ''; +} |