Skip to content
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

wl-screenrec doesn't override cargoHash or use a Cargo.lock etc #452

Open
colemickens opened this issue Jun 22, 2024 · 2 comments
Open

wl-screenrec doesn't override cargoHash or use a Cargo.lock etc #452

colemickens opened this issue Jun 22, 2024 · 2 comments

Comments

@colemickens
Copy link
Member

Uh,

Not sure how this was ever working.

This tries to use updated sources, with an old cargo hash.

I might disable wl-screenrec for now.

@Artturin
Copy link
Member

Artturin commented Jun 22, 2024

// lib.optionalAttrs (previousAttrs ? cargoDeps) {
cargoDeps = prev.rustPlatform.importCargoLock cargoLock;
cargoHash = null;
is working and there's no error like ERROR: cargoHash or cargoSha256 is out of date after Validating consistency between /build/source/Cargo.lock and /build/.../Cargo.lock

Applying this patch to nixpkgs

diff --git a/pkgs/tools/wayland/wl-screenrec/default.nix b/pkgs/tools/wayland/wl-screenrec/default.nix
index 2836d7fed2bb..648109de6055 100644
--- a/pkgs/tools/wayland/wl-screenrec/default.nix
+++ b/pkgs/tools/wayland/wl-screenrec/default.nix
@@ -14,11 +14,11 @@ rustPlatform.buildRustPackage rec {
   src = fetchFromGitHub {
     owner = "russelltg";
     repo = pname;
-    rev = "v${version}";
-    hash = "sha256-ThPZPV1GyMFRu94O9WwUpXbR4gnIML26K7TyIfXZlcI=";
+    rev = "a3d0b5da69487441ce81ebfc3be8ba8d2255c714";
+    hash = "sha256-DE0Olwc2hYuGjkA1p1kbEXxMmoWOH7PTrne6pm1z97s=";
   };
 
-  cargoHash = "sha256-DtlVsUFKNKXcwqNvGvqkSKUE+kRHX8wajL4fR0c9ZuQ=";
+  cargoHash = "sha256-EDH0Q3+U0pMaxCfiO74MSbjqwNJfMLp0lImc4/2aQWA=";
 
   nativeBuildInputs = [
     pkg-config

Results in the same error error: none of the selected packages contains these features: avcodec_version_greater_than_56_0, avcodec_ver...

@colemickens
Copy link
Member Author

Gotcha, I'll reopen the upstream bug: russelltg/wl-screenrec#77

We can re-add it when it's fixed, you if you want you can downgrade it and re-add it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants