summaryrefslogtreecommitdiffstats
path: root/pkgs/os-specific/bsd/openbsd/default.nix
blob: bfc88f097865f795f9cd54a14494247626aa9a9c (plain)
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
{
  lib,
  makeScopeWithSplicing',
  generateSplicesForMkScope,
  buildPackages,
}:

let
  otherSplices = generateSplicesForMkScope "openbsd";
  buildOpenbsd = otherSplices.selfBuildHost;
in

makeScopeWithSplicing' {
  inherit otherSplices;
  f = (
    self:
    lib.packagesFromDirectoryRecursive {
      callPackage = self.callPackage;
      directory = ./pkgs;
    }
    // {
      libc = self.callPackage ./pkgs/libc/package.nix {
        inherit (self) csu include;
        inherit (buildOpenbsd) makeMinimal;
        inherit (buildPackages.netbsd)
          install
          gencat
          rpcgen
          tsort
          ;
      };
      makeMinimal = buildPackages.netbsd.makeMinimal.override { inherit (self) make-rules; };
      mkDerivation = self.callPackage ./pkgs/mkDerivation.nix {
        inherit (buildPackages.netbsd) install;
        inherit (buildPackages.buildPackages) rsync;
      };
      include = self.callPackage ./pkgs/include/package.nix {
        inherit (buildOpenbsd) makeMinimal;
        inherit (buildPackages.netbsd) install rpcgen mtree;
      };
      csu = self.callPackage ./pkgs/csu.nix {
        inherit (self) include;
        inherit (buildOpenbsd) makeMinimal;
        inherit (buildPackages.netbsd) install;
      };
      make-rules = self.callPackage ./pkgs/make-rules/package.nix { };
      lorder = self.callPackage ./pkgs/lorder.nix { inherit (buildPackages.netbsd) install; };
    }
  );
}