Skip to content

Commit 6d6c8c1

Browse files
authored
Use workspace cargo (#381)
1 parent 8dcf64e commit 6d6c8c1

File tree

3 files changed

+23
-9
lines changed

3 files changed

+23
-9
lines changed

Cargo.toml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,11 @@
11
[workspace]
22
members = ["mozjs", "rust-mozjs"]
3+
4+
[workspace.package]
5+
repository = "https://github.com/servo/mozjs/"
6+
license = "MPL-2.0"
7+
edition = "2015"
8+
9+
[workspace.dependencies]
10+
cc = "1"
11+
libc = "0.2"

mozjs/Cargo.toml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,20 @@
11
[package]
22
name = "mozjs_sys"
33
description = "System crate for the Mozilla SpiderMonkey JavaScript engine."
4-
repository = "https://github.com/servo/mozjs/"
4+
repository.workspace = true
55
version = "0.68.2"
66
authors = ["Mozilla"]
77
links = "mozjs"
88
build = "build.rs"
9-
license = "MPL-2.0"
9+
license.workspace = true
1010
exclude = [
1111
"mozjs/js/src/tests/**",
1212
"mozjs/js/src/octane/**",
1313
"mozjs/js/src/jit-test/**",
1414
"mozjs/js/src/jsapi-tests/**",
1515
"mozjs/js/src/doc/**",
1616
]
17+
edition.workspace = true
1718

1819
[features]
1920
debugmozjs = []
@@ -30,10 +31,13 @@ doctest = false
3031
[dependencies]
3132
encoding_c = "0.9.6"
3233
encoding_c_mem = "0.2.5"
33-
libc = "0.2"
34+
libc.workspace = true
3435
libz-sys = "1.0"
3536

3637
[build-dependencies]
37-
bindgen = { version = "0.62", default-features = false, features = ["runtime", "which-rustfmt"] }
38-
cc = "1.0"
38+
bindgen = { version = "0.62", default-features = false, features = [
39+
"runtime",
40+
"which-rustfmt",
41+
] }
42+
cc.workspace = true
3943
walkdir = "2"

rust-mozjs/Cargo.toml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
[package]
22
name = "mozjs"
33
description = "Rust bindings to the Mozilla SpiderMonkey JavaScript engine."
4-
repository = "https://github.com/servo/mozjs"
4+
repository.workspace = true
55
version = "0.14.1"
66
authors = ["The Servo Project Developers"]
77
build = "build.rs"
8-
license = "MPL-2.0"
8+
license.workspace = true
9+
edition.workspace = true
910

1011
[build-dependencies]
11-
cc = "1"
12+
cc.workspace = true
1213

1314
[[example]]
1415
name = "minimal"
@@ -59,7 +60,7 @@ uwp = ['mozjs_sys/uwp']
5960

6061
[dependencies]
6162
lazy_static = "1"
62-
libc = "0.2"
63+
libc.workspace = true
6364
log = "0.4"
6465
num-traits = "0.2"
6566
mozjs_sys = { path = "../mozjs" }

0 commit comments

Comments
 (0)