Skip to content

deepfilternet: fix compilation with Rust 1.80#334838

Merged
SuperSandro2000 merged 1 commit into
NixOS:masterfrom
Mrmaxmeier:deepfilternet-rust-1-80
Aug 16, 2024
Merged

deepfilternet: fix compilation with Rust 1.80#334838
SuperSandro2000 merged 1 commit into
NixOS:masterfrom
Mrmaxmeier:deepfilternet-rust-1-80

Conversation

@Mrmaxmeier

@Mrmaxmeier Mrmaxmeier commented Aug 15, 2024

Copy link
Copy Markdown
Contributor

As per #332957, rust-lang/rust#127343. Bumps the time dependency in Cargo.lock, to fix a compilation issue.

Xref #333227 for a similar PR :)

Upstream issue:
Rikorose/DeepFilterNet#602

Description of changes

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

As per NixOS#332957, rust-lang/rust#127343. Bumps the time dependency in
Cargo.lock, to fix a compilation issue.

Xref NixOS#333227 for a similar PR :)

Upstream issue:
Rikorose/DeepFilterNet#602
@Mrmaxmeier

Copy link
Copy Markdown
Contributor Author

Welp, turns out this is a is a duplicate of #334835

@Mrmaxmeier Mrmaxmeier closed this Aug 15, 2024
@ofborg ofborg Bot requested a review from ralismark August 15, 2024 12:35
@ofborg ofborg Bot added 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels Aug 15, 2024
@Mrmaxmeier Mrmaxmeier reopened this Aug 15, 2024

cargoPatches = [
# Fix compilation with Rust 1.80 (https://github.com/NixOS/nixpkgs/issues/332957)
./cargo-lock-bump-time.patch

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.

Can we symlink the Cargo.lock into place, rather than having to have both a Cargo.lock file and a patch file? Like in #334818.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I kind of like this approach since its clearly bound to the package version that's being patched. It also communicates why the (updated) vendored Cargo.lock is necessary and what's changed.

It seems like the linked PR might cause strange situations when the underlying reason for the patch is made redundant by an upstream release, since there won't be a "patch doesn't apply anymore" to nudge maintainers.

Let me know if this seems reasonable to you. I'm new-ish to Nix packaging so my hunch might be off here 🙂

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.

I think you're quite right, and this is a good instinct. In this case, I think a comment would probably be enough to get it removed on update — it's right there below the source hash, which has to be updated anyway. I regret not asking for that on the other PR.

@nixos-discourse

Copy link
Copy Markdown

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/rustc-explain-e0282-error-could-not-compile-time-lib/50765/4

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

Labels

10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants