Build Issues

166 views
Skip to first unread message

Corey

unread,
Sep 21, 2011, 12:32:36 AM9/21/11
to v8-u...@googlegroups.com
Hey, so I'm coming back to an old project of mine that I'm starting up again, and I'm trying to build V8 from scratch on the r9343 revision, and I'm getting some errors when trying to build. I'm using Visual Studio 2010 on Windows 7 x64, building as x86 using the following:

C:\path\to\v8> "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\vcvarsall.bat" x86
C:\path\to\v8> scons mode=debug library=shared env="PATH:%PATH%,LIB:%LIB%,INCLUDE:%INCLUDE%"

All goes well until the linking phase, where I get these errors:

   Creating library v8preparser_g.lib and object v8preparser_g.exp
conversions.obj : error LNK2019: unresolved external symbol "void __cdecl v8::Re
gisterExtension(class v8::Extension *)" (?RegisterExtension@v8@@YAXPAVExtension@
1@@Z) referenced in function "public: __thiscall v8::DeclareExtension::DeclareEx
tension(class v8::Extension *)" (??0DeclareExtension@v8@@QAE@PAVExtension@1@@Z)
preparser.obj : error LNK2001: unresolved external symbol "void __cdecl v8::Regi
sterExtension(class v8::Extension *)" (?RegisterExtension@v8@@YAXPAVExtension@1@
@Z)
conversions.obj : error LNK2019: unresolved external symbol "public: void __this
call v8::Isolate::Enter(void)" (?Enter@Isolate@v8@@QAEXXZ) referenced in functio
n "public: __thiscall v8::Isolate::Scope::Scope(class v8::Isolate *)" (??0Scope@
Isolate@v8@@QAE@PAV12@@Z)
preparser.obj : error LNK2001: unresolved external symbol "public: void __thisca
ll v8::Isolate::Enter(void)" (?Enter@Isolate@v8@@QAEXXZ)
conversions.obj : error LNK2019: unresolved external symbol "public: void __this
call v8::Isolate::Exit(void)" (?Exit@Isolate@v8@@QAEXXZ) referenced in function
"public: __thiscall v8::Isolate::Scope::~Scope(void)" (??1Scope@Isolate@v8@@QAE@
XZ)
preparser.obj : error LNK2001: unresolved external symbol "public: void __thisca
ll v8::Isolate::Exit(void)" (?Exit@Isolate@v8@@QAEXXZ)
conversions.obj : error LNK2019: unresolved external symbol "public: virtual __t
hiscall v8::StartupDataDecompressor::~StartupDataDecompressor(void)" (??1Startup
DataDecompressor@v8@@UAE@XZ) referenced in function "public: virtual void * __th
iscall v8::StartupDataDecompressor::`scalar deleting destructor'(unsigned int)"
(??_GStartupDataDecompressor@v8@@UAEPAXI@Z)
preparser.obj : error LNK2001: unresolved external symbol "public: virtual __thi
scall v8::StartupDataDecompressor::~StartupDataDecompressor(void)" (??1StartupDa
taDecompressor@v8@@UAE@XZ)
conversions.obj : error LNK2019: unresolved external symbol "public: __thiscall
v8::Unlocker::Unlocker(class v8::Isolate *)" (??0Unlocker@v8@@QAE@PAVIsolate@1@@
Z) referenced in function "public: void __thiscall v8::Unlocker::`default constr
uctor closure'(void)" (??_FUnlocker@v8@@QAEXXZ)
preparser.obj : error LNK2001: unresolved external symbol "public: __thiscall v8
::Unlocker::Unlocker(class v8::Isolate *)" (??0Unlocker@v8@@QAE@PAVIsolate@1@@Z)

conversions.obj : error LNK2019: unresolved external symbol "public: __thiscall
v8::Locker::Locker(class v8::Isolate *)" (??0Locker@v8@@QAE@PAVIsolate@1@@Z) ref
erenced in function "public: void __thiscall v8::Locker::`default constructor cl
osure'(void)" (??_FLocker@v8@@QAEXXZ)
preparser.obj : error LNK2001: unresolved external symbol "public: __thiscall v8
::Locker::Locker(class v8::Isolate *)" (??0Locker@v8@@QAE@PAVIsolate@1@@Z)
conversions.obj : error LNK2019: unresolved external symbol "public: void __this
call v8::Template::Set(class v8::Handle<class v8::String>,class v8::Handle<class
 v8::Data>,enum v8::PropertyAttribute)" (?Set@Template@v8@@QAEXV?$Handle@VString
