I'm trying to use V8 in my project. I've built it as a static library and now in the out.gn/x64.release/obj
folder I have quite many .lib
files. Based on this parameters list to g++
:
--start-group \
out.gn/x64.release/obj/{libv8_{base,libbase,external_snapshot,libplatform,libsampler},\
third_party/icu/libicu{uc,i18n},src/inspector/libinspector}.a \
-Wl,--end-group
I've undefined and linked the following libraries in v8.cpp
file:
#pragma comment(lib, "v8_base.lib")
#pragma comment(lib, "v8_libbase")
#pragma comment(lib, "v8_external_snapshot")
#pragma comment(lib, "v8_libplatform")
#pragma comment(lib, "v8_libsampler")
#pragma comment(lib, "icuuc.lib")
#pragma comment(lib, "icui18n.lib")
#pragma comment(lib, "inspector")
But now I get many linker errors:
1>------ Build started: Project: v8, Configuration: Release x64 ------
1>v8_libbase.lib(platform-win32.obj) : error LNK2001: unresolved external symbol __imp_timeGetTime
1>v8_libbase.lib(time.obj) : error LNK2001: unresolved external symbol __imp_timeGetTime
1>v8_libbase.lib(stack_trace_win.obj) : error LNK2001: unresolved external symbol __imp_StackWalk64
1>v8_libbase.lib(stack_trace_win.obj) : error LNK2001: unresolved external symbol __imp_SymSetOptions
...
1>C:\...\Documents\Visual Studio 2015\Projects\v8\x64\Release\v8.exe : fatal error LNK1120: 11 unresolved externals
I've read here that
If you are manually adding the *.lib files to your link dependencies, then you are also responsible for linking against any DLLs they depend on
So my question is how to identify these DLL's and how to link them? I'm using Visual Studio 2015.