Skip to content

Upgrade to Glam 0.29.3 and Simplify Feature Gating #18638

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 31, 2025

Conversation

bushrat011899
Copy link
Contributor

Objective

Solution

  • Upgrade to Glam 0.29.3, which has backported the nostd-libm feature.
  • Expose a similar feature in bevy_math and enable it in bevy_internal, allowing bevy_math, bevy_input, and bevy_transform to be unconditional dependencies again.

Testing

  • CI

Notes

  • This includes libm as a dependency, but this was already the case in the common scenario where rand or many other features were enabled. Considering libm is an official Rust crate, it's a very low-risk dependency to unconditionally include.
  • For users who do not want libm included, simply import Bevy's subcrates directly, since bevy_math/nostd-libm will not be enabled.
  • I know we are very late in the RC cycle for 0.16, but this has a substantial impact on the usability of bevy that I consider worth including.

Use `nostd-libm` to always allow `bevy_math`, `bevy_input`, and `bevy_transform` in `bevy`.
@bushrat011899 bushrat011899 added this to the 0.16 milestone Mar 31, 2025
@bushrat011899 bushrat011899 added C-Dependencies A change to the crates that Bevy depends on A-Math Fundamental domain-agnostic mathematical operations X-Contentious There are nontrivial implications that should be thought through D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Needs-Review Needs reviewer attention (from anyone!) to move forward labels Mar 31, 2025
@alice-i-cecile
Copy link
Member

I think this is really essential to reducing the pain for crate authors.

@Jondolf Jondolf added S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it and removed S-Needs-Review Needs reviewer attention (from anyone!) to move forward labels Mar 31, 2025
@alice-i-cecile alice-i-cecile added this pull request to the merge queue Mar 31, 2025
Merged via the queue into bevyengine:main with commit 45e2398 Mar 31, 2025
49 checks passed
mockersf pushed a commit that referenced this pull request Mar 31, 2025
- Fixes #18397
- Supersedes #18474
- Simplifies 0.16 migration

- Upgrade to Glam 0.29.3, which has backported the `nostd-libm` feature.
- Expose a similar feature in `bevy_math` and enable it in
`bevy_internal`, allowing `bevy_math`, `bevy_input`, and
`bevy_transform` to be unconditional dependencies again.

- CI

---

- This includes `libm` as a dependency, but this was already the case in
the common scenario where `rand` or many other features were enabled.
Considering `libm` is an official Rust crate, it's a very low-risk
dependency to unconditionally include.
- For users who do not want `libm` included, simply import Bevy's
subcrates directly, since `bevy_math/nostd-libm` will not be enabled.
- I know we are _very_ late in the RC cycle for 0.16, but this has a
substantial impact on the usability of `bevy` that I consider worth
including.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Math Fundamental domain-agnostic mathematical operations C-Dependencies A change to the crates that Bevy depends on D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it X-Contentious There are nontrivial implications that should be thought through
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bevy_input is now optional, but there's no way to enable it
3 participants