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

Nix-build is broken, nix build works #3107

Closed
3 tasks done
tomsmalley opened this issue Feb 4, 2022 · 2 comments
Closed
3 tasks done

Nix-build is broken, nix build works #3107

tomsmalley opened this issue Feb 4, 2022 · 2 comments
Assignees
Labels

Comments

@tomsmalley
Copy link

Just checking...

  • This is a cardano-wallet bug.
  • I am using the latest cardano-wallet release.
  • I am using the correct cardano-node version for that release of cardano-wallet.

Version

dde6270

Platform

Linux nixos 5.10.88 #1-NixOS SMP Wed Dec 22 08:31:00 UTC 2021 x86_64 GNU/Linux

Installation method

Nix

Network configuration

No response

Context

When running nix-build in the project root directory, I get:

building '/nix/store/4ig2z0ly7yjnzxcfhkl3rwqy739gkm94-source.drv'...

trying https://api.github.com/repos/numtide/flake-utils/tarball/74f7e4319258e287b0f9cb95426c9853b282730b
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  7256  100  7256    0     0  28793      0 --:--:-- --:--:-- --:--:-- 28793
unpacking source archive /build/74f7e4319258e287b0f9cb95426c9853b282730b
do not know how to unpack source archive /build/74f7e4319258e287b0f9cb95426c9853b282730b
error: builder for '/nix/store/4ig2z0ly7yjnzxcfhkl3rwqy739gkm94-source.drv' failed with exit code 1

But if I use Nix with flakes and nix-command, I can run nix flake archive, and subsequent nix-builds will work fine because flake-utils is in the store.

Description

Steps to Reproduce

  1. Clone the repo
  2. nix-collect-garbage to ensure you don't have flake-utils in the store
  3. nix-build

Expected behavior

Successful build

Actual behavior

This error:

building '/nix/store/4ig2z0ly7yjnzxcfhkl3rwqy739gkm94-source.drv'...

trying https://api.github.com/repos/numtide/flake-utils/tarball/74f7e4319258e287b0f9cb95426c9853b282730b
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100  7256  100  7256    0     0  28793      0 --:--:-- --:--:-- --:--:-- 28793
unpacking source archive /build/74f7e4319258e287b0f9cb95426c9853b282730b
do not know how to unpack source archive /build/74f7e4319258e287b0f9cb95426c9853b282730b
error: builder for '/nix/store/4ig2z0ly7yjnzxcfhkl3rwqy739gkm94-source.drv' failed with exit code 1
@tomsmalley tomsmalley added the Bug label Feb 4, 2022
@rvl
Copy link
Contributor

rvl commented Feb 8, 2022

Hi @tomsmalley, The next release of cardano-wallet will be using nix flakes for its build.
Could I ask you to please install nix version 2.6.0 (or greater) and enable this configuration:

# nix.conf
experimental-features = nix-command flakes

Then build with the command:

nix build

More information:

Thanks

@rvl rvl linked a pull request Feb 9, 2022 that will close this issue
@rvl rvl self-assigned this Apr 5, 2022
@HeinrichApfelmus HeinrichApfelmus changed the title Nix build is broken Nix-build is broken, nix build works Jul 17, 2023
@HeinrichApfelmus
Copy link
Contributor

Closing — as @rvl said, we no longer support building with plain nix-build, but we do support flakes with nix build.

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

Successfully merging a pull request may close this issue.

4 participants
@HeinrichApfelmus @rvl @tomsmalley and others