about summary refs log tree commit diff
path: root/nixpkgs/pkgs/applications/science/electronics/kicad/libraries.nix
blob: e98f2e49576b323a7dd860c83fb35bc3267d2687 (plain) (blame)
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
{ lib, stdenv
, cmake
, gettext
, libSrc
, libVersion
}:
let
  mkLib = name:
    stdenv.mkDerivation {
      pname = "kicad-${name}";
      version = libVersion;

      src = libSrc name;

      nativeBuildInputs = [ cmake ];

      meta = rec {
        license = lib.licenses.cc-by-sa-40;
        platforms = lib.platforms.all;
        # the 3d models are a ~1 GiB download and occupy ~5 GiB in store.
        # this would exceed the hydra output limit
        hydraPlatforms = if (name == "packages3d") then [ ] else platforms;
      };
    };
in
{
  symbols = mkLib "symbols";
  templates = mkLib "templates";
  footprints = mkLib "footprints";
  packages3d = mkLib "packages3d";
}