Skip to content
This repository
Browse code

make compile on linux

  • Loading branch information...
commit 737bb4a20a45fbc3f876861c0e64ccb7708c9d74 1 parent b4c6c62
Jan Lehnardt authored

Showing 1 changed file with 14 additions and 6 deletions. Show diff stats Hide diff stats

  1. +14 6 couchdbx-core-builder.sh
20 couchdbx-core-builder.sh
@@ -12,7 +12,7 @@ COUCHDB_VERSION="0.9.1"
12 12 COUCHDB_SVNPAPTH="tags/$COUCHDB_VERSION"
13 13
14 14 # or R12B-5
15   -ERLANG_VERSION="R13B"
  15 +ERLANG_VERSION="R13B01"
16 16
17 17 # make options
18 18 MAKE_OPTS="-j4"
@@ -186,8 +186,10 @@ couchdb_link_erl_driver()
186 186
187 187 couchdb_post_install()
188 188 {
189   - # build couch_erl_driver.so against bundlered ICU
190   - couchdb_link_erl_driver
  189 + if [ "`uname`" eq "Darwin"]; then
  190 + # build couch_erl_driver.so against bundlered ICU
  191 + couchdb_link_erl_driver
  192 + fi
191 193
192 194 cd ../../dist/couchdb
193 195 # replace absolute to relative paths
@@ -241,13 +243,19 @@ download_js()
241 243 install_js()
242 244 {
243 245 if [ ! -e .js-installed ]; then
  246 + uname=`uname`
  247 + if [ "$uname" -eq "Darwin" ]; then
  248 + soext="dylib"
  249 + else
  250 + soext="so"
  251 + fi
244 252 cd src/js
245 253 cd src
246 254 make $MAKEOPTS -f Makefile.ref
247 255 JS_DIST=$WORKDIR/dist/js make -f Makefile.ref export
248 256 cd ../../../
249   - mkdir dist/Darwin_DBG.OBJ/
250   - cp dist/js/lib/libjs.dylib dist/Darwin_DBG.OBJ/libjs.dylib
  257 + mkdir -p dist/${uname}_DBG.OBJ/
  258 + cp dist/js/lib*/libjs.$soext dist/${uname}_DBG.OBJ/libjs.$soext
251 259 touch .js-installed
252 260 fi
253 261 }
@@ -269,7 +277,7 @@ package()
269 277 rm -rf couchdbx-core
270 278 mkdir couchdbx-core
271 279 cp -r dist/* couchdbx-core
272   - tar czf couchdbx-core-$COCUHDB_VERSION-$ERLANG_VERSION.tar.gz couchdbx-core
  280 + tar czf couchdbx-core-$COUCHDB_VERSION-$ERLANG_VERSION.tar.gz couchdbx-core
273 281 }
274 282
275 283 # main:

0 comments on commit 737bb4a

Please sign in to comment.
Something went wrong with that request. Please try again.