Skip to content

Update bindgen #159

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 2 commits into from
Dec 14, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ zeroize = { version = "1.1.0", features = ["zeroize_derive"] }
env_logger = "0.7.1"

[build-dependencies]
bindgen = "0.54.0"
bindgen = "0.56.0"
pkg-config = "0.3.18"

[features]
Expand Down
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,15 @@ case:
$ export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig
```

## Minimum Supported Rust Version (MSRV)

At the moment we test (via CI) and support the following Rust compiler versions:

* On Ubuntu we test with the latest stable compiler version, as accessible through `rustup`.
* On Fedora we test with the compiler version included with the Fedora 33 release.
Copy link
Member

Choose a reason for hiding this comment

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

Do we test with the latest compiler version available in Fedora 33?

Copy link
Member Author

Choose a reason for hiding this comment

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

I think we test with the one that comes with the OS release? CC @puiterwijk

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yes, we test with the one that's included in Fedora 33.


If you need support for other versions of the compiler, get in touch with us to see what we can do!
Copy link
Member

Choose a reason for hiding this comment

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

Maybe mention somewhere that for those supproted versions we test on the CI that every PR works with them.

Copy link
Member Author

Choose a reason for hiding this comment

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

I made a mistake on the line before the list above, will include it there.

Copy link
Collaborator

Choose a reason for hiding this comment

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

I was under the impression that we would use the packaged versions for the different distributions so in the case of ubuntu one would need to do the following: apt update && apt -y upgrade && apt install rustc && apt install cargo. So that we could say that we support the latest version that the distribution provides using its update channels.

Copy link
Member Author

Choose a reason for hiding this comment

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

In the Dockerfile we actually build with the pipe-to-shell command from the Rust website - but that's a good point, maybe we should try out the one included in Ubuntu.

Copy link
Member Author

Choose a reason for hiding this comment

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

It seems the latest supported is 1.43.0 (for rustc), but the weird thing is that cargo has version 0.44.1 🤔

Copy link
Member

Choose a reason for hiding this comment

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

I was under the impression that we would use the packaged versions for the different distributions

I think we decided that as well for all the distributions that we want to support (like Fedora) but I think we should also definitely test with the latest stable Rust got from rustup. If Ubuntu is also one of the distribution we want to support then we should do the three:

  • Ubuntu using the latest version of cargo from apt
  • Fedora using the latest version of cargo from dnf
  • any distrib using the latest version from rustup

My point being that for the case when we test on rustup, the distribution should not really matter.


## Community channel

Come and talk to us in [our Slack channel](https://app.slack.com/client/T0JK1PCN6/CPMQ9D4H1)!
Expand Down
30 changes: 0 additions & 30 deletions tests/all-ubuntu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,33 +31,3 @@ RUST_BACKTRACE=1 cargo build
# Run the tests #
#################
RUST_BACKTRACE=1 RUST_LOG=info cargo test -- --test-threads=1 --nocapture

###################
# Stop TPM server #
###################
pkill tpm_server

#############################
# Install nightly toolchain #
#############################
rustup toolchain install nightly

############################
# Install legacy toolchain #
############################
rustup toolchain install 1.38.0

####################
# Verify doc build #
####################
cargo +nightly doc --features docs --verbose --no-deps

########################
# Verify nightly build #
########################
cargo +nightly build

#####################################
# Verify build with legacy compiler #
#####################################
RUST_BACKTRACE=1 cargo +1.38.0 build