summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXavier Claessens <xclaessens@netflix.com>2025-10-20 14:54:34 -0400
committerXavier Claessens <xclaesse@gmail.com>2025-10-22 15:43:06 -0400
commit1e8ae5811d56662f701ef03013c2da0607e8f491 (patch)
tree6ca2d3412f4595138b8f330ac7297d940dba05c1
parent0b8d33033b961d2094ec2e69e8201cd532e42934 (diff)
downloadmeson-1e8ae5811d56662f701ef03013c2da0607e8f491.tar.gz
cargo: The default executable is src/main.rs
https://doc.rust-lang.org/cargo/guide/project-layout.html
-rw-r--r--mesonbuild/cargo/manifest.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/cargo/manifest.py b/mesonbuild/cargo/manifest.py
index 7ee4b333c..304ae7526 100644
--- a/mesonbuild/cargo/manifest.py
+++ b/mesonbuild/cargo/manifest.py
@@ -365,7 +365,7 @@ class Binary(BuildTarget):
def from_raw(cls, raw: raw.BuildTarget, pkg: Package) -> Self:
name = raw["name"]
return _raw_to_dataclass(raw, cls, f'Binary entry {name}',
- path=DefaultValue(f'bin/{name}.rs'),
+ path=DefaultValue('src/main.rs'),
edition=DefaultValue(pkg.edition))