-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathdefault.nix
36 lines (32 loc) · 925 Bytes
/
default.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# nixpkgs with our overlay packages.
# This file gets referenced when you import <fc>.
# Set up environment: eval $(./dev-setup)
# Build upstream pacakge: nix-build -A hello
# Build own package: nix-build -A fc.userscan
# ===
# <nixpkgs> should usually point to FC patched upstream nixpkgs
{
nixpkgs ? <nixpkgs>,
localSystem ? builtins.intersectAttrs {
system = null;
platform = null;
} args,
system ? localSystem.system,
platform ? localSystem.platform,
crossSystem ? null,
overlays ? [ ],
config ? { },
}@args:
with builtins;
let
nixpkgsConfig = import ./nixpkgs-config.nix;
getName = pkg: pkg.pname or (parseDrvName pkg.name);
in
import nixpkgs {
overlays = overlays ++ [ (import ./pkgs/overlay.nix) ];
config = config // {
inherit (nixpkgsConfig) permittedInsecurePackages;
allowUnfreePredicate = pkg: elem (getName pkg) nixpkgsConfig.allowedUnfreePackageNames;
};
}
// args