Error linking V8 on Debian: undefined reference to `v8::base::SysInfo::NumberOfProcessors()'
327 views
Skip to first unread message
Jack
unread,
Aug 11, 2016, 8:12:17 PM8/11/16
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to v8-users
When I try compiling my program on Debian using CMake I'm getting the following the error:
/home/jack/v8/out/native/obj.target/v8_libplatform/src/libplatform/default-platform.o: In function `v8::platform::CreateDefaultPlatform(int)': ../src/libplatform/default-platform.cc:(.text._ZN2v88platform21CreateDefaultPlatformEi+0xb5): undefined reference to `v8::base::SysInfo::NumberOfProcessors()' /home/jack/v8/out/native/obj.target/v8_libplatform/src/libplatform/default-platform.o: In function `v8::platform::DefaultPlatform::SetThreadPoolSize(int)': ../src/libplatform/default-platform.cc:(.text._ZN2v88platform15DefaultPlatform17SetThreadPoolSizeEi+0x1a): undefined reference to `v8::base::SysInfo::NumberOfProcessors()'
Have I built v8 wrong? My CMakeLists file is like this for V8: link_directories( ~/v8/out/native/obj.target/src ~/v8/out/native/obj.target/third_party/icu ) ... target_link_libraries(Main PUBLIC v8_base v8_libbase v8_external_snapshot v8_libplatform v8_libsampler icui18n icuuc rt dl pthread )
~/v8/out/native/obj.target/srcincludes the following: libv8_base.a libv8_external_snapshot.a libv8_libbase.a libv8_libplatform.a libv8_libsampler.a libv8_nosnapshot.a and ~/v8/out/native/obj.target/third_party/icu contains: libicui18n.a libicuuc.a
Jack
unread,
Aug 13, 2016, 12:32:22 PM8/13/16
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to v8-users
I rebuilt it using gn. I used gn args to uncomment is_component_build and this sucessfully generated libv8.so on build. I then linked that and the libv8_libplatform.a that was generated earlier like so: target_link_libraries(Main PUBLIC v8 v8_libplatform