Skip to content

Backport cpal 0.18.2 to the 0.22 release line - #930

Merged
yara-blue merged 3 commits into
RustAudio:backport-cpal-0.18from
xronocode:898-backport-cpal-0.18
Oct 8, 2026
Merged

yara-blue merged 3 commits into
RustAudio:backport-cpal-0.18from
xronocode:898-backport-cpal-0.18

Conversation

@xronocode

@xronocode xronocode commented Oct 7, 2026 •

Copy link
Copy Markdown

As agreed in #898: a backport of cpal 0.18 to the 0.22 release line, targeting backport-cpal-0.18.

The first commit updates cpal to 0.18.2. The code changes are copied from master, commits 174ce9b (#866) and 049fbd3 (#875), and Cargo.lock is regenerated. In the migration code, the only difference from master is the requirement cpal = "0.18.2" instead of "0.18", because the CoreAudio build for visionOS was only fixed in 0.18.2, and visionOS is what this issue started with.

The second commit adds a changelog entry under Unreleased and a section in UPGRADE.md. I didn't touch the version or the other release steps, I'm leaving those to you.

The last commit is the one-line clippy 1.97 fix from #899, cherry-picked from master. The 0.22 release line predates it, and without it CI fails at the clippy step.

One thing to know: on this branch Microphone still ends on any stream error, including xruns, which cpal 0.18.2 now reports on more backends. I left that alone to keep this a straight copy of master. If you want, I can send a small separate fix.

Tested: the full command set from ci.yml on Rust 1.87 with -D warnings, plus clippy, rustfmt and the nightly docs build. cargo +nightly check -Zbuild-std=std,panic_abort --target aarch64-apple-visionos --lib fails on v0.22.2 and passes on this branch.

Manually on macOS (CoreAudio): playback and recording through Microphone work. A 440 Hz sine played through the BlackHole virtual device records back at the expected frequency and level, and the built-in microphone records too. I didn't test Linux or Windows on hardware.

Refs #898

xronocode and others added 3 commits October 7, 2026 17:24
Backport of the cpal 0.18 migration from master onto the 0.22
release line. The code changes are copied from master commits
174ce9b (RustAudio#866) and 049fbd3 (RustAudio#875). Cargo.lock is regenerated for
cpal 0.18.2.

The cpal requirement is 0.18.2 rather than master's 0.18, because
the visionOS CoreAudio build fix landed in 0.18.2.

Refs RustAudio#898
`clippy::question_mark` started flagging this in Rust 1.97, and CI runs clippy
from stable with `-D warnings`, so the check now fails on master.

(cherry picked from commit e1b6efe)

@yara-blue yara-blue left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

perfect thanks!

I'll cut a release soon. Please ping me if I fail to do so this weekend!

@yara-blue
yara-blue merged commit a79c440 into RustAudio:backport-cpal-0.18 Oct 8, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants