Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Support aarch64-darwin #335

Closed
liaowang11 opened this issue Jul 5, 2021 · 5 comments
Closed

Support aarch64-darwin #335

liaowang11 opened this issue Jul 5, 2021 · 5 comments
Labels
enhancement New feature or request

Comments

@liaowang11
Copy link

Your issue may already be reported!
Please search on the issue tracker before creating one.

Describe the solution you'd like

Define aarch64-darwin system doesn't work for now, I get

A definition for option `nixos.hosts.mbp-m1.system' is not of type `system defined in `supportedSystems`'.

But I cannot find supportedSystems defined any where in digga or devos, maybe it's from nixpkgs?

        hosts = {
          "mbp-m1" = {
            system = "aarch64-darwin";
          };
        };

Describe alternatives you've considered

For now, only have to manually import pkgsM1 to use any native packages.

  pkgsM1 = import <nixpkgs> { localSystem = "aarch64-darwin"; };
@liaowang11 liaowang11 added the enhancement New feature or request label Jul 5, 2021
@Pacman99
Copy link
Member

Pacman99 commented Jul 5, 2021

supportedSystems is a top-level argument in digga. It can be set in your flake.nix, just add a supportedSystems = [ ... ] line anywhere inside the attribute set thats passed to mkFlake.

@blaggacao
Copy link
Contributor

blaggacao commented Jul 5, 2021

@liaowang11
Copy link
Author

liaowang11 commented Jul 6, 2021

supportedSystems is a top-level argument in digga. It can be set in your flake.nix, just add a supportedSystems = [ ... ] line anywhere inside the attribute set thats passed to mkFlake.

Works like a charm.
Is there any way in digga that I can define two nixpkgs(one for native and one for x86_64-darwin) to pass to my m1 host config? I have to use --impure to build homeConfigurations.

@blaggacao
Copy link
Contributor

Is there any way in digga that I can define two nixpkgs(one for native and one for x86_64-darwin) to pass to my m1 host config? I have to use --impure to build homeConfigurations.

Could you clarify what you are trying to do? Do you want to have different {pkgs, ... } as module inputs? Something doesn't sound right, though. Or most probably: I'm missing most of the context.

@liaowang11
Copy link
Author

Is there any way in digga that I can define two nixpkgs(one for native and one for x86_64-darwin) to pass to my m1 host config? I have to use --impure to build homeConfigurations.

Could you clarify what you are trying to do? Do you want to have different {pkgs, ... } as module inputs? Something doesn't sound right, though. Or most probably: I'm missing most of the context.

Yes, I wish to have something like {pkgs, pkgsM1, ...}. As some package are still not working under aarch64-darwin, I would like to use pkgsM1 for packages that are working natively and pkgs for some package like ghc.

What I do to archive this for now is just importing another pkgs on top of every module file, which looks ugly and cannot use devos packages defined in pkgs folder.

pkgsX86 = import <nixpkgs> { localSystem = "x86_64-darwin"; };

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants