感謝StackOverflow社區的幫助,我能夠在我的computer running Linux CentOS 7上正確安裝luasql。如何在Linux Ubuntu 16上安裝luasql?
現在我有一個類似的問題在Linux Ubuntu的16 我嘗試下面的命令:
sudo apt-get -y install lua-sql-postgres
sudo apt-get -y install lua-sql-postgres-dev
sudo luarocks install luasql-postgres
下面是我從系統中得到的錯誤:
Installing https://rocks.moonscript.org/luasql-postgres-2.3.5-2.rockspec...
Using https://rocks.moonscript.org/luasql-postgres-2.3.5-2.rockspec... switching to 'build' mode
Error: Could not find expected file libpq-fe.h, or libpq-fe.h for PGSQL -- 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
有誰知道解決這個問題? 感謝
請安裝'的libpq-dev':該文件是'/ usr/include目錄/ postgresql/libpq-fe.h' http://packages.ubuntu.com/xenial-updates/amd64/libpq-dev/filelist –