NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
17.61k stars 13.77k forks source link

mathematica: build fails when sandbox is enabled #66123

Open dfoxfranke opened 5 years ago

dfoxfranke commented 5 years ago

Mathematica 12.0 won't build when sandboxing is enabled (but works fine after I set nix.useSandbox = false).

$ nix-env -iA nixos-unstable.mathematica
installing 'mathematica-12.0.0'
these derivations will be built:
  /nix/store/a9hm1nrxg910lpfx3ylbi5d2vb2549qg-mathematica-12.0.0.drv
building '/nix/store/a9hm1nrxg910lpfx3ylbi5d2vb2549qg-mathematica-12.0.0.drv'...
unpacking sources
=== Extracting makeself archive ===
490761+1 records in
8618040+0 records out
4412436480 bytes (4.4 GB, 4.1 GiB) copied, 6.00982 s, 734 MB/s
patching sources
configuring
no configure script, doing nothing
glibPreInstallPhase
installing
=== Running MathInstaller ===
/nix/store/f74zj9535vgk9nlrskk1qgk3v6m7w6n4-stdenv-linux/setup: line 1328: cd: /nix/store/vfczgsldk12q9hjcm97c2ga2g4ip48ah-mathematica-12.0.0/libexec/Mathematica/Executables: No such file or directory
builder for '/nix/store/a9hm1nrxg910lpfx3ylbi5d2vb2549qg-mathematica-12.0.0.drv' failed with exit code 1
error: build of '/nix/store/a9hm1nrxg910lpfx3ylbi5d2vb2549qg-mathematica-12.0.0.drv' failed
$ nix run nixpkgs.nix-info -c nix-info -m
 - system: `"x86_64-linux"`
 - host os: `Linux 4.19.63, NixOS, 19.03.173228.93ea6db29cc (Koi)`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.2.2`
 - channels(dfranke): `"nixos-unstable-19.09pre187587.57d65085125"`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`
dfoxfranke commented 5 years ago

cc @herberteuler

herberteuler commented 5 years ago

I cannot reproduce this error here. My environment is like this:

$ nix run nixpkgs.nix-info -c nix-info -m
 - system: `"x86_64-linux"`
 - host os: `Linux 4.19.46, NixOS, 19.03.git.3769819 (Koi)`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.2.2`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`

I checked out nixpkgs 57d6508 and tried to install Mathematica from it, and it succeeded.

stale[bot] commented 4 years ago

Thank you for your contributions.

This has been automatically marked as stale because it has had no activity for 180 days.

If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity.

Here are suggestions that might help resolve this more quickly:

  1. Search for maintainers and people that previously touched the related code and @ mention them in a comment.
  2. Ask on the NixOS Discourse.
  3. Ask on the #nixos channel on irc.freenode.net.
ullika commented 3 years ago

This problem occurs whenever the MathInstaller fails (for me this was the case because there wasn't enough free disk space). I suggest to implement some kind of error handling with a more informative message or remove the "silent" switch where the MathInstaller script is run.

stale[bot] commented 2 years ago

I marked this as stale due to inactivity. → More info