Alaska
b2000620f4
cargo subprojects: don't assume each target has dependencies
...
Previously, creating a meson wrap with "method=cargo"
for https://github.com/sunfishcode/is-terminal would fail,
because its Cargo.toml contains a [target] section without
dependencies.
Instead, we now fall back to an empty list in case of no specified dependencies
(like everywhere else in "_convert_manifest")
1 year ago
Xavier Claessens
3af0632c3d
cargo: Use rust_abi and rust.proc_macro() instead of rust_crate_type
1 year ago
Xavier Claessens
dc329f0f04
interpreter: Add support for cargo subproject
1 year ago
Xavier Claessens
ea42d2d019
cargo: Fix '1.0.45' version conversion
...
The middle 0 was wrongly dropped.
1 year ago
Xavier Claessens
019a0c38c6
cargo: Support all crate library types
1 year ago
Xavier Claessens
d6bf48cd7e
cargo: Package description is optional
1 year ago
Xavier Claessens
3a16da39ad
cargo: Add support for rust_dependency_map
1 year ago
Xavier Claessens
3abe52133d
cargo: Use "-rs" suffix convention to lookup for Rust dependencies
1 year ago
Xavier Claessens
f752efdd88
cargo: interpreter: Reorganize functions order
...
Keep _create_foo() functions together and with a common signature.
That's cleaner especially since we are going to add more of them.
1 year ago
Xavier Claessens
05d5055d85
cargo: Remove unused function
1 year ago
Xavier Claessens
3334addbbd
cargo: Builder: Add dict support
1 year ago
Xavier Claessens
b5b952688f
cargo: builder: Remove all duplicated functions
...
Keep only the Builder class, there is no point in duplicating
everything.
1 year ago
Charles Brunet
5b29eff8ad
parser: simplify other node constructors
1 year ago
Charles Brunet
0f4891cdf4
parser: simplify Assignment and PlusAssignment nodes
1 year ago
Charles Brunet
02ff9553db
parser: add SymbolNode to preserve operators
1 year ago
Charles Brunet
306562b466
parser: use IdNode for function name and assignment name
1 year ago
Charles Brunet
5707d39017
parser: preserve number base
1 year ago
Eli Schwartz
0bb1647fd1
move various bits of type-checking only code to TYPE_CHECKING blocks
...
Mostly detected with flake8-type-checking. Also quote T.cast() first
arguments, since those are not affected by future annotations.
1 year ago
Dylan Baker
f02e26877d
cargo/interpreter: Implement an interpreter for Cargo TOML
...
This converts a Cargo TOML file into Meson AST
Co-Authored-By: Thibault Saunier <tsaunier@igalia.com>
2 years ago
Dylan Baker
4017dab484
cargo/cfg: Add a parser for the rust/cargo cfg() expressions
...
This uses a recursive descent parser + lexer to create an IR from cfg()
expressions, which it then converts into meson IR.
2 years ago
Dylan Baker
5e59e5a9e4
cargo/version: add a function to convert cargo versioning to meson
2 years ago
Dylan Baker
b01ae087f5
cargo: Add a builder module to the cargo package
...
This is a helper, currently only used by cargo. It could be moved later
if there are other users.
2 years ago
Dylan Baker
71325547aa
cargo/manifest: Add a file with type definitions of the cargo manifest format
...
Co-Authored-By: Thibault Saunier <tsaunier@igalia.com>
2 years ago