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 Mac OS X Sierra 10.12.4] mu-0.9.18 cannot install due to pmccabe-2.6 error #24636

Closed
ag91 opened this issue Apr 4, 2017 · 6 comments
Closed
Labels
6.topic: darwin Running or building packages on Darwin

Comments

@ag91
Copy link

ag91 commented Apr 4, 2017

Issue description

Hello,

Huge thanks for contributing to nix! I am trying to use this great package manager with a Mac, and I am having some issues trying to install my favourite email client.

Steps to reproduce

When I try to install mu with nix-env -I mu, I get the following error:

installing ‘mu-0.9.18’
error: Package ‘pmccabe-2.6’ in ‘/nix/store/p95wisxzddaqm41921jg1x9imwfai5jv-nixpkgs-17.09pre104948.c34db6e419/nixpkgs/pkgs/development/tools/misc/pmccabe/default.nix:25’ is not supported on ‘x86_64-darwin’, refusing to evaluate.

a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowBroken = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowBroken = true; }
to ~/.config/nixpkgs/config.nix.

(use ‘--show-trace’ to show detailed location information)

Technical details

I checked the pmccabe derivation, and it has indeed a constraint on the platform: platforms = platforms.linux;.
Any way this derivation can work on Mac OS X x64?
Thanks,

Andrea

  • System: Mac OS X Sierra 10.12.4
  • Nix version: 1.11.8
  • Nixpkgs version: 17.09pre104948.c34db6e419
@LnL7 LnL7 added the 6.topic: darwin Running or building packages on Darwin label Apr 4, 2017
@LnL7
Copy link
Member

LnL7 commented Apr 4, 2017

It seems the pmccabe dependency is not used or at least optional, this builds fine without it.

mu.override { pmccabe = null; }

@joachifm
Copy link
Contributor

joachifm commented Apr 4, 2017

cc @peterhoeg added it, I think. iirc, that dep is for the test suite.

@peterhoeg
Copy link
Member

This isn't the first time I'm breaking the build on Darwin. How do other people test properly without access to a mac?

@ag91
Copy link
Author

ag91 commented Apr 5, 2017 via email

peterhoeg pushed a commit that referenced this issue Apr 6, 2017
pmccabe: darwin is supported too
Fixes #24636.
@LnL7
Copy link
Member

LnL7 commented Apr 6, 2017

@peterhoeg You can use nix-instantiate --argstr system x86_64-darwin to check evaluation for darwin or other platforms. That should catch simple cases like this if you don't have allowBroken enabled in your config.

@peterhoeg
Copy link
Member

Thanks for the pointer @LnL7. I think the trick is to get darwin running in a VM instead...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
6.topic: darwin Running or building packages on Darwin
Projects
None yet
Development

No branches or pull requests

4 participants