You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Linker error, while compiling node js from source (as a shared library) - v 6.11.2 #15195
I am trying to compile node js as a shared library from source on Windows.
Currently i am following vcbuild.bat - by passing "release" "x64" "dll" as arguments to the script.
Error (listing only one, but contains about 50+ all linker errors to v8_base_3.lib):
v8_base_3.lib(api.obj) : error LNK2005: "public: __cdecl v8::HandleScope::HandleScope(class v8::Isolate *)" (??0HandleScope@v8@@QEAA@PEAVIsolate@1@@Z) already defined in node.lib(node.dll) [D:\node-v6.11.2\cctest.vcxproj]
ghost changed the title [-]Compilation error, while compiling node js from source (as a shared library)[/-][+]Linker error, while compiling node js from source (as a shared library)[/+]on Sep 5, 2017
ghost changed the title [-]Linker error, while compiling node js from source (as a shared library)[/-][+]Linker error, while compiling node js from source (as a shared library) - v 6.11.2[/+]on Sep 5, 2017
you reinstall and install node.js in http://nodejs.org/download in linux
and write code
$ tar -zxf node-v0.12.4.tar.gz
$ cd node-v0.12.4
$ ./configure
$ make
$ sudo make install
and success
Reacted by Richard Lau, Tobias Nießen and Avaer Kazmer
@rao-krish this is an annoying but a non critical error. The build process tried to build the C++ test harness cctest only after it finishes building node.dll. I think if you look in /Release/ you'll find a completed node.dll.
Anyway we currently have no harness for testing node.dll, so the following steps of vcbuild.bat are irrelevant.
This could also might happen if by any chance you are reusing previous build products (from node@6.11.1 for example)...
Refs: #13078
Refs: #14158
@rao-krish I'm trying to reproduce locally. Meanwhile since the error you posted is already defined I have a strong intuition that the node.dll will work.
Activity
[-]Compilation error, while compiling node js from source (as a shared library)[/-][+]Linker error, while compiling node js from source (as a shared library)[/+][-]Linker error, while compiling node js from source (as a shared library)[/-][+]Linker error, while compiling node js from source (as a shared library) - v 6.11.2[/+]Mickey248 commentedon Sep 5, 2017
you reinstall and install node.js in http://nodejs.org/download in linux
and write code
$ tar -zxf node-v0.12.4.tar.gz
$ cd node-v0.12.4
$ ./configure
$ make
$ sudo make install
and success
bzoz commentedon Sep 6, 2017
@rao-krish sorry, I can't reproduce.
Could you provide more details? OS version, Visual Studio version, how did you obtain the code?
refack commentedon Sep 6, 2017
@rao-krish this is an annoying but a non critical error. The build process tried to build the C++ test harness
cctestonly after it finishes buildingnode.dll. I think if you look in/Release/you'll find a completednode.dll.Anyway we currently have no harness for testing
node.dll, so the following steps ofvcbuild.batare irrelevant.This could also might happen if by any chance you are reusing previous build products (from node@6.11.1 for example)...
Refs: #13078
Refs: #14158
bnoordhuis commentedon Sep 11, 2017
Looks like this has been answered and OP hasn't commented since. Closing, reopen if that is a mistake.
refack commentedon Sep 12, 2017
@rao-krish I'm trying to reproduce locally. Meanwhile since the error you posted is
already definedI have a strong intuition that thenode.dllwill work.But be aware that electron/atom float patches over "vanilla" node: electron/node@8d426bb...electron
refack commentedon Sep 12, 2017
@bzoz following the above steps reproduces
https://github.com/proxy/gist.github.com/refack/c28d94cc2ed0ee5d8408bb1aa68af35c
@rao-krish all the errors I'm seeing (~225) are
multiple definition, which IMHO hints that all needed symbols are exported bynode.dll