Skip to content

Commit

Permalink
Merge pull request #18 from nrdxp/multiArch
Browse files Browse the repository at this point in the history
initial multiArch support
  • Loading branch information
nrdxp committed Dec 28, 2020
2 parents bd9367b + 7a6e725 commit 766b54b
Show file tree
Hide file tree
Showing 9 changed files with 76 additions and 28 deletions.
16 changes: 16 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

78 changes: 52 additions & 26 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,17 @@
master.url = "nixpkgs/master";
nixos.url = "nixpkgs/release-20.09";
home.url = "github:nix-community/home-manager/release-20.09";
flake-utils.url = "github:numtide/flake-utils";
};

outputs = inputs@{ self, home, nixos, master, nur }:
outputs = inputs@{ self, home, nixos, master, flake-utils, nur }:
let
inherit (builtins) attrNames attrValues readDir;
inherit (builtins) attrNames attrValues readDir elem;
inherit (flake-utils.lib) eachDefaultSystem;
inherit (nixos) lib;
inherit (lib) removeSuffix recursiveUpdate genAttrs filterAttrs;
inherit (lib) all removeSuffix recursiveUpdate genAttrs filterAttrs;
inherit (utils) pathsToImportedAttrs genPkgset overlayPaths modules
genPackages;
genPackages pkgImport;

utils = import ./lib/utils.nix { inherit lib; };

Expand All @@ -27,33 +29,57 @@
genPkgset {
inherit master nixos overlays system;
};
in
with pkgset;
{
nixosConfigurations =
import ./hosts (recursiveUpdate inputs {
inherit lib pkgset system utils;
});

devShell."${system}" = import ./shell.nix {
pkgs = osPkgs;
};
outputs = {
nixosConfigurations =
import ./hosts (recursiveUpdate inputs {
inherit lib pkgset system utils;
});

overlay = import ./pkgs;
overlay = import ./pkgs;

overlays = pathsToImportedAttrs overlayPaths;
overlays = pathsToImportedAttrs overlayPaths;

packages."${system}" = genPackages {
overlay = self.overlay;
overlays = self.overlays;
pkgs = osPkgs;
};
nixosModules = modules;

nixosModules = modules;
templates.flk.path = ./.;

templates.flk.path = ./.;
templates.flk.description = "flk template";
templates.flk.description = "flk template";

defaultTemplate = self.templates.flk;
};
defaultTemplate = self.templates.flk;
};
in
(eachDefaultSystem (system':
let
pkgs' = pkgImport {
pkgs = nixos;
system = system';
overlays = [ ];
};
in
{
devShell = import ./shell.nix {
pkgs = pkgs';
};

packages =
let
packages' = genPackages {
overlay = self.overlay;
overlays = self.overlays;
pkgs = pkgs';
};

filtered = filterAttrs
(_: v:
(v.meta ? platforms)
&& (elem system' v.meta.platforms)
&& (
(all (dev: dev.meta ? platforms) v.buildInputs)
&& (all (dev: elem system' dev.meta.platforms) v.buildInputs)
))
packages';
in
filtered;
})) // outputs;
}
2 changes: 1 addition & 1 deletion pkgs/applications/blockchains/miningcore/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,6 @@ stdenv.mkDerivation rec {
homepage = "https://github.com/akshaynexus/miningcore";
license = licenses.mit;
maintainers = with maintainers; [ nrdxp ];
platforms = [ "x86_64-linux" ];
platforms = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" ];
};
}
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,11 @@ stdenv.mkDerivation {
'';

meta = with stdenv.lib; {
inherit version;
description = "The hottest theme around for SDDM";
homepage = "https://github.com/MarianArlt/sddm-chili";
maintainers = [ maintainers.nrdxp ];
license = licenses.gpl3;
inherit version;
platforms = platforms.linux;
};
}
1 change: 1 addition & 0 deletions pkgs/applications/window-managers/steamcompmgr/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ stdenv.mkDerivation {
homepage = "https://github.com/steamos-compositor-plus";
maintainers = [ maintainers.nrdxp ];
license = licenses.bsd2;
platforms = platforms.linux;
inherit version;
};
}
1 change: 1 addition & 0 deletions pkgs/data/fonts/dejavu-nerdfont/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ stdenv.mkDerivation {
homepage = "https://github.com/ryanoasis/nerd-fonts";
license = licenses.mit;
maintainers = [ maintainers.nrdxp ];
platforms = platforms.unix;
inherit version;
};
}
1 change: 1 addition & 0 deletions pkgs/misc/drivers/wii-u-gc-adapter/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ stdenv.mkDerivation {
homepage = "https://github.com/ToadKing/wii-u-gc-adapter";
maintainers = [ maintainers.nrdxp ];
license = licenses.mit;
platforms = platforms.linux;
inherit version;
};
}
1 change: 1 addition & 0 deletions pkgs/shells/zsh/pure/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ stdenv.mkDerivation {
description = "Pretty, minimal and fast ZSH prompt";
homepage = "https://github.com/sindresorhus/pure";
maintainers = [ maintainers.nrdxp ];
platforms = platforms.unix;
license = licenses.mit;
inherit version;
};
Expand Down
1 change: 1 addition & 0 deletions pkgs/shells/zsh/purs/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ buildRustPackage {
homepage = "https://github.com/xcambar/purs";
maintainers = [ maintainers.nrdxp ];
license = licenses.mit;
platforms = platforms.unix;
inherit version;
};
}

0 comments on commit 766b54b

Please sign in to comment.