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

onig v4.3.1 fails to build with rust 1.27.0 #97

Closed
rivy opened this Issue Feb 5, 2019 · 3 comments

Comments

Projects
None yet
2 participants
@rivy
Copy link
Contributor

rivy commented Feb 5, 2019

Compilation is broken for rust v1.27.0 with v4.3.1...

   Compiling onig v4.3.1
error[E0658]: access to extern crates through prelude is experimental (see issue #44660)
   --> C:\Users\appveyor\.cargo\registry\src\github.com-1ecc6299db9ec823\onig-4.3.1\src\find.rs:180:43
    |
180 |                 (&mut region.raw) as *mut onig_sys::OnigRegion,
    |                                           ^^^^^^^^
error: aborting due to previous error
For more information about this error, try `rustc --explain E0658`.
error: Could not compile `onig`.

A month ago, v4.2.1 compiled and worked without error.

I think a minimum rust compiler version change should mean a semver major version increment (not just a minor), so that builds don't just arbitrarily break on re-build.

I also can't find any indication for minimum rust version in your code, docs, or CI.

Thanks for your attention.

rivy added a commit to rivy/rust.coreutils that referenced this issue Feb 5, 2019

expr: fix ~ restrict onig version to 4.2.1
* v4.3+ (accidentally?) introduces a new minimum rust version > 1.27 (see rust-onig/rust-onig#97 )

rivy added a commit to rivy/rust.coreutils that referenced this issue Feb 5, 2019

expr: fix ~ restrict onig version to 4.2.1
* v4.3+ (accidentally?) introduces a new minimum rust version > 1.27 (see rust-onig/rust-onig#97 )

rivy added a commit to rivy/rust.coreutils that referenced this issue Feb 6, 2019

expr: fix ~ restrict onig version to 4.2.1
* v4.3+ (accidentally?) introduces a new minimum rust version > 1.27 (see rust-onig/rust-onig#97 )

@iwillspeak iwillspeak self-assigned this Feb 6, 2019

rivy added a commit to rivy/rust.coreutils that referenced this issue Feb 7, 2019

expr: fix ~ restrict onig version to 4.2.1
* v4.3+ (accidentally?) introduces a new minimum rust version > 1.27 (see rust-onig/rust-onig#97 )
@iwillspeak

This comment has been minimized.

Copy link
Collaborator

iwillspeak commented Feb 7, 2019

Thanks for this report. Unfortunately this crate hasn't had a very grown up policy towards minimum Rust version so far. It should do though. I can see two ways to solve this:

Treat compiler version as major brekaing change:

  • Document the crate's minimum supported rustc version
  • Publish a new major version with the same codebase
  • Publish a new minor version which rolls Rust support back to 1.27
  • Include a test compile wtih our stated minimum rustc version in CI

Treat compiler version as minior brekaing change:

  • Document the crate's minimum supported rustc version
  • Include a test compile with our stated minimum rustc version in CI

I had kind of always assumed people depended on crates with x.y version numbers and that compiler version changes were treated as minor version breaking changes in the Rust ecosystem. This appears to be BurntSushi's oppinion over on https://users.rust-lang.org/t/rust-version-requirement-change-as-semver-breaking-or-not/20980 (https://github.com/rust-lang/regex#minimum-rust-version-policy).

rivy added a commit to rivy/rust.coreutils that referenced this issue Feb 8, 2019

expr: fix ~ update onig/onig_sys dependency (fixes windows compilatio…
…n bug)

* fixes compile bug which blocked compilation on windows unless the MSVC/VS tools were
  prepared and available on the PATH (via `vsvarsall` or the "VCX command prompt")
* restrict to v4.2.1; v4.3+ introduces a new minimum rust version > 1.27 (see rust-onig/rust-onig#97)

rivy added a commit to rivy/rust.coreutils that referenced this issue Feb 8, 2019

expr: fix ~ restrict onig version to 4.2.1
* v4.3+ (accidentally?) introduces a new minimum rust version > 1.27 (see rust-onig/rust-onig#97 )

rivy added a commit to rivy/rust.coreutils that referenced this issue Feb 9, 2019

expr: fix ~ restrict onig version to 4.2.1
* v4.3+ (accidentally?) introduces a new minimum rust version > 1.27 (see rust-onig/rust-onig#97 )

iwillspeak added a commit that referenced this issue Feb 9, 2019

Fixup Compilation Errors on Rust 1.27.0
Fixes #97 by sqaushing warnings from no clippy and fixing the error in
the cast's path.

iwillspeak added a commit that referenced this issue Feb 9, 2019

Discuss Supported Rust Version in README
Add versioning policy to clarify #97
@iwillspeak

This comment has been minimized.

Copy link
Collaborator

iwillspeak commented Feb 9, 2019

This should now be fixed by #98.

@iwillspeak iwillspeak closed this Feb 9, 2019

@rivy

This comment has been minimized.

Copy link
Contributor Author

rivy commented Feb 9, 2019

Thanks for the quick response!

rivy added a commit to rivy/rust.coreutils that referenced this issue Feb 9, 2019

expr: fix ~ restrict onig version to v4.3.2 (or later patches)
.# Discussion

onig v4.3.0/v4.3.1 inadvertently introduced a new minimum rust version (requiring v1.31+;
see rust-onig/rust-onig#97). This was repaired with v4.3.2, and
onig now specifies that rust minimum version will stay the same for patches, but may
change between minor version increments.

@rivy rivy referenced this issue Feb 11, 2019

Merged

Windows fixes #99

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment