-
Notifications
You must be signed in to change notification settings - Fork 54
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
Automatic alloc detection #95
Conversation
miniz_oxide/build.rs
Outdated
|
||
fn main() { | ||
autocfg::new().emit_sysroot_crate("alloc"); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lacking newline
Yeah this would be nice. @HeroicKatora does this work fine for your needs? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe it should work if the feature is not removed but simply changed into a no-op.
Is it fine now @HeroicKatora ? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be good to go. The branch works as a drop-in in png
etc.
flate2 was pinned to versions <= 1.0.14 in zip-rs#175, because flate2 updated to a new version of miniz_oxide which increased its MSRV (zip-rs#170, Frommi/miniz_oxide#85). This was fixed in Frommi/miniz_oxide#95, so all published versions of flate2 can once agoin be built with Rust 1.34.0.
Closes #94
Uses
autocfg
to detect the availability of thealloc
crate, removing the need for a feature. This avoids forcing libraries to proxy the feature through, or awkward extra dependencies onminiz_oxide
to force the feature to be enabled.I don't actually know any way this could break semver. The
no_extern_crate_alloc
won't usealloc
<1.36, but they're all going to be rexported instd
anyway. Either way,0.4.1
is only ~10 days old