You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@couchdb.apache.org by Michael Parker <mi...@gmail.com> on 2012/05/25 00:28:45 UTC
Trouble building from source on CentOS 5.6
Hi all,
I'm having trouble installing CouchDB 1.2 from source as described at
http://wiki.apache.org/couchdb/Installing_SpiderMonkey.
All the header files can be found in /usr/local/include/js/, and
/usr/local/lib looks correct:
$ ls /usr/local/lib/libmozjs185*
/usr/local/lib/libmozjs185-1.0.a /usr/local/lib/libmozjs185.so
/usr/local/lib/libmozjs185.so.1.0 /usr/local/lib/libmozjs185.so.1.0.0
I then run configure for CouchDB with:
./configure --with-js-lib=/usr/local/lib/
--with-js-include=/usr/local/include/js/
During the configure, it seems to be finding some Javascript headers:
checking jsapi.h usability... yes
checking jsapi.h presence... yes
checking for jsapi.h... yes
checking for JS_NewObject in -lmozjs... no
checking for JS_NewObject in -ljs... yes
checking for JS_NewCompartmentAndGlobalObject in -ljs... no
checking for JS_ThrowStopIteration in -ljs... no
checking for JS_GetStringCharsAndLength in -ljs... no
checking for JSScript*... no
But when I run make it quickly fails with:
In file included from couch_js/main.c:20:
couch_js/sm170.c: In function ‘req_status’:
couch_js/sm170.c:105: error: implicit declaration of function
‘INT_FITS_IN_JSVAL’
couch_js/sm170.c: In function ‘evalcx’:
couch_js/sm170.c:138: error: implicit declaration of function
‘JS_GetStringChars’
couch_js/sm170.c:138: error: assignment makes pointer from integer
without a cast
couch_js/sm170.c: In function ‘seal’:
couch_js/sm170.c:220: error: implicit declaration of function ‘JS_SealObject’
couch_js/sm170.c: At top level:
couch_js/sm170.c:236: error: initialization from incompatible pointer type
Note that, on another CentOS 5.6 box where for some mysterious reason
I was able to install CouchDB, running configure in the exact same way
seems to be finding the SpiderMonkey 1.8.5 headers:
checking jsapi.h presence... yes
checking for jsapi.h... yes
checking for JS_NewObject in -lmozjs... no
checking for JS_NewObject in -ljs... no
checking for JS_NewObject in -ljs3250... no
checking for JS_NewObject in -ljs32... no
checking for JS_NewObject in -lmozjs185-1.0... no
checking for JS_NewObject in -lmozjs185... yes
checking for JS_NewCompartmentAndGlobalObject in -lmozjs185... yes
checking whether JSOPTION_ANONFUNFIX is declared... yes
checking for JS_ThrowStopIteration in -lmozjs185... yes
checking for JS_GetStringCharsAndLength in -lmozjs185... yes
checking for JSScript*... no
Note that "checking for JS_NewObject in -lmozjs185" succeeds, and not
"checking for JS_NewObject in -ljs" like on my problematic box.
Running make afterward on this box succeeds.
So configure isn't finding the Spidermonkey 1.8.5 headers, and seem to
be picking up some other, wrong JS headers. Anyone know how I can fix
it?
Thanks,
Mike
Re: Trouble building from source on CentOS 5.6
Posted by Thierry <co...@lechat.org>.
Hi,
As far as I remember (I took notes), I did the following to successfully
install couchdb 1.2 on centos 6, after I got the same kind of error message
about spidermonkey...
Have a try ...
Hot to install couchdb 1.2 on centos6 :
yum update -y
sudo rpm -Uvh
http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-5.noarch.rpm
sudo yum install erlang
yum install gcc-c++
sudo yum install libicu-devel openssl-devel curl-devel make gcc erlang
js-devel libtool which
make
make install
Change "bind_address=0.0.0.0" in /usr/local/etc/couchdb/local.ini
sudo adduser -r --home /usr/local/var/lib/couchdb -M --shell
/bin/bash --comment "CouchDB Admin" couchdb
sudo chown -R couchdb: /usr/local/var/lib/couchdb /usr/local/var/log/couchdb
/usr/local/var/run/couchdb /usr/local/etc/couchdb
sudo ln -s /usr/local/etc/rc.d/couchdb /etc/init.d/couchdb
sudo chkconfig --add couchdb
sudo chkconfig --level 345 couchdb on
sudo service couchdb start
try it with futon. Hope it will be good
Thierry
-----Message d'origine-----
From: Michael Parker
Sent: Friday, May 25, 2012 12:28 AM
To: user@couchdb.apache.org
Subject: Trouble building from source on CentOS 5.6
Hi all,
I'm having trouble installing CouchDB 1.2 from source as described at
http://wiki.apache.org/couchdb/Installing_SpiderMonkey.
All the header files can be found in /usr/local/include/js/, and
/usr/local/lib looks correct:
$ ls /usr/local/lib/libmozjs185*
/usr/local/lib/libmozjs185-1.0.a /usr/local/lib/libmozjs185.so
/usr/local/lib/libmozjs185.so.1.0 /usr/local/lib/libmozjs185.so.1.0.0
I then run configure for CouchDB with:
./configure --with-js-lib=/usr/local/lib/
--with-js-include=/usr/local/include/js/
During the configure, it seems to be finding some Javascript headers:
checking jsapi.h usability... yes
checking jsapi.h presence... yes
checking for jsapi.h... yes
checking for JS_NewObject in -lmozjs... no
checking for JS_NewObject in -ljs... yes
checking for JS_NewCompartmentAndGlobalObject in -ljs... no
checking for JS_ThrowStopIteration in -ljs... no
checking for JS_GetStringCharsAndLength in -ljs... no
checking for JSScript*... no
But when I run make it quickly fails with:
In file included from couch_js/main.c:20:
couch_js/sm170.c: In function ‘req_status’:
couch_js/sm170.c:105: error: implicit declaration of function
‘INT_FITS_IN_JSVAL’
couch_js/sm170.c: In function ‘evalcx’:
couch_js/sm170.c:138: error: implicit declaration of function
‘JS_GetStringChars’
couch_js/sm170.c:138: error: assignment makes pointer from integer
without a cast
couch_js/sm170.c: In function ‘seal’:
couch_js/sm170.c:220: error: implicit declaration of function ‘JS_SealObject’
couch_js/sm170.c: At top level:
couch_js/sm170.c:236: error: initialization from incompatible pointer type
Note that, on another CentOS 5.6 box where for some mysterious reason
I was able to install CouchDB, running configure in the exact same way
seems to be finding the SpiderMonkey 1.8.5 headers:
checking jsapi.h presence... yes
checking for jsapi.h... yes
checking for JS_NewObject in -lmozjs... no
checking for JS_NewObject in -ljs... no
checking for JS_NewObject in -ljs3250... no
checking for JS_NewObject in -ljs32... no
checking for JS_NewObject in -lmozjs185-1.0... no
checking for JS_NewObject in -lmozjs185... yes
checking for JS_NewCompartmentAndGlobalObject in -lmozjs185... yes
checking whether JSOPTION_ANONFUNFIX is declared... yes
checking for JS_ThrowStopIteration in -lmozjs185... yes
checking for JS_GetStringCharsAndLength in -lmozjs185... yes
checking for JSScript*... no
Note that "checking for JS_NewObject in -lmozjs185" succeeds, and not
"checking for JS_NewObject in -ljs" like on my problematic box.
Running make afterward on this box succeeds.
So configure isn't finding the Spidermonkey 1.8.5 headers, and seem to
be picking up some other, wrong JS headers. Anyone know how I can fix
it?
Thanks,
Mike
Re: Trouble building from source on CentOS 5.6
Posted by Dave Cottlehuber <da...@muse.net.nz>.
On 25 May 2012 10:59, Mike Kimber <mk...@kana.com> wrote:
> Ah apologies read this to quickly your trying to build spikermonkey. I
> tried this to and had a similar set of issues so ended up just going with
> yum js-devel which I believe installs spidermonkey from the repo. When you
> do find an answer it would be good to know the solution.
>
> Also looks like this mailing list strips attachments, so if you'd still
> like it then let me know and I'll find somewhere to put it that's publicly
> accessible.
>
>
Hi Mike (Kember),
The wiki would be excellent - just add a page on
http://wiki.apache.org/couchdb/Installation
If you don't have a wiki access yet, just sign up, and pop onto IRC or
reply here to get your acct added to the contributors group. This is a pain
but has resulted in 0 spam since we turned that on.
@Michael (Parker) the issue appears to be that you have 2 SM installed, and
couchdb is ignoring the expected one and falling back to compiling with the
1.7.0 couchjs integration. If you can paste details from pkg-config,
config.log and output from configure somewhere convenient we might be able
to work out what's failing.
A+
Dave
RE: Trouble building from source on CentOS 5.6
Posted by Mike Kimber <mk...@kana.com>.
Ah apologies read this to quickly your trying to build spikermonkey. I tried this to and had a similar set of issues so ended up just going with yum js-devel which I believe installs spidermonkey from the repo. When you do find an answer it would be good to know the solution.
Also looks like this mailing list strips attachments, so if you'd still like it then let me know and I'll find somewhere to put it that's publicly accessible.
Mike
-----Original Message-----
From: Mike Kimber [mailto:mkimber@kana.com]
Sent: 25 May 2012 09:01
To: user@couchdb.apache.org
Subject: RE: Trouble building from source on CentOS 5.6
Attached is the process I follow to install Couchdb 1.2 on Centos 5.7.
Spidermonkey does seem to be a bit of an issue depending on what version of it gets installed.
Hope it helps
Mike
-----Original Message-----
From: Michael Parker [mailto:michael.g.parker@gmail.com]
Sent: 24 May 2012 23:29
To: user@couchdb.apache.org
Subject: Trouble building from source on CentOS 5.6
Hi all,
I'm having trouble installing CouchDB 1.2 from source as described at
http://wiki.apache.org/couchdb/Installing_SpiderMonkey.
All the header files can be found in /usr/local/include/js/, and
/usr/local/lib looks correct:
$ ls /usr/local/lib/libmozjs185*
/usr/local/lib/libmozjs185-1.0.a /usr/local/lib/libmozjs185.so
/usr/local/lib/libmozjs185.so.1.0 /usr/local/lib/libmozjs185.so.1.0.0
I then run configure for CouchDB with:
./configure --with-js-lib=/usr/local/lib/
--with-js-include=/usr/local/include/js/
During the configure, it seems to be finding some Javascript headers:
checking jsapi.h usability... yes
checking jsapi.h presence... yes
checking for jsapi.h... yes
checking for JS_NewObject in -lmozjs... no
checking for JS_NewObject in -ljs... yes
checking for JS_NewCompartmentAndGlobalObject in -ljs... no
checking for JS_ThrowStopIteration in -ljs... no
checking for JS_GetStringCharsAndLength in -ljs... no
checking for JSScript*... no
But when I run make it quickly fails with:
In file included from couch_js/main.c:20:
couch_js/sm170.c: In function 'req_status':
couch_js/sm170.c:105: error: implicit declaration of function
'INT_FITS_IN_JSVAL'
couch_js/sm170.c: In function 'evalcx':
couch_js/sm170.c:138: error: implicit declaration of function
'JS_GetStringChars'
couch_js/sm170.c:138: error: assignment makes pointer from integer
without a cast
couch_js/sm170.c: In function 'seal':
couch_js/sm170.c:220: error: implicit declaration of function 'JS_SealObject'
couch_js/sm170.c: At top level:
couch_js/sm170.c:236: error: initialization from incompatible pointer type
Note that, on another CentOS 5.6 box where for some mysterious reason
I was able to install CouchDB, running configure in the exact same way
seems to be finding the SpiderMonkey 1.8.5 headers:
checking jsapi.h presence... yes
checking for jsapi.h... yes
checking for JS_NewObject in -lmozjs... no
checking for JS_NewObject in -ljs... no
checking for JS_NewObject in -ljs3250... no
checking for JS_NewObject in -ljs32... no
checking for JS_NewObject in -lmozjs185-1.0... no
checking for JS_NewObject in -lmozjs185... yes
checking for JS_NewCompartmentAndGlobalObject in -lmozjs185... yes
checking whether JSOPTION_ANONFUNFIX is declared... yes
checking for JS_ThrowStopIteration in -lmozjs185... yes
checking for JS_GetStringCharsAndLength in -lmozjs185... yes
checking for JSScript*... no
Note that "checking for JS_NewObject in -lmozjs185" succeeds, and not
"checking for JS_NewObject in -ljs" like on my problematic box.
Running make afterward on this box succeeds.
So configure isn't finding the Spidermonkey 1.8.5 headers, and seem to
be picking up some other, wrong JS headers. Anyone know how I can fix
it?
Thanks,
Mike
RE: Trouble building from source on CentOS 5.6
Posted by Mike Kimber <mk...@kana.com>.
Attached is the process I follow to install Couchdb 1.2 on Centos 5.7.
Spidermonkey does seem to be a bit of an issue depending on what version of it gets installed.
Hope it helps
Mike
-----Original Message-----
From: Michael Parker [mailto:michael.g.parker@gmail.com]
Sent: 24 May 2012 23:29
To: user@couchdb.apache.org
Subject: Trouble building from source on CentOS 5.6
Hi all,
I'm having trouble installing CouchDB 1.2 from source as described at
http://wiki.apache.org/couchdb/Installing_SpiderMonkey.
All the header files can be found in /usr/local/include/js/, and
/usr/local/lib looks correct:
$ ls /usr/local/lib/libmozjs185*
/usr/local/lib/libmozjs185-1.0.a /usr/local/lib/libmozjs185.so
/usr/local/lib/libmozjs185.so.1.0 /usr/local/lib/libmozjs185.so.1.0.0
I then run configure for CouchDB with:
./configure --with-js-lib=/usr/local/lib/
--with-js-include=/usr/local/include/js/
During the configure, it seems to be finding some Javascript headers:
checking jsapi.h usability... yes
checking jsapi.h presence... yes
checking for jsapi.h... yes
checking for JS_NewObject in -lmozjs... no
checking for JS_NewObject in -ljs... yes
checking for JS_NewCompartmentAndGlobalObject in -ljs... no
checking for JS_ThrowStopIteration in -ljs... no
checking for JS_GetStringCharsAndLength in -ljs... no
checking for JSScript*... no
But when I run make it quickly fails with:
In file included from couch_js/main.c:20:
couch_js/sm170.c: In function 'req_status':
couch_js/sm170.c:105: error: implicit declaration of function
'INT_FITS_IN_JSVAL'
couch_js/sm170.c: In function 'evalcx':
couch_js/sm170.c:138: error: implicit declaration of function
'JS_GetStringChars'
couch_js/sm170.c:138: error: assignment makes pointer from integer
without a cast
couch_js/sm170.c: In function 'seal':
couch_js/sm170.c:220: error: implicit declaration of function 'JS_SealObject'
couch_js/sm170.c: At top level:
couch_js/sm170.c:236: error: initialization from incompatible pointer type
Note that, on another CentOS 5.6 box where for some mysterious reason
I was able to install CouchDB, running configure in the exact same way
seems to be finding the SpiderMonkey 1.8.5 headers:
checking jsapi.h presence... yes
checking for jsapi.h... yes
checking for JS_NewObject in -lmozjs... no
checking for JS_NewObject in -ljs... no
checking for JS_NewObject in -ljs3250... no
checking for JS_NewObject in -ljs32... no
checking for JS_NewObject in -lmozjs185-1.0... no
checking for JS_NewObject in -lmozjs185... yes
checking for JS_NewCompartmentAndGlobalObject in -lmozjs185... yes
checking whether JSOPTION_ANONFUNFIX is declared... yes
checking for JS_ThrowStopIteration in -lmozjs185... yes
checking for JS_GetStringCharsAndLength in -lmozjs185... yes
checking for JSScript*... no
Note that "checking for JS_NewObject in -lmozjs185" succeeds, and not
"checking for JS_NewObject in -ljs" like on my problematic box.
Running make afterward on this box succeeds.
So configure isn't finding the Spidermonkey 1.8.5 headers, and seem to
be picking up some other, wrong JS headers. Anyone know how I can fix
it?
Thanks,
Mike