Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to build rusty_v8 with old v8 version? #1340

Open
raefko opened this issue Oct 3, 2023 · 1 comment
Open

How to build rusty_v8 with old v8 version? #1340

raefko opened this issue Oct 3, 2023 · 1 comment

Comments

@raefko
Copy link

raefko commented Oct 3, 2023

Hello all!
I am trying to build rusty_v8 (https://github.com/denoland/rusty_v8) with an old version of v8.
I saw that there is an env var RUSTY_V8_ARCHIVE, so i tried to build v8 from the official repository as a static library.
I tried using this
target_os = "linux"
is_debug = false
target_cpu = "x64"
use_custom_libcxx = false
clang_use_chrome_plugins = false
is_component_build = false
is_clang = true
v8_static_library = true
v8_use_external_startup_data = false
v8_enable_test_features = false
v8_enable_i18n_support = false
treat_warnings_as_errors = false

I'm getting multiple .a and I don't know which one to use, but trying with libv8_libbase.a throw me this error
error: failed to build archive: 'v8_libbase/bits.o': No such file or directory

Can you please help me compile v8 as a static library to use it with rusty_v8?
Thanks!

@raefko raefko changed the title How to build rusty_v8 with old v8 version? Rust Crate Usage FFI / Native Code 3 octobre 2023 How to build rusty_v8 with old v8 version? Oct 3, 2023
@bartlomieju
Copy link
Member

You'd have to fork rusty_v8 and update various files required to build V8 with a specific version (all these directories like build/ and buildtools/ are tied to a specific version of V8) and then you'd have to update src/binding.cc and relevant Rust files to match what's in src/binding.cc. You might have a better luck trying to check out one of the older versions of rusty_v8 that uses the V8 version you need.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants