You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by "Robert Rees (JIRA)" <ji...@apache.org> on 2008/04/28 23:01:56 UTC

[jira] Created: (COUCHDB-47) Building CouchDB against Spidermonkey source

Building CouchDB against Spidermonkey source
--------------------------------------------

                 Key: COUCHDB-47
                 URL: https://issues.apache.org/jira/browse/COUCHDB-47
             Project: CouchDB
          Issue Type: Bug
          Components: Build System
         Environment: OSX Leopard, Spidermonkey 1.7, Erlang 5.6, CouchDB r650729
            Reporter: Robert Rees


When trying to build against my source distribution of Spidermonkey the build script acknowledges the existence of libjs but gives an error message that the header files (jsapi.h) is not present. This seems to be due to an error in the test file the build script constructs to test the include of the header file.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (COUCHDB-47) Building CouchDB against Spidermonkey source

Posted by "Jan Lehnardt (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-47?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12592895#action_12592895 ] 

Jan Lehnardt commented on COUCHDB-47:
-------------------------------------

Please see http://wiki.apache.org/couchdb/InstallingSpiderMonkey

> Building CouchDB against Spidermonkey source
> --------------------------------------------
>
>                 Key: COUCHDB-47
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-47
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Build System
>         Environment: OSX Leopard, Spidermonkey 1.7, Erlang 5.6, CouchDB r650729
>            Reporter: Robert Rees
>
> When trying to build against my source distribution of Spidermonkey the build script acknowledges the existence of libjs but gives an error message that the header files (jsapi.h) is not present. This seems to be due to an error in the test file the build script constructs to test the include of the header file.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (COUCHDB-47) --with-js-lib configure flag does not work

Posted by "Noah Slater (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-47?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12592901#action_12592901 ] 

Noah Slater commented on COUCHDB-47:
------------------------------------

Please follow the first few steps from here:

   http://wiki.apache.org/couchdb/Troubleshooting

If it still doesn't work can you:

  * provide details about what flags you are using
  * provide the a listing of directory contents of the directories you are passing to configure
  * attach the full output of running ./configure
  * attach the full config.log file

> --with-js-lib configure flag does not work
> ------------------------------------------
>
>                 Key: COUCHDB-47
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-47
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Build System
>         Environment: OSX Leopard, Spidermonkey 1.7, Erlang 5.6, CouchDB r650729
>            Reporter: Robert Rees
>
> When trying to build against my source distribution of Spidermonkey the build script acknowledges the existence of libjs but gives an error message that the header files (jsapi.h) is not present. This seems to be due to an error in the test file the build script constructs to test the include of the header file.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (COUCHDB-47) --with-js-lib configure flag does not work

Posted by "Robert Rees (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-47?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12592914#action_12592914 ] 

Robert Rees commented on COUCHDB-47:
------------------------------------

The problem is this line:

configure:19518: gcc -c -g -O2 -L/usr/local/lib -L/opt/local/lib -L/Users/rrees/Documents/dev/js/src/Darwin_DBG.OBJ/ -I${exec_prefix}/lib/erlang/usr/include -I/usr/lib/erlang/usr/include -I/usr/local/lib/erlang/usr/include -I/opt/local/lib/erlang/usr/include -I/Users/rrees/Documents/dev/js/src/ -DXP_UNIX   conftest.c >&5
In file included from /Users/rrees/Documents/dev/js/src/jspubtd.h:45,
                 from /Users/rrees/Documents/dev/js/src/jsapi.h:47,
                 from conftest.c:56:
/Users/rrees/Documents/dev/js/src/jstypes.h:245:71: error: jsautocfg.h: No such file or directory

Ignoring my local stuff the jsautocfg.h is under the Darwin_DBG.OBJ directory not under js/src. Both directories need to be -I on the cc line.

> --with-js-lib configure flag does not work
> ------------------------------------------
>
>                 Key: COUCHDB-47
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-47
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Build System
>         Environment: OSX Leopard, Spidermonkey 1.7, Erlang 5.6, CouchDB r650729
>            Reporter: Robert Rees
>
> When trying to build against my source distribution of Spidermonkey the build script acknowledges the existence of libjs but gives an error message that the header files (jsapi.h) is not present. This seems to be due to an error in the test file the build script constructs to test the include of the header file.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (COUCHDB-47) --with-js-lib configure flag does not work

Posted by "Noah Slater (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-47?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12596027#action_12596027 ] 

Noah Slater commented on COUCHDB-47:
------------------------------------

It shouldn't matter where you install them, /usr/local is not special in any way. Have you tried using the --with-js-include option as well, you will need it to get the header files included.

> --with-js-lib configure flag does not work
> ------------------------------------------
>
>                 Key: COUCHDB-47
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-47
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Build System
>         Environment: OSX Leopard, Spidermonkey 1.7, Erlang 5.6, CouchDB r650729
>            Reporter: Robert Rees
>
> When trying to build against my source distribution of Spidermonkey the build script acknowledges the existence of libjs but gives an error message that the header files (jsapi.h) is not present. This seems to be due to an error in the test file the build script constructs to test the include of the header file.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (COUCHDB-47) --with-js-lib configure flag does not work

Posted by "Noah Slater (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/COUCHDB-47?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Noah Slater resolved COUCHDB-47.
--------------------------------

    Resolution: Fixed

Agreed. If anything is missing from the documentation, it should be added it to the wiki page mentioned above.

> --with-js-lib configure flag does not work
> ------------------------------------------
>
>                 Key: COUCHDB-47
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-47
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Build System
>         Environment: OSX Leopard, Spidermonkey 1.7, Erlang 5.6, CouchDB r650729
>            Reporter: Robert Rees
>
> When trying to build against my source distribution of Spidermonkey the build script acknowledges the existence of libjs but gives an error message that the header files (jsapi.h) is not present. This seems to be due to an error in the test file the build script constructs to test the include of the header file.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-47) --with-js-lib configure flag does not work

Posted by "Robert Rees (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/COUCHDB-47?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Robert Rees updated COUCHDB-47:
-------------------------------

    Summary: --with-js-lib configure flag does not work  (was: Building CouchDB against Spidermonkey source)

Realised the original title gave the wrong idea about the bug. The issue is not that you can't build on OSX but that the configure flag is not working properly.

> --with-js-lib configure flag does not work
> ------------------------------------------
>
>                 Key: COUCHDB-47
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-47
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Build System
>         Environment: OSX Leopard, Spidermonkey 1.7, Erlang 5.6, CouchDB r650729
>            Reporter: Robert Rees
>
> When trying to build against my source distribution of Spidermonkey the build script acknowledges the existence of libjs but gives an error message that the header files (jsapi.h) is not present. This seems to be due to an error in the test file the build script constructs to test the include of the header file.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (COUCHDB-47) --with-js-lib configure flag does not work

Posted by "Robert Rees (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-47?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12593066#action_12593066 ] 

Robert Rees commented on COUCHDB-47:
------------------------------------

Yeah I'll try and explain a bit better and provide a hacky fix that might explain better than just words! I have built Spidermonkey using the default instructions and the during the build the jsautocfg.h is created in the target (DARWIN_DBG.OBJ). I imagine that during the install process for Spidermonkey the headers from both source and target platform are placed in the same include directory, however by default the headers in both js/src/ and js/src/TARGET_PLATFORM need to be included.

So for example I have managed to fix the issue by changing the --with-js-lib case to the following:

# Check whether --with-js-lib was given.
if test "${with_js_lib+set}" = set; then
  withval=$with_js_lib; JS_LIB_FLAGS="-L$withval"
  JS_INCLUDE_FLAGS="$JS_INCLUDE_FLAGS -I$withval"
fi

Looking at it again I think the issue is that -with-js-include is probably meant to point at an installed Spidermonkey whereas I am building ICU, Spidermonkey and CouchDB side by side without ever installing any of them to /usr/local (or similar).

If this is the case then the bug could probably be resolved by documentation and I could just symbolically link jsautocfg.h to js/src to make this compilation step pass.

> --with-js-lib configure flag does not work
> ------------------------------------------
>
>                 Key: COUCHDB-47
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-47
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Build System
>         Environment: OSX Leopard, Spidermonkey 1.7, Erlang 5.6, CouchDB r650729
>            Reporter: Robert Rees
>
> When trying to build against my source distribution of Spidermonkey the build script acknowledges the existence of libjs but gives an error message that the header files (jsapi.h) is not present. This seems to be due to an error in the test file the build script constructs to test the include of the header file.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (COUCHDB-47) --with-js-lib configure flag does not work

Posted by "Noah Slater (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-47?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12592997#action_12592997 ] 

Noah Slater commented on COUCHDB-47:
------------------------------------

Sorry to be a pain but could you explain this more or follow the steps outlined previously.

> --with-js-lib configure flag does not work
> ------------------------------------------
>
>                 Key: COUCHDB-47
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-47
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Build System
>         Environment: OSX Leopard, Spidermonkey 1.7, Erlang 5.6, CouchDB r650729
>            Reporter: Robert Rees
>
> When trying to build against my source distribution of Spidermonkey the build script acknowledges the existence of libjs but gives an error message that the header files (jsapi.h) is not present. This seems to be due to an error in the test file the build script constructs to test the include of the header file.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (COUCHDB-47) --with-js-lib configure flag does not work

Posted by "Christopher Lenz (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-47?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599726#action_12599726 ] 

Christopher Lenz commented on COUCHDB-47:
-----------------------------------------

I think this should be closed, we should be able to expect dependencies to be correctly installed, not only compiled.

http://wiki.apache.org/couchdb/InstallingSpiderMonkey contains (some) documentation on how to install SpiderMonkey from source.

> --with-js-lib configure flag does not work
> ------------------------------------------
>
>                 Key: COUCHDB-47
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-47
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Build System
>         Environment: OSX Leopard, Spidermonkey 1.7, Erlang 5.6, CouchDB r650729
>            Reporter: Robert Rees
>
> When trying to build against my source distribution of Spidermonkey the build script acknowledges the existence of libjs but gives an error message that the header files (jsapi.h) is not present. This seems to be due to an error in the test file the build script constructs to test the include of the header file.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.