Merge pull request #6044 from sjmackenzie/erlang-javac-hipe
Problem: erlang in nixpkgs doesn't support jinterface + no hipe
This commit is contained in:
commit
b783b69326
|
@ -1,15 +1,19 @@
|
||||||
{ stdenv, fetchurl, perl, gnum4, ncurses, openssl
|
{ stdenv, fetchurl, perl, gnum4, ncurses, openssl
|
||||||
, gnused, gawk, makeWrapper
|
, gnused, gawk, makeWrapper
|
||||||
, odbcSupport ? false, unixODBC ? null
|
, odbcSupport ? false, unixODBC ? null
|
||||||
, wxSupport ? false, mesa ? null, wxGTK ? null, xlibs ? null }:
|
, wxSupport ? true, mesa ? null, wxGTK ? null, xlibs ? null
|
||||||
|
, javacSupport ? false, openjdk ? null
|
||||||
|
, enableHipe ? true}:
|
||||||
|
|
||||||
assert wxSupport -> mesa != null && wxGTK != null && xlibs != null;
|
assert wxSupport -> mesa != null && wxGTK != null && xlibs != null;
|
||||||
assert odbcSupport -> unixODBC != null;
|
assert odbcSupport -> unixODBC != null;
|
||||||
|
assert javacSupport -> openjdk != null;
|
||||||
|
|
||||||
with stdenv.lib;
|
with stdenv.lib;
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "erlang-" + version + "${optionalString odbcSupport "-odbc"}";
|
name = "erlang-" + version + "${optionalString odbcSupport "-odbc"}"
|
||||||
|
+ "${optionalString javacSupport "-javac"}";
|
||||||
version = "17.4";
|
version = "17.4";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
|
@ -20,7 +24,8 @@ stdenv.mkDerivation rec {
|
||||||
buildInputs =
|
buildInputs =
|
||||||
[ perl gnum4 ncurses openssl makeWrapper
|
[ perl gnum4 ncurses openssl makeWrapper
|
||||||
] ++ optional wxSupport [ mesa wxGTK xlibs.libX11 ]
|
] ++ optional wxSupport [ mesa wxGTK xlibs.libX11 ]
|
||||||
++ optional odbcSupport [ unixODBC ];
|
++ optional odbcSupport [ unixODBC ]
|
||||||
|
++ optional javacSupport [ openjdk ];
|
||||||
|
|
||||||
patchPhase = '' sed -i "s@/bin/rm@rm@" lib/odbc/configure erts/configure '';
|
patchPhase = '' sed -i "s@/bin/rm@rm@" lib/odbc/configure erts/configure '';
|
||||||
|
|
||||||
|
@ -29,7 +34,7 @@ stdenv.mkDerivation rec {
|
||||||
sed -e s@/bin/pwd@pwd@g -i otp_build
|
sed -e s@/bin/pwd@pwd@g -i otp_build
|
||||||
'';
|
'';
|
||||||
|
|
||||||
configureFlags= "--with-ssl=${openssl} ${optionalString odbcSupport "--with-odbc=${unixODBC}"} ${optionalString stdenv.isDarwin "--enable-darwin-64bit"}";
|
configureFlags= "--with-ssl=${openssl} ${optionalString enableHipe "--enable-hipe"} ${optionalString odbcSupport "--with-odbc=${unixODBC}"} ${optionalString stdenv.isDarwin "--enable-darwin-64bit"} ${optionalString javacSupport "--with-javac"}";
|
||||||
|
|
||||||
postInstall = let
|
postInstall = let
|
||||||
manpages = fetchurl {
|
manpages = fetchurl {
|
||||||
|
@ -68,6 +73,6 @@ stdenv.mkDerivation rec {
|
||||||
platforms = platforms.unix;
|
platforms = platforms.unix;
|
||||||
# Note: Maintainer of prev. erlang version was simons. If he wants
|
# Note: Maintainer of prev. erlang version was simons. If he wants
|
||||||
# to continue maintaining erlang I'm totally ok with that.
|
# to continue maintaining erlang I'm totally ok with that.
|
||||||
maintainers = [ maintainers.the-kenny ];
|
maintainers = [ maintainers.the-kenny maintainers.sjmackenzie ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -4464,8 +4464,12 @@ let
|
||||||
erlangR16_odbc = callPackage ../development/interpreters/erlang/R16.nix { odbcSupport = true; };
|
erlangR16_odbc = callPackage ../development/interpreters/erlang/R16.nix { odbcSupport = true; };
|
||||||
erlangR17 = callPackage ../development/interpreters/erlang/R17.nix { };
|
erlangR17 = callPackage ../development/interpreters/erlang/R17.nix { };
|
||||||
erlangR17_odbc = callPackage ../development/interpreters/erlang/R17.nix { odbcSupport = true; };
|
erlangR17_odbc = callPackage ../development/interpreters/erlang/R17.nix { odbcSupport = true; };
|
||||||
|
erlangR17_javac = callPackage ../development/interpreters/erlang/R17.nix { javacSupport = true; };
|
||||||
|
erlangR17_odbc_javac = callPackage ../development/interpreters/erlang/R17.nix { javacSupport = true; odbcSupport = true; };
|
||||||
erlang = erlangR17;
|
erlang = erlangR17;
|
||||||
erlang_odbc = erlangR17_odbc;
|
erlang_odbc = erlangR17_odbc;
|
||||||
|
erlang_javac = erlangR17_javac;
|
||||||
|
erlang_odbc_javac = erlangR17_odbc_javac;
|
||||||
|
|
||||||
rebar = callPackage ../development/tools/build-managers/rebar { };
|
rebar = callPackage ../development/tools/build-managers/rebar { };
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue