在Centos 6.8上安装CouchDB 2.0

时间:2016-10-28 14:52:16

标签: couchdb couchdb-2.0

我试图在CentOS 6.8上安装CouchDB 2.0并遇到此错误,我不确定是什么问题。

任何想法??

这是日志:

Compiled src/couch_db.erl
Compiled src/couch_native_process.erl
Compiled src/couch_util.erl
Compiling /root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c
/root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c:18:19: warning: jsapi.h: No such file or directory
In file included from /root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c:20:
priv/couch_js/utf8.h:16: error: expected ‘)’ before ‘*’ token
priv/couch_js/utf8.h:17: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
In file included from /root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c:21:
priv/couch_js/util.h:25: error: expected specifier-qualifier-list before ‘JSString’
priv/couch_js/util.h:30: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
priv/couch_js/util.h:31: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
priv/couch_js/util.h:32: error: expected ‘)’ before ‘*’ token
priv/couch_js/util.h:33: error: expected ‘)’ before ‘*’ token
priv/couch_js/util.h:34: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘couch_load_funcs’
/root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c:37: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘http_ctor’
/root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c:44: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘http_dtor’
/root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c:51: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘http_open’
/root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c:58: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘http_set_hdr’
/root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c:65: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘http_send’
/root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c:72: error: expected ‘)’ before ‘*’ token
/root/apache-couchdb-2.0.0/src/couch/priv/couch_js/http.c:78: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘http_uri’
ERROR: compile failed while processing /root/apache-couchdb-2.0.0/src/couch: rebar_abort
make: *** [couch] Error 1

谢谢

1 个答案:

答案 0 :(得分:0)

因为jsapi.h默认情况下是/usr/local/include/js/

尝试使用/ usr上的前缀编译SpiderMonkey,如下所示:

./configure --prefix=/usr && make && make install

再次编译couchdb。