forked from NixOS/nixpkgs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
beam-packages.nix
95 lines (80 loc) · 2.57 KB
/
beam-packages.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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
{
lib,
beam,
beam_nodocs,
callPackage,
wxGTK32,
buildPackages,
stdenv,
ex_docSupport ? true,
wxSupport ? true,
systemd,
systemdSupport ? lib.meta.availableOn stdenv.hostPlatform systemd,
}:
let
self = beam;
in
{
beamLib = callPackage ../development/beam-modules/lib.nix { };
latestVersion = "erlang_25";
# Each
interpreters = {
erlang = self.interpreters.${self.latestVersion};
# Standard Erlang versions, using the generic builder.
erlang_27 = self.beamLib.callErlang ../development/interpreters/erlang/27.nix {
wxGTK = wxGTK32;
parallelBuild = true;
autoconf = buildPackages.autoconf269;
inherit (beam_nodocs.packages.erlang_27) ex_doc;
inherit ex_docSupport wxSupport systemdSupport;
};
erlang_26 = self.beamLib.callErlang ../development/interpreters/erlang/26.nix {
wxGTK = wxGTK32;
parallelBuild = true;
autoconf = buildPackages.autoconf269;
inherit wxSupport systemdSupport;
};
erlang_25 = self.beamLib.callErlang ../development/interpreters/erlang/25.nix {
wxGTK = wxGTK32;
parallelBuild = true;
autoconf = buildPackages.autoconf269;
inherit wxSupport systemdSupport;
};
erlang_24 = self.beamLib.callErlang ../development/interpreters/erlang/24.nix {
wxGTK = wxGTK32;
# Can be enabled since the bug has been fixed in https://github.com/erlang/otp/pull/2508
parallelBuild = true;
autoconf = buildPackages.autoconf269;
inherit wxSupport systemdSupport;
};
# Other Beam languages. These are built with `beam.interpreters.erlang`. To
# access for example elixir built with different version of Erlang, use
# `beam.packages.erlang_24.elixir`.
inherit (self.packages.erlang)
elixir
elixir_1_17
elixir_1_16
elixir_1_15
elixir_1_14
elixir_1_13
elixir_1_12
elixir_1_11
elixir_1_10
elixir-ls
lfe
lfe_2_1
;
};
# Helper function to generate package set with a specific Erlang version.
packagesWith = erlang: callPackage ../development/beam-modules { inherit erlang; };
# Each field in this tuple represents all Beam packages in nixpkgs built with
# appropriate Erlang/OTP version.
packages = {
erlang = self.packages.${self.latestVersion};
erlang_27 = self.packagesWith self.interpreters.erlang_27;
erlang_26 = self.packagesWith self.interpreters.erlang_26;
erlang_25 = self.packagesWith self.interpreters.erlang_25;
erlang_24 = self.packagesWith self.interpreters.erlang_24;
};
__attrsFailEvaluation = true;
}