去apache下载到couchDB 1.1.1版本,在debian上解压到目录couchDB,进入目录,命令:
./configure
报错:
configure: error: Could not find the js library.
Is the Mozilla SpiderMonkey library installed?
需要先安装SpiderMonkey,这是一个JS的引擎由Mozilla基金维护,安装不难,下载地址
http://ftp.mozilla.org/pub/mozilla.org/js/
下载了1.7那个,然后在debian上解压,进入js/src,命令:
make BUILD_OPT=1 -f Makefile.ref
命令:
make BUILD_OPT=1 JS_DIST=/usr/local -f Makefile.ref export
然后再去couchDB那儿
./configure
报错:
configure: error: Your SpiderMonkey library is too new.
真让人难受不是,现在卸载1.7的SM,根据当时make的信息,在usr/local/的目录下bin,lib,included子目录下删除make命令拷贝进去的东西,然后回过来把整个SpiderMonkey都删除了。接着下载js185-1.0.0版本,解压,进入到src目录,命令
./configure
make
编译完成后,回去配置couchDB,说找不到spider的库,因为,这个185xx的版本没有那个拷贝库到usr/local/lib的流程,所以,在configure的时候设置库路径参数,命令:
./configure --with-js-lib=/usr/local/spidermonkey/lib --with-js-include=/usr/local/spidermonkey/include
把路径改成到src目录的路径。这样之后报错:
The icu-config script could not be found.
安装icu似乎很简单,命令
apt-get install libicu-dev
然后在像上面那样configure,报错:
Could not find the `erl' executable. Is Erlang installed?
安装erl,,命令:
apt-get install erlang-nox erlang-dev
安装好了,在按上面的命令configure,哦yeah,提示:You have configured Apache CouchDB, time to relax.,接下来,命令
make install
然后,哈哈!提示我:You have installed Apache CouchDB, time to relax.