mirror of
https://github.com/ruby/ruby.git
synced 2025-08-15 13:39:04 +02:00

This commit allows building YJIT and ZJIT simultaneously, a "combo build". Previously, `./configure --enable-yjit --enable-zjit` failed. At runtime, though, only one of the two can be enabled at a time. Add a root Cargo workspace that contains both the yjit and zjit crate. The common Rust build integration mechanisms are factored out into defs/jit.mk. Combo YJIT+ZJIT dev builds are supported; if either JIT uses `--enable-*=dev`, both of them are built in dev mode. The combo build requires Cargo, but building one JIT at a time with only rustc in release build remains supported.
20 lines
655 B
TOML
20 lines
655 B
TOML
[package]
|
|
name = "zjit"
|
|
version = "0.0.1"
|
|
edition = "2024"
|
|
rust-version = "1.85.0" # Minimally supported rust version
|
|
publish = false # Don't publish to crates.io
|
|
|
|
[dependencies]
|
|
# No required dependencies to simplify build process. TODO: Link to yet to be
|
|
# written rationale. Optional For development and testing purposes
|
|
capstone = { version = "0.13.0", optional = true }
|
|
|
|
[dev-dependencies]
|
|
expect-test = "1.5.1"
|
|
|
|
# NOTE: Development builds select a set of these via configure.ac
|
|
# For debugging, `make V=1` shows exact cargo invocation.
|
|
[features]
|
|
# Support --yjit-dump-disasm and RubyVM::YJIT.disasm using libcapstone.
|
|
disasm = ["capstone"]
|