I tried installing luasql on my Linux CentOS 7 computer using this command:
luarocks install luasql-postgres
but unfortunately I got the following error:
Installing https://raw.githubusercontent.com/rocks-moonscript-org/moonrocks-mirror/master/luasql-postgres-2.3.5-2.rockspec...
Using https://raw.githubusercontent.com/rocks-moonscript-org/moonrocks-mirror/master/luasql-postgres-2.3.5-2.rockspec... switching to 'build' mode
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
I tried to run the last line luarocks install luasql-postgres PGSQL_DIR=/usr/local
, but I had no improvement ...
What should I do?
source
share