2016-05-07 46 views
2

我試圖在Cent OS中安裝luarocks。 命令後./configure我得到錯誤:如何在Cent OS中安裝luarocks?

Lua interpreter found: /bin/lua... 
Lua version detected: 5.1 
lua found in $PATH: /bin 
Checking Lua includes... lua.h not found (looked in //include, //include/lua/5.1, //include/lua5.1) 
You may want to use the flag --with-lua or --with-lua-include. See --help. 

正如我理解正確的話,起先我需要安裝Lua和指定路徑到Lua時配置luarocks

回答

2

具有/bin(而不是/usr/bin)似乎Lua解釋異常。

您是否在某處安裝了文件lua.h? (換句話說,你安裝的Lua開發頭?)你應該能夠它使用locate命令查找:

locate lua.h 

如果你確實有lua.h(例如,在/usr/include),告訴配置腳本其中,該文件位於,就像錯誤信息提示您:

./configure --with-lua-include=/usr/include 
+0

難道這是因爲[UsrMerge(https://www.freedesktop.org/wiki/Software/systemd/TheCaseForTheUsrMerge/) ? LuaRocks的'configure'腳本應該檢查一下嗎? – siffiejoe

+0

它可能是。哦,自2003年以來,GoboLinux已經將/ usr/bin和/ bin(和/ sbin和/ usr/bin)合併在一起,我們從來沒有遇到過問題。我需要在某個時候重寫'configure'腳本。有一些錯誤的案例, –