@v8@@@2@V?$Handle@VData@v8@@@2@W4PropertyAttribute@2@@Z) referenced in function
"public: void __thiscall v8::Template::Set(char const *,class v8::Handle<class v
8::Data>)" (?Set@Template@v8@@QAEXPBDV?$Handle@VData@v8@@@2@@Z)
preparser.obj : error LNK2001: unresolved external symbol "public: void __thisca
ll v8::Template::Set(class v8::Handle<class v8::String>,class v8::Handle<class v
8::Data>,enum v8::PropertyAttribute)" (?Set@Template@v8@@QAEXV?$Handle@VString@v
8@@@2@V?$Handle@VData@v8@@@2@W4PropertyAttribute@2@@Z)
conversions.obj : error LNK2019: unresolved external symbol "public: static clas
s v8::Local<class v8::String> __cdecl v8::String::New(char const *,int)" (?New@S
tring@v8@@SA?AV?$Local@VString@v8@@@2@PBDH@Z) referenced in function "public: vo
id __thiscall v8::Template::Set(char const *,class v8::Handle<class v8::Data>)"
(?Set@Template@v8@@QAEXPBDV?$Handle@VData@v8@@@2@@Z)
preparser.obj : error LNK2001: unresolved external symbol "public: static class
v8::Local<class v8::String> __cdecl v8::String::New(char const *,int)" (?New@Str
ing@v8@@SA?AV?$Local@VString@v8@@@2@PBDH@Z)
v8preparser_g.dll : fatal error LNK1120: 8 unresolved externals
scons: *** [v8preparser_g.dll] Error 1120
scons: building terminated because of errors.

I've looked through the compilation instructions for Windows several times, and haven't found anything to indicate why I would be getting this problem.

Yang Guo

unread,
Sep 28, 2011, 11:56:53 AM9/28/11
to v8-users
Hi Corey,

sorry for the late reply. The shared library build seems indeed to be
broken. However, it seems to work fine if you provide a target to
scons, for example the d8 shell:

scons mode=debug library=shared env="PATH:%PATH%,LIB:%LIB%,INCLUDE:
%INCLUDE%" d8

As the scons build is going to become deprecated in the medium term, I
would like to point you to the GYP build: http://code.google.com/p/v8/wiki/BuildingWithGYP

Regards,

Yang

Corey

unread,
Oct 2, 2011, 6:57:50 PM10/2/11
to v8-u...@googlegroups.com
Hm, well I'm trying to run the GYP install in cygwin, and I get this:

Corey@Corey-PC /cygdrive/c/Users/Corey/Documents/Dropbox/projects/v8
$ build/gyp_v8
Updating projects from gyp files...
      1 [main] python 4060 C:\cygwin\bin\python.exe: *** fatal error - unable to remap \\?\C:\cygwin\lib\python2.6\lib-dynload\_random.dll to same address as parent: 0x360000 != 0x3E0000
Stack trace:
Frame     Function  Args
002899E8  6102796B  (002899E8, 00000000, 00000000, 00000000)
00289CD8  6102796B  (6117EC60, 00008000, 00000000, 61180977)
0028AD08  61004F1B  (611A7FAC, 6124C97C, 00360000, 003E0000)
End of stack trace
      1 [main] python 5164 fork: child 4060 - died waiting for dll loading, errno 11
Traceback (most recent call last):
  File "build/gyp_v8", line 162, in <module>
    run_gyp(gyp_args)
  File "build/gyp_v8", line 107, in run_gyp
    rc = gyp.main(args)
  File "./build/gyp/pylib/gyp/__init__.py", line 463, in main
    options.circular_check)
  File "./build/gyp/pylib/gyp/__init__.py", line 69, in Load
    generator.CalculateVariables(default_variables, params)
  File "./build/gyp/pylib/gyp/generator/msvs.py", line 1609, in CalculateVariables
    generator_flags.get('msvs_version', 'auto'))
  File "./build/gyp/pylib/gyp/MSVSVersion.py", line 256, in SelectVisualStudioVersion
    versions = _DetectVisualStudioVersions()
  File "./build/gyp/pylib/gyp/MSVSVersion.py", line 213, in _DetectVisualStudioVersions
    if not _RegistryKeyExists(keys[index]):
  File "./build/gyp/pylib/gyp/MSVSVersion.py", line 136, in _RegistryKeyExists
    if not _RegistryQuery(key):
  File "./build/gyp/pylib/gyp/MSVSVersion.py", line 102, in _RegistryQuery
    text = _RegistryQueryBase('Sysnative', key, value)
  File "./build/gyp/pylib/gyp/MSVSVersion.py", line 74, in _RegistryQueryBase
    p = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
  File "/usr/lib/python2.6/subprocess.py", line 633, in __init__
    errread, errwrite)
  File "/usr/lib/python2.6/subprocess.py", line 1049, in _execute_child
    self.pid = os.fork()
OSError: [Errno 11] Resource temporarily unavailable

I'm sure my cygwin is missing some modules, I'm just not sure what.

Jakob Kummerow

unread,
Oct 4, 2011, 3:45:24 AM10/4/11
to v8-u...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages