Repository navigation
Expand file tree
/
Copy pathCargo.toml
More file actions
223 lines (214 loc) · 11.8 KB
/
Copy pathCargo.toml
File metadata and controls
223 lines (214 loc) · 11.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
[workspace]
resolver = "3"
# The tree's crates, its applications, and the **build tool** that checks
# it. The xtask is an ordinary member and not a script: `cargo test -p
# xtask` runs its own tests, `cargo clippy --workspace` covers it, and the
# layering gate sees it.
members = ["crates/*", "apps/*", "xtask"]
[workspace.package]
version = "0.2.0"
edition = "2024"
# The lowest toolchain this workspace is actually verified against: `stable`
# as of the first full green `cargo xtask ci`, with every test passing. Not
# a guess and not a wish — `cargo xtask doctor` compares it against the
# toolchain you are actually using and tells you when they disagree.
rust-version = "1.93"
license = "MIT OR Apache-2.0"
# Where the code actually is. A package's `repository` field is where a
# reader is sent, so it has to be a place that answers.
repository = "https://github.com/CipherOcto/craftkit"
authors = ["craftkit contributors"]
[workspace.dependencies]
# The SDK is the only thing a plugin depends on.
craftkit-sdk = { path = "crates/craftkit-sdk", version = "0.2.0" }
craftkit-derive = { path = "crates/craftkit-derive", version = "0.2.0" }
# The geometry: a **library**, not a plugin. It contributes nothing to the
# registry and the linker does not wire it in.
craftkit-vector-geom = { path = "crates/craftkit-vector-geom", version = "0.2.0" }
# The time model of the sound battery — and of the CLAP battery, whose
# transport is worked out with it: a **library**, not a plugin. It
# contributes nothing to the registry and the linker does not wire it
# in.
craftkit-sound-time = { path = "crates/craftkit-sound-time", version = "0.2.0" }
# The **payload reader**: a bounded reader for the values a document
# carries. A **library**, not a plugin — the core bounds a command's
# parameters and says nothing about a payload, so the reading of one is
# a plugin's business and the mechanism is shared.
craftkit-payload = { path = "crates/craftkit-payload", version = "0.2.0" }
# The line breaker: the box/glue/penalty model, and the two breakers. A
# **library**, not a plugin. It contributes nothing to the registry and
# the linker does not wire it in.
craftkit-text-layout = { path = "crates/craftkit-text-layout", version = "0.2.0" }
# The kit's own typeface: glyphs as strokes, drawn in code. A
# **library**, not a plugin. It contributes nothing to the registry and
# the linker does not wire it in.
craftkit-font = { path = "crates/craftkit-font", version = "0.2.0" }
# The **WAV reader**: the samples of a sound, from the file. A
# **library**, not a plugin: it contributes nothing to the registry and
# the linker does not wire it in.
craftkit-wav = { path = "crates/craftkit-wav", version = "0.2.0" }
# The **mixer**: the samples of many tracks, summed into one. A
# **library**, not a plugin: it contributes nothing to the registry and
# the linker does not wire it in.
craftkit-audio = { path = "crates/craftkit-audio", version = "0.2.0" }
# The **MIDI library**: the notes, the controllers and the Standard
# MIDI File. A **library**, not a plugin: it contributes nothing to the
# registry and the linker does not wire it in.
craftkit-midi = { path = "crates/craftkit-midi", version = "0.2.0" }
# The kit's own **audio plugins**: a catalogue of small programs that
# change a signal. A **library**, not a plugin: it contributes nothing
# to the registry and the linker does not wire it in.
craftkit-plugins = { path = "crates/craftkit-plugins", version = "0.2.0" }
# The MCP door: the registry, spoken to an agent. One tool per command.
craftkit-mcp = { path = "crates/craftkit-mcp", version = "0.2.0" }
# The **PNG reader**: the pixels of a picture, and the inflate they come
# in. A **library**, not a plugin: it contributes nothing to the registry
# and the linker does not wire it in.
craftkit-png = { path = "crates/craftkit-png", version = "0.2.0" }
# The **inflate**: DEFLATE, from RFC 1951. A **library**, not a plugin:
# it contributes nothing to the registry and the linker does not wire it
# in. The picture reader, a package reader and a PDF filter all want the
# same thing, and they want it from one place.
craftkit-deflate = { path = "crates/craftkit-deflate", version = "0.2.0" }
# The **package reader**: a ZIP archive, read. A **library**, not a
# plugin: it contributes nothing to the registry and the linker does
# not wire it in.
craftkit-zip = { path = "crates/craftkit-zip", version = "0.2.0" }
# The **XML reader**: a part of a file, read as elements. A **library**,
# not a plugin: it contributes nothing to the registry and the linker
# does not wire it in.
craftkit-xml = { path = "crates/craftkit-xml", version = "0.2.0" }
# The **workbook reader**: an XLSX file, read as a workbook. A
# **library**, not a plugin: it contributes nothing to the registry and
# the linker does not wire it in.
craftkit-xlsx = { path = "crates/craftkit-xlsx", version = "0.2.0" }
# The **PDF writer**: a file written as a PDF. A **library**, not a
# plugin: it contributes nothing to the registry and the linker does
# not wire it in.
craftkit-pdf-writer = { path = "crates/craftkit-pdf-writer", version = "0.2.0" }
# The **JPEG decoder**: the family's own, clean-room from ITU-T T.81. A
# **library**, not a plugin: it contributes nothing to the registry and
# the linker does not wire it in.
craftkit-jpeg = { path = "crates/craftkit-jpeg", version = "0.2.0" }
# The **scratch**: the file or the directory a test works in, taken back
# when the thread that asked for it ends. A **dev** dependency of the
# crates whose tests use it, and nothing that ships links it.
craftkit-scratch = { path = "crates/craftkit-scratch", version = "0.2.0" }
# The **picture's size**: read from a picture's header. A **library**,
# not a plugin: it contributes nothing to the registry and the linker
# does not wire it in.
craftkit-image = { path = "crates/craftkit-image", version = "0.2.0" }
# The **image battery**: a picture is a size and a file. It is optional,
# like the others.
craftkit-plugin-image = { path = "crates/craftkit-plugin-image", version = "0.2.0" }
# The **rasteriser**: a canvas that draws a document into a picture. A
# **library**, not a plugin: it contributes nothing to the registry and
# the linker does not wire it in.
craftkit-control = { path = "crates/craftkit-control", version = "0.2.0" }
# The **VST3 ABI**: the shapes a VST3 plugin is made of. A crate of
# data, with no `unsafe` in it at all.
craftkit-vst3-abi = { path = "crates/craftkit-vst3-abi", version = "0.2.0" }
# The **AU ABI**: the shapes an Audio Unit is made of. A crate of data,
# with no `unsafe` in it at all.
craftkit-au-abi = { path = "crates/craftkit-au-abi", version = "0.2.0" }
# The **AU host**: the door that opens a unit and drives it. A
# **library**, not a plugin: it contributes nothing to the registry and
# the linker does not wire it in.
craftkit-au = { path = "crates/craftkit-au", version = "0.2.0" }
# A **reference AU**: a shared library that exports the symbols the host
# looks for. It is a fixture, and it is here because a host that has
# never opened a real unit has not been tested.
craftkit-au-fixture = { path = "crates/craftkit-au-fixture", version = "0.2.0" }
# The **VST3 host**: the door that opens a VST3 plugin and drives the
# component inside it. A **library**, not a plugin: it contributes
# nothing to the registry and the linker does not wire it in.
craftkit-vst3 = { path = "crates/craftkit-vst3", version = "0.2.0" }
# The **VST3 battery**: the document model of a VST3 plugin — an
# identity, a parameter list and a state. A plugin, and not a library.
craftkit-plugin-vst3 = { path = "crates/craftkit-plugin-vst3", version = "0.2.0" }
# A **reference VST3 plugin**: a shared library that exports the entry
# the host looks for. It is a fixture, and it is here because a host
# that has never opened a real plugin has not been tested.
craftkit-vst3-fixture = { path = "crates/craftkit-vst3-fixture", version = "0.2.0" }
craftkit-raster = { path = "crates/craftkit-raster", version = "0.2.0" }
# The **terminal door**: a person drives the kit from a prompt. It is an
# **application**, and it depends on everything.
craftkit-repl = { path = "apps/craftkit-repl", version = "0.2.0" }
# The **typed value**: a length in millimetres and an angle in radians. A
# **library**, not a plugin. It contributes nothing to the registry and
# the linker does not wire it in.
craftkit-numeric = { path = "crates/craftkit-numeric", version = "0.2.0" }
# The **door**: opening a shared library and calling the plugin table in
# it. A crate with the second of v2's three allowed exceptions.
craftkit-ffi = { path = "crates/craftkit-ffi", version = "0.2.0" }
# The **contract** the door and the plugin agree on. No dependencies.
craftkit-ffi-abi = { path = "crates/craftkit-ffi-abi", version = "0.2.0" }
# The **CLAP ABI**: the shapes a CLAP plugin is made of. No dependencies:
# a binary contract is a set of shapes, and a set of shapes is data.
craftkit-clap-abi = { path = "crates/craftkit-clap-abi", version = "0.2.0" }
# The **CLAP host**: the door that opens a CLAP plugin and asks it what
# it holds. A **library**, not a plugin: it contributes nothing to the
# registry and the linker does not wire it in.
craftkit-clap = { path = "crates/craftkit-clap", version = "0.2.0" }
serde = { version = "1", features = ["derive"] }
serde_json = "1"
inventory = "0.3"
# The **toolkit** the window is drawn with, and the window itself. They
# are **libraries**, not plugins: they contribute no command and no
# kind, and the linker does not wire them in.
egui = "0.33"
eframe = { version = "0.33", default-features = false, features = [
"default_fonts",
"glow",
"wayland",
"x11",
] }
# The geometry the batteries' path operations use. Both are permissively
# licensed and both are dependencies, not copied code: `kurbo` is the bezier
# library and `linesweeper` is a robust sweep-line boolean operation.
kurbo = "0.13"
linesweeper = "0.5"
syn = { version = "2", features = ["full", "extra-traits"] }
quote = "1"
proc-macro2 = "1"
proc-macro-crate = "3"
[workspace.lints.rust]
# **Deny**, not forbid: a crate that exports a symbol the platform looks up
# **by name** cannot avoid an unsafe attribute (`#[unsafe(no_mangle)]`), and
# `forbid` cannot be relaxed by an `allow`. Every crate root carries
# `#![forbid(unsafe_code)]` — the house rule, checked by `cargo xtask lists` —
# so this is the backstop and not the rule. The one crate that may not forbid
# is the Android package, and it is named in the gate. §236.
unsafe_code = "deny"
# The house deny. Every production crate root repeats this with
# `#![deny(clippy::unwrap_used, ...)]`; `clippy.toml` relaxes it for tests.
# Kept here so a new crate that forgets the attribute still gets it.
[workspace.lints.clippy]
dbg_macro = "warn"
todo = "warn"
[profile.dev]
# The **working** profile: what a developer builds with, and — since §957 —
# what the gate builds with on a desk, so that the gate and the working
# build share **one** set of artefacts.
#
# `debug = "line-tables-only"` is the `ci` profile's setting, and it is here
# for the same reason it is there: a tree with a hundred test binaries keeps
# a copy of every one of them, and full debug info in each of them is the
# difference between one directory of artefacts and two. Line tables are
# kept, so a panic still says the file and the line.
opt-level = 1
debug = "line-tables-only"
# The `ci` profile exists so the test suite is fast without going to full
# release, and with debug assertions off (they are slow and, in a graphics
# context, sometimes wrong) but overflow checks on.
#
# **It is the build machine's profile, and only that.** A desk builds with
# `dev` — the profile the working build uses, in the same directory — so a
# desk keeps one copy of the tree's artefacts and not two. §957.
[profile.ci]
inherits = "dev"
opt-level = 1
debug = "line-tables-only"
debug-assertions = false
overflow-checks = true
incremental = true