Skip to content

Commit 2729864

Browse files
author
bors-servo
committed
Auto merge of #10857 - servo:toml, r=nox
Simplify TOML syntax * Sections like `[dependencies.foo]` can be entries in a `[dependencies]` section with the `{key = value}` syntax. * Per-target dependencies can be expressed with more general `cfg(…)` conditions instead of exact target triples: rust-lang/cargo#2328 <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/10857) <!-- Reviewable:end -->
2 parents caba731 + 83b3ebf commit 2729864

File tree

36 files changed

+288
-901
lines changed

36 files changed

+288
-901
lines changed

components/canvas/Cargo.toml

Lines changed: 7 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -8,29 +8,14 @@ publish = false
88
name = "canvas"
99
path = "lib.rs"
1010

11-
[dependencies.azure]
12-
git = "https://github.com/servo/rust-azure"
13-
features = ["plugins"]
14-
15-
[dependencies.canvas_traits]
16-
path = "../canvas_traits"
17-
18-
[dependencies.plugins]
19-
path = "../plugins"
20-
21-
[dependencies.util]
22-
path = "../util"
23-
24-
[dependencies.gfx_traits]
25-
path = "../gfx_traits"
26-
27-
[dependencies.ipc-channel]
28-
git = "https://github.com/servo/ipc-channel"
29-
30-
[dependencies.webrender_traits]
31-
git = "https://github.com/servo/webrender_traits"
32-
3311
[dependencies]
12+
azure = {git = "https://github.com/servo/rust-azure", features = ["plugins"]}
13+
canvas_traits = {path = "../canvas_traits"}
14+
plugins = {path = "../plugins"}
15+
util = {path = "../util"}
16+
gfx_traits = {path = "../gfx_traits"}
17+
ipc-channel = {git = "https://github.com/servo/ipc-channel"}
18+
webrender_traits = {git = "https://github.com/servo/webrender_traits"}
3419
euclid = {version = "0.6.4", features = ["plugins"]}
3520
gleam = "0.2.8"
3621
log = "0.3.5"

components/canvas_traits/Cargo.toml

Lines changed: 6 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -8,27 +8,13 @@ publish = false
88
name = "canvas_traits"
99
path = "lib.rs"
1010

11-
[dependencies.gfx_traits]
12-
path = "../gfx_traits"
13-
14-
[dependencies.azure]
15-
git = "https://github.com/servo/rust-azure"
16-
features = ["plugins"]
17-
18-
[dependencies.ipc-channel]
19-
git = "https://github.com/servo/ipc-channel"
20-
21-
[dependencies.serde]
22-
version = "0.7"
23-
features = [ "nightly" ]
24-
25-
[dependencies.plugins]
26-
path = "../plugins"
27-
28-
[dependencies.webrender_traits]
29-
git = "https://github.com/servo/webrender_traits"
30-
3111
[dependencies]
12+
gfx_traits = {path = "../gfx_traits"}
13+
azure = {git = "https://github.com/servo/rust-azure", features = ["plugins"]}
14+
ipc-channel = {git = "https://github.com/servo/ipc-channel"}
15+
serde = {version = "0.7", features = [ "nightly" ]}
16+
plugins = {path = "../plugins"}
17+
webrender_traits = {git = "https://github.com/servo/webrender_traits"}
3218
cssparser = {version = "0.5.4", features = ["heap_size", "serde-serialization"]}
3319
euclid = {version = "0.6.4", features = ["plugins"]}
3420
heapsize = "0.3.0"

components/compositing/Cargo.toml

Lines changed: 22 additions & 77 deletions
Original file line numberDiff line numberDiff line change
@@ -8,84 +8,26 @@ publish = false
88
name = "compositing"
99
path = "lib.rs"
1010

11-
[dependencies.gfx]
12-
path = "../gfx"
13-
14-
[dependencies.gfx_traits]
15-
path = "../gfx_traits"
16-
17-
[dependencies.layout_traits]
18-
path = "../layout_traits"
19-
20-
[dependencies.script_traits]
21-
path = "../script_traits"
22-
23-
[dependencies.style_traits]
24-
path = "../style_traits"
25-
26-
[dependencies.msg]
27-
path = "../msg"
28-
29-
[dependencies.profile_traits]
30-
path = "../profile_traits"
31-
32-
[dependencies.net_traits]
33-
path = "../net_traits"
34-
35-
[dependencies.util]
36-
path = "../util"
37-
38-
[dependencies.devtools_traits]
39-
path = "../devtools_traits"
40-
41-
[dependencies.canvas_traits]
42-
path = "../canvas_traits"
43-
44-
[dependencies.canvas]
45-
path = "../canvas"
46-
47-
[dependencies.plugins]
48-
path = "../plugins"
49-
50-
[dependencies.azure]
51-
git = "https://github.com/servo/rust-azure"
52-
features = ["plugins"]
53-
54-
[dependencies.layers]
55-
git = "https://github.com/servo/rust-layers"
56-
features = ["plugins"]
57-
58-
[dependencies.clipboard]
59-
git = "https://github.com/aweinstock314/rust-clipboard"
60-
61-
[dependencies.ipc-channel]
62-
git = "https://github.com/servo/ipc-channel"
63-
64-
[target.arm-linux-androideabi.dependencies.gaol]
65-
git = "https://github.com/servo/gaol"
66-
67-
[target.x86_64-apple-darwin.dependencies.gaol]
68-
git = "https://github.com/servo/gaol"
69-
70-
[target.x86_64-unknown-linux-gnu.dependencies.gaol]
71-
git = "https://github.com/servo/gaol"
72-
73-
[target.i686-unknown-linux-gnu.dependencies.gaol]
74-
git = "https://github.com/servo/gaol"
75-
76-
[target.arm-unknown-linux-gnueabihf.dependencies.gaol]
77-
git = "https://github.com/servo/gaol"
78-
79-
[target.aarch64-unknown-linux-gnu.dependencies.gaol]
80-
git = "https://github.com/servo/gaol"
81-
82-
[dependencies.webrender_traits]
83-
git = "https://github.com/servo/webrender_traits"
84-
85-
[dependencies.webrender]
86-
git = "https://github.com/servo/webrender"
87-
8811
[dependencies]
12+
gfx = {path = "../gfx"}
13+
gfx_traits = {path = "../gfx_traits"}
14+
layout_traits = {path = "../layout_traits"}
15+
script_traits = {path = "../script_traits"}
16+
style_traits = {path = "../style_traits"}
17+
msg = {path = "../msg"}
18+
profile_traits = {path = "../profile_traits"}
19+
net_traits = {path = "../net_traits"}
20+
util = {path = "../util"}
21+
devtools_traits = {path = "../devtools_traits"}
22+
canvas_traits = {path = "../canvas_traits"}
23+
canvas = {path = "../canvas"}
24+
plugins = {path = "../plugins"}
25+
azure = {git = "https://github.com/servo/rust-azure", features = ["plugins"]}
26+
layers = {git = "https://github.com/servo/rust-layers", features = ["plugins"]}
27+
clipboard = {git = "https://github.com/aweinstock314/rust-clipboard"}
28+
ipc-channel = {git = "https://github.com/servo/ipc-channel"}
29+
webrender_traits = {git = "https://github.com/servo/webrender_traits"}
30+
webrender = {git = "https://github.com/servo/webrender"}
8931
app_units = {version = "0.2.3", features = ["plugins"]}
9032
euclid = {version = "0.6.4", features = ["plugins"]}
9133
gleam = "0.2.8"
@@ -98,3 +40,6 @@ serde = "0.7"
9840
serde_macros = "0.7"
9941
time = "0.1.17"
10042
url = {version = "1.0.0", features = ["heap_size"]}
43+
44+
[target.'cfg(not(target_os = "windows"))'.dependencies]
45+
gaol = {git = "https://github.com/servo/gaol"}

components/devtools/Cargo.toml

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -8,22 +8,12 @@ publish = false
88
name = "devtools"
99
path = "lib.rs"
1010

11-
[dependencies.devtools_traits]
12-
path = "../devtools_traits"
13-
14-
[dependencies.msg]
15-
path = "../msg"
16-
17-
[dependencies.util]
18-
path = "../util"
19-
20-
[dependencies.plugins]
21-
path = "../plugins"
22-
23-
[dependencies.ipc-channel]
24-
git = "https://github.com/servo/ipc-channel"
25-
2611
[dependencies]
12+
devtools_traits = {path = "../devtools_traits"}
13+
msg = {path = "../msg"}
14+
util = {path = "../util"}
15+
plugins = {path = "../plugins"}
16+
ipc-channel = {git = "https://github.com/servo/ipc-channel"}
2717
hyper = { version = "0.9", features = [ "serde-serialization" ] }
2818
serde = "0.7"
2919
serde_json = "0.7"

components/devtools_traits/Cargo.toml

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,10 @@ publish = false
88
name = "devtools_traits"
99
path = "lib.rs"
1010

11-
[dependencies.msg]
12-
path = "../msg"
13-
14-
[dependencies.ipc-channel]
15-
git = "https://github.com/servo/ipc-channel"
16-
17-
[dependencies.plugins]
18-
path = "../plugins"
19-
2011
[dependencies]
12+
msg = {path = "../msg"}
13+
ipc-channel = {git = "https://github.com/servo/ipc-channel"}
14+
plugins = {path = "../plugins"}
2115
heapsize = "0.3.0"
2216
heapsize_plugin = "0.1.2"
2317
hyper = { version = "0.9", features = [ "serde-serialization" ] }
@@ -26,4 +20,3 @@ bitflags = "0.3"
2620
serde = "0.7"
2721
serde_macros = "0.7"
2822
url = {version = "1.0.0", features = ["heap_size"]}
29-

components/gfx/Cargo.toml

Lines changed: 19 additions & 91 deletions
Original file line numberDiff line numberDiff line change
@@ -31,100 +31,28 @@ string_cache = {version = "0.2.12", features = ["heap_size"]}
3131
time = "0.1.12"
3232
unicode-script = { version = "0.1", features = ["harfbuzz"] }
3333
url = {version = "1.0.0", features = ["heap_size"]}
34-
35-
[dependencies.plugins]
36-
path = "../plugins"
37-
38-
[dependencies.gfx_traits]
39-
path = "../gfx_traits"
40-
41-
[dependencies.net_traits]
42-
path = "../net_traits"
43-
44-
[dependencies.util]
45-
path = "../util"
46-
47-
[dependencies.msg]
48-
path = "../msg"
49-
50-
[dependencies.profile_traits]
51-
path = "../profile_traits"
52-
53-
[dependencies.range]
54-
path = "../range"
55-
56-
[dependencies.style]
57-
path = "../style"
58-
59-
[dependencies.style_traits]
60-
path = "../style_traits"
61-
62-
[dependencies.azure]
63-
git = "https://github.com/servo/rust-azure"
64-
features = ["plugins"]
65-
66-
[dependencies.layers]
67-
git = "https://github.com/servo/rust-layers"
68-
features = ["plugins"]
69-
70-
[dependencies.ipc-channel]
71-
git = "https://github.com/servo/ipc-channel"
72-
73-
[dependencies.webrender_traits]
74-
git = "https://github.com/servo/webrender_traits"
75-
76-
[target.x86_64-apple-darwin.dependencies]
34+
plugins = {path = "../plugins"}
35+
gfx_traits = {path = "../gfx_traits"}
36+
net_traits = {path = "../net_traits"}
37+
util = {path = "../util"}
38+
msg = {path = "../msg"}
39+
profile_traits = {path = "../profile_traits"}
40+
range = {path = "../range"}
41+
style = {path = "../style"}
42+
style_traits = {path = "../style_traits"}
43+
azure = {git = "https://github.com/servo/rust-azure", features = ["plugins"]}
44+
layers = {git = "https://github.com/servo/rust-layers", features = ["plugins"]}
45+
ipc-channel = {git = "https://github.com/servo/ipc-channel"}
46+
webrender_traits = {git = "https://github.com/servo/webrender_traits"}
47+
48+
[target.'cfg(target_os = "macos")'.dependencies]
7749
core-foundation = "0.2"
7850
core-graphics = "0.3"
7951
core-text = "1.1"
8052

81-
[target.i686-unknown-linux-gnu.dependencies]
82-
servo-fontconfig = "0.2"
83-
84-
[target.x86_64-unknown-linux-gnu.dependencies]
85-
servo-fontconfig = "0.2"
86-
87-
[target.arm-unknown-linux-gnueabihf.dependencies]
88-
servo-fontconfig = "0.2"
89-
90-
[target.aarch64-unknown-linux-gnu.dependencies]
91-
servo-fontconfig = "0.2"
92-
93-
[target.arm-linux-androideabi.dependencies]
53+
[target.'cfg(any(target_os = "linux", target_os = "android", target_os = "windows"))'.dependencies]
9454
servo-fontconfig = "0.2"
55+
freetype = {git = "https://github.com/servo/rust-freetype"}
9556

96-
[target.x86_64-pc-windows-gnu.dependencies]
97-
servo-fontconfig = "0.2"
98-
99-
[target.i686-unknown-linux-gnu.dependencies.freetype]
100-
git = "https://github.com/servo/rust-freetype"
101-
102-
[target.x86_64-unknown-linux-gnu.dependencies.freetype]
103-
git = "https://github.com/servo/rust-freetype"
104-
105-
[target.arm-unknown-linux-gnueabihf.dependencies.freetype]
106-
git = "https://github.com/servo/rust-freetype"
107-
108-
[target.aarch64-unknown-linux-gnu.dependencies.freetype]
109-
git = "https://github.com/servo/rust-freetype"
110-
111-
[target.arm-linux-androideabi.dependencies.freetype]
112-
git = "https://github.com/servo/rust-freetype"
113-
114-
[target.x86_64-pc-windows-gnu.dependencies.freetype]
115-
git = "https://github.com/servo/rust-freetype"
116-
117-
[target.x86_64-unknown-linux-gnu.dependencies.simd]
118-
git = "https://github.com/huonw/simd"
119-
120-
[target.x86_64-apple-darwin.dependencies.simd]
121-
git = "https://github.com/huonw/simd"
122-
123-
[target.aarch64-unknown-linux-gnu.dependencies.simd]
124-
git = "https://github.com/huonw/simd"
125-
126-
[target.x86_64-pc-windows-gnu.dependencies.simd]
127-
git = "https://github.com/huonw/simd"
128-
129-
[target.x86_64-pc-windows-msvc.dependencies.simd]
130-
git = "https://github.com/huonw/simd"
57+
[target.'cfg(any(target_arch = "x86_64", target_arch = "aarch64"))'.dependencies]
58+
simd = {git = "https://github.com/huonw/simd"}

components/gfx_traits/Cargo.toml

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,21 +8,11 @@ publish = false
88
name = "gfx_traits"
99
path = "lib.rs"
1010

11-
[dependencies.azure]
12-
git = "https://github.com/servo/rust-azure"
13-
features = ["plugins"]
14-
15-
[dependencies.layers]
16-
git = "https://github.com/servo/rust-layers"
17-
features = ["plugins"]
18-
19-
[dependencies.msg]
20-
path = "../msg"
21-
22-
[dependencies.plugins]
23-
path = "../plugins"
24-
2511
[dependencies]
12+
azure = {git = "https://github.com/servo/rust-azure", features = ["plugins"]}
13+
layers = {git = "https://github.com/servo/rust-layers", features = ["plugins"]}
14+
msg = {path = "../msg"}
15+
plugins = {path = "../plugins"}
2616
euclid = {version = "0.6.5", features = ["plugins"]}
2717
heapsize = "0.3.0"
2818
heapsize_plugin = "0.1.2"

0 commit comments

Comments
 (0)