[buildout]

extends =
  ../openssl/buildout.cfg
  ../curl/buildout.cfg
  ../erlang/buildout.cfg
  ../icu/buildout.cfg
  ../spidermonkey/buildout.cfg

parts = couchdb

[couchdb]
recipe = slapos.recipe.cmmi
url = http://mir2.ovh.net/ftp.apache.org/dist//couchdb/1.1.1/apache-couchdb-1.1.1.tar.gz
md5sum = cd126219b9cb69a4c521abd6960807a6
configure-options =
  --with-erlang=${erlang:location}/lib/erlang/usr/include
  --with-js-include=${spidermonkey-1.7:location}/include
  --with-js-lib=${erlang:location}/lib
  --enable-js-trunk
environment-section = couchdb-environ

[couchdb-environ]
PATH = ${erlang:location}/bin:${icu4c:location}/bin:${curl:location}/bin:%(PATH)s
# XXX: Gotta put everything on the same line. If not, it won't compile
CFLAGS = -I${icu4c:location}/include -I${spidermonkey-1.7:location}/include -I${curl:location}/include
LDFLAGS = -L${icu4c:location}/lib -Wl,-rpath=${icu4c:location}/lib -L${spidermonkey-1.7:location}/lib -Wl,-rpath=${spidermonkey-1.7:location}/lib -L${curl:location}/lib -Wl,-rpath=${curl:location}/lib
