Tidy up legacyPackages instantiation
This commit is contained in:
parent
1c7d71a00f
commit
256fac99ad
29
flake.nix
29
flake.nix
|
@ -180,22 +180,19 @@
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
legacyPackages =
|
legacyPackages = forAllSystems ({ system, localSystem, crossSystem }:
|
||||||
# The nixpkgs.legacyPackages set after overlaying.
|
if builtins.hasAttr system nixpkgs.legacyPackages then
|
||||||
let f = import nixpkgs;
|
nixpkgs.legacyPackages.${system}.appendOverlays overlays
|
||||||
in forAllSystems ({ system, localSystem, crossSystem }:
|
else
|
||||||
if localSystem == crossSystem then
|
import nixpkgs {
|
||||||
nixpkgs.legacyPackages.${system}.appendOverlays overlays
|
inherit localSystem;
|
||||||
else
|
crossSystem = {
|
||||||
f {
|
system = crossSystem;
|
||||||
inherit localSystem;
|
useLLVM = true;
|
||||||
crossSystem = {
|
};
|
||||||
system = crossSystem;
|
config.allowUnsupportedSystem = true;
|
||||||
useLLVM = true;
|
inherit overlays;
|
||||||
};
|
});
|
||||||
config.allowUnsupportedSystem = true;
|
|
||||||
inherit overlays;
|
|
||||||
});
|
|
||||||
|
|
||||||
packages =
|
packages =
|
||||||
# Genode native packages, not packages in the traditional
|
# Genode native packages, not packages in the traditional
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
./qemu-vm.nix
|
./qemu-vm.nix
|
||||||
./services
|
./services
|
||||||
];
|
];
|
||||||
nixpkgs = {
|
nixpkgs = rec {
|
||||||
localSystem.system = "x86_64-linux";
|
localSystem.system = "x86_64-linux";
|
||||||
crossSystem.system = "x86_64-genode";
|
crossSystem.system = "x86_64-genode";
|
||||||
system = localSystem.system + "-" + crossSystem.system;
|
system = localSystem.system + "-" + crossSystem.system;
|
||||||
|
|
Loading…
Reference in New Issue