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

"nixos-rebuild dry-build" just built something. #20422

Closed
spacekitteh opened this issue Nov 15, 2016 · 4 comments
Closed

"nixos-rebuild dry-build" just built something. #20422

spacekitteh opened this issue Nov 15, 2016 · 4 comments

Comments

@spacekitteh
Copy link
Contributor

spacekitteh commented Nov 15, 2016

Issue description

I issued the command once, then quickly canceled it because i thought I had to change something, changed my mind, and re-did the command (all over a period of about a second.)

building the system configuration...
^C

[spacekitteh@spaceserv:~]$ error: interrupted by the user
sudo nixos-rebuild dry-build -I nixpkgs=https://github.com/NixOS/nixpkgs/archive/master.tar.gz
building the system configuration...
fetching path ‘/nix/store/1skciy7shbqd30a9krf22bcxr48yrmrd-cjdns-v18.tar.gz’...
fetching path ‘/nix/store/p388ghnjvnxslac0rg7zv0yccpih4q1w-nodejs-6.9.1’...
fetching path ‘/nix/store/8bvcnygy0xpddy6mq9mwpy5zvp7hai60-util-linux-2.28.1-dev’...

*** Downloading ‘https://cache.nixos.org/nar/1mdkyqks1bdqxd7z88wixcfqb85v1ydgymb15y69v1a5vwks7r7a.nar.xz’ (signed by ‘cache.nixos.org-1’) to ‘/nix/store/8bvcnygy0xpddy6mq9mwpy5zvp7hai60-util-linux-2.28.1-dev’...

*** Downloading ‘https://cache.nixos.org/nar/0wfvii9xrqrxi07b75zd4diyz7094f9q7hji7py2irhcgjx31wzw.nar.xz’ (signed by ‘cache.nixos.org-1’) to ‘/nix/store/1skciy7shbqd30a9krf22bcxr48yrmrd-cjdns-v18.tar.gz’...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
*** Downloading ‘https://cache.nixos.org/nar/1f6c3kk09m6hvpg8h13y8p4vzblg0apqc6n3zhkc81ab81pn27wy.nar.xz’ (signed by ‘cache.nixos.org-1’) to ‘/nix/store/p388ghnjvnxslac0rg7zv0yccpih4q1w-nodejs-6.9.1’...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 15692  100 15692    0     0   8907      0  0:00:01  0:00:01 --:--:--  8905

100 3813k  100 3813k    0     0  86102      0  0:00:45  0:00:45 --:--:-- 87947

100 7374k  100 7374k    0     0  88620      0  0:01:25  0:01:25 --:--:-- 93050

building path(s) ‘/nix/store/qnb2l3vqmk757qyvi602rr46cmpg0zcj-cjdns-18’
unpacking sources
unpacking source archive /nix/store/1skciy7shbqd30a9krf22bcxr48yrmrd-cjdns-v18.tar.gz
source root is cjdns-cjdns-v18
setting SOURCE_DATE_EPOCH to timestamp 1476221984 of file cjdns-cjdns-v18/wire/SwitchHeader.h
patching sources
configuring
no configure script, doing nothing
building
Initialize 12ms
{"isLLVM":false,"isClang":false,"isGCC":true,"version":"5.4.0"}
Copy dependencies
Compiler supports link time optimization
Build NaCl
Creating directories
Getting system type
System is [amd64]
Using premade plan at [node_build/plans/amd64_plan.json]
Creating system specific integer type headers
beginning build
implementations generated
Compiling jsbuild/objects_internal/crypto_hashblocks_sha512_inplace_blocks.c.o
Compiling jsbuild/objects_internal/crypto_scalarmult_curve25519_donna_c64_base.c.o
Compiling jsbuild/objects_internal/crypto_scalarmult_curve25519_donna_c64_smult.c.o
etc etc etc

Technical details

  • System: 17.03pre-git (Gorilla)
  • Nix version: nix-env (Nix) 1.11.4
  • Nixpkgs version: master
@danbst
Copy link
Contributor

danbst commented Nov 15, 2016

My guess is it is because of import from derivation (https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/services/networking/cjdns.nix#L32). Eelco already mentioned this in in another thread

@joachifm
Copy link
Contributor

This is expected behavior. It needs a build of cjdns at eval time to add stuff to extraHosts.
The only obvious way around the need for import-from-derivation is to implement the pubkey -> ipv6 addr in pure Nix. Alternatively, a self-contained pubkey -> ipv6 addr utility could be created/extracted and used instead of pulling in all of cjdns for that purpose, but then you'd still have to contend with a stdenv build at eval time.

Might make sense to guard that logic with a conditional, so that only users who need that feature pay for the overhead. If it turns out nobody actually needs it, it could be outright removed.

@joachifm
Copy link
Contributor

cc @ehmry

@ehmry
Copy link
Contributor

ehmry commented Nov 18, 2016

I say remove it, its kind of a cool feature, but not worth the overhead.

@ehmry ehmry self-assigned this Nov 18, 2016
@ehmry ehmry closed this as completed in 60ded3f Nov 18, 2016
wizeman pushed a commit to wizeman/nixpkgs that referenced this issue Feb 13, 2017
Generating IPv6 addresses at eval time required building cjdns.

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

No branches or pull requests

5 participants