1

Im trying to install PyV8 from source . I had downloaded v8 from svn and then exported v8 homepath and tried to do a setup.py install on the pyv8 folder . Im getting a host of errors below ...

INFO: Found Google v8 base on V8_HOME </media/DATA/thug-honey/v8>
running install
running bdist_egg
running egg_info
creating PyV8.egg-info
writing requirements to PyV8.egg-info/requires.txt
writing PyV8.egg-info/PKG-INFO
writing top-level names to PyV8.egg-info/top_level.txt
writing dependency_links to PyV8.egg-info/dependency_links.txt
writing manifest file 'PyV8.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'PyV8.egg-info/SOURCES.txt'
installing library code to build/bdist.linux-x86_64/egg
running install_lib
running build_py
running build_ext
building '_PyV8' extension
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DBOOST_PYTHON_STATIC_LIB -DV8_NATIVE_REGEXP -DENABLE_DEBUGGER_SUPPORT -DV8_TARGET_ARCH_X64 -I/media/DATA/thug-honey/v8/include -I/media/DATA/thug-honey/v8 -I/media/DATA/thug-honey/v8/src -I/usr/lib/python2.7/dist-packages/boost -I/usr/include/python2.7 -c src/Utils.cpp -o build/temp.linux-x86_64-2.7/src/Utils.o -Wno-write-strings -g -O3
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ [enabled by default]
In file included from src/Locker.h:3:0,
                 from src/Utils.cpp:11:
src/Exception.h: In constructor ‘CJavascriptStackTrace::CJavascriptStackTrace(v8::Isolate*, v8::Handle<v8::StackTrace>)’:
src/Exception.h:43:43: error: no matching function for call to ‘v8::Persistent<v8::StackTrace>::Persistent(v8::Isolate*&, v8::Handle<v8::StackTrace>&)’
     : m_isolate(isolate), m_st(isolate, st)
                                           ^

Can any body guide me to get pyv8 working

Or If i can find a debian package for PyV8

  • pip install also fails running build_ext building '_PyV8' extension creating build/temp.linux-i686-2.7 creating build/temp.linux-i686-2.7/src gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DBOOST_PYTHON_STATIC_LIB -Ilib/python/inc -Ilib/boost/inc -Ilib/v8/inc -I/usr/include/python2.7 -c src/Exception.cpp -o build/temp.linux-i686-2.7/src/Exception.occ1plus: warning: command line option "-Wstrict-prototypes" is valid for Ada/C/ObjC but not for C++ In file included from src/Exception.cpp:1: src/Exception.h:6:16: error: v8.h: No such file or directory – m3lhIN400Forty4 Sep 08 '14 at 09:45

1 Answers1

0

Since IMO PyV8 is not well maintained, it only really works with certain combinations of V8 builds and PyV8 builds. Beware of memory leaks as well, I needed to wrap it with some very specific cleanup code to get something stable. This approach is documented in the following issue:

https://code.google.com/p/pyv8/issues/detail?id=229&sort=-id

If I'd start over I would look into doing IPC between a node.js process and a python process to get the same functionality in a more stable and efficient manner.

  • Ok im open for any approach .. It will be helpful if you can give me some info on how can i integrate node.js with python .My only aim is to generate javascript and get the output which i can use it in python for other process Thanks in advance :D :D – m3lhIN400Forty4 Sep 09 '14 at 10:29