diff options
author | Paul Joseph Davis <davisp@apache.org> | 2009-09-06 21:55:49 +0000 |
---|---|---|
committer | Paul Joseph Davis <davisp@apache.org> | 2009-09-06 21:55:49 +0000 |
commit | e8769763ef6dd5e38bd458f00a42f531a953cc3c (patch) | |
tree | a054e4a96f0066182dfca97446ab1101fcfd2a1f /configure.ac | |
parent | 9f5c2be171c6964e4e05456833e742b0009bf029 (diff) |
Fix for building CouchDB on Snow Leapord.
I was unable to track down the root cause of this bug, but for some reason, having -ljs in the link command for couch_erl_driver was causing a segfault when loading the latter in Erlang.
This patch just removes -ljs from the global LIBS variable and places it specificially in the libs for couchjs.
git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@811910 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac index a281a868..ddaff741 100644 --- a/configure.ac +++ b/configure.ac @@ -103,10 +103,10 @@ esac AM_CONDITIONAL([WINDOWS], [test x$IS_WINDOWS = xTRUE]) -AC_CHECK_LIB([mozjs], [JS_NewContext], [], [ - AC_CHECK_LIB([js], [JS_NewContext], [], [ - AC_CHECK_LIB([js3250], [JS_NewContext], [], [ - AC_CHECK_LIB([js32], [JS_NewContext], [], [ +AC_CHECK_LIB([mozjs], [JS_NewContext], [JSLIB=-lmozjs], [ + AC_CHECK_LIB([js], [JS_NewContext], [JSLIB=-ljs], [ + AC_CHECK_LIB([js3250], [JS_NewContext], [JSLIB=-ljs3250], [ + AC_CHECK_LIB([js32], [JS_NewContext], [JSLIB=-ljs32], [ AC_MSG_ERROR([Could not find the js library. Is the Mozilla SpiderMonkey library installed?])])])])]) @@ -122,6 +122,8 @@ AC_CHECK_HEADER([jsapi.h], [], [ Are the Mozilla SpiderMonkey headers installed?]) ])]) +AC_SUBST(JSLIB) + AC_LANG_PUSH(C) OLD_CFLAGS="$CFLAGS" CFLAGS="-Werror-implicit-function-declaration" |