-
-
Save Thomashrb/d67ae419527ed59762cbcf7d32046254 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
What I am missing is: | |
``` | |
$ luarocks install luasql-postgres --local | |
Installing https://luarocks.org/luasql-postgres-2.3.5-2.rockspec | |
Error: Could not find header file for PGSQL | |
No file libpq-fe.h in /usr/local/include | |
No file libpq-fe.h in /usr/include | |
You may have to install PGSQL in your system and/or pass PGSQL_DIR or PGSQL_INCDIR to the luarocks command. | |
Example: luarocks install luasql-postgres PGSQL_DIR=/usr/local | |
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with import <nixpkgs> {}; | |
with luaPackages; | |
let | |
libs = [lua cjson luasocket luasec]; | |
in | |
stdenv.mkDerivation { | |
name = "streamstore-env"; | |
buildInputs = [ | |
nginx | |
ffmpeg | |
libs | |
luarocks | |
libpqxx | |
]; | |
shellHook = '' | |
export LUA_CPATH="${lib.concatStringsSep ";" (map getLuaCPath libs)}" | |
export LUA_PATH="${lib.concatStringsSep ";" (map getLuaPath libs)}" | |
export PGSQL_INCDIR=${postgresql}/include | |
export PGSQL_LIBDIR=${postgresql.lib}/lib | |
luarocks install penlight --local | |
''; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment