aboutsummaryrefslogtreecommitdiff
path: root/Cargo.example.toml
diff options
context:
space:
mode:
authorDario Nieuwenhuis <[email protected]>2021-03-29 21:46:51 +0200
committerDario Nieuwenhuis <[email protected]>2021-03-29 21:46:51 +0200
commit4371302da87f7fad4649c0ef4eade9432dc94529 (patch)
treed09f2b75e7e116e6e96f4233c16cca47efbc20b3 /Cargo.example.toml
parent02ae53e71ba034268d929bcbaa359200fcb34690 (diff)
Remove workspace Cargo.toml, add template
Diffstat (limited to 'Cargo.example.toml')
-rw-r--r--Cargo.example.toml75
1 files changed, 75 insertions, 0 deletions
diff --git a/Cargo.example.toml b/Cargo.example.toml
new file mode 100644
index 000000000..c946a460d
--- /dev/null
+++ b/Cargo.example.toml
@@ -0,0 +1,75 @@
1# This file is a template for a Cargo workspace for developer convenience.
2#
3# Since Cargo resolves all features for all crates in the workspace together,
4# it is not possible to have a workspace with all the crates together, since they
5# enable incompatible features. For example, nrf crates enable embassy-macros/nrf
6# and stm32 crates enable embassy-macros/stm32. embassy-macros doesn't support having
7# both of these features on at the same time, because it makes no sense.
8#
9# Instead, we provide this template so you can enable only the crates you're going to
10# work on. This makes eg rust-analyzer check-on-save and autocomplete work, but only
11# in these crates, without any feature conflict.
12#
13# Copy this file to `Cargo.toml` and uncomment one group of crates below.
14#
15# `/Cargo.toml` is already in .gitignore, so you don't commit it accidentally.
16
17[workspace]
18members = [
19 "embassy",
20 "embassy-traits",
21 "embassy-macros",
22 "embassy-extras",
23
24 # Uncomment ONLY ONE of the groups below.
25
26 # nRF
27 #"embassy-nrf",
28 #"embassy-nrf-examples",
29
30 # stm32
31 #"embassy-stm32",
32 #"embassy-stm32f4",
33 #"embassy-stm32l0",
34 #"embassy-stm32f4-examples",
35
36 # rp2040
37 #"embassy-rp",
38 #"embassy-rp-examples",
39
40 # std
41 #"embassy-std",
42 #"embassy-std-examples",
43]
44
45[profile.dev]
46codegen-units = 1
47debug = 2
48debug-assertions = true
49incremental = false
50opt-level = 3
51overflow-checks = true
52
53[profile.release]
54codegen-units = 1
55debug = 2
56debug-assertions = false
57incremental = false
58lto = "fat"
59opt-level = 's'
60overflow-checks = false
61
62# do not optimize proc-macro crates = faster builds from scratch
63[profile.dev.build-override]
64codegen-units = 8
65debug = false
66debug-assertions = false
67opt-level = 0
68overflow-checks = false
69
70[profile.release.build-override]
71codegen-units = 8
72debug = false
73debug-assertions = false
74opt-level = 0
75overflow-checks = false