nixpkgs/pkgs/applications/science/math/weka/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

33 lines
1004 B
Nix
Raw Normal View History

2021-01-15 13:21:58 +00:00
{ lib, stdenv, fetchurl, jre, unzip, makeWrapper }:
2013-06-19 15:12:55 +01:00
2016-06-07 22:05:52 +01:00
stdenv.mkDerivation rec {
pname = "weka";
2022-12-01 14:38:24 +00:00
version = "3.9.6";
2016-06-07 22:05:52 +01:00
2013-06-19 15:12:55 +01:00
src = fetchurl {
url = "mirror://sourceforge/weka/${lib.replaceStrings ["."]["-"] "${pname}-${version}"}.zip";
2022-12-01 14:38:24 +00:00
sha256 = "sha256-8fVN4MXYqXNEmyVtXh1IrauHTBZWgWG8AvsGI5Y9Aj0=";
2013-06-19 15:12:55 +01:00
};
nativeBuildInputs = [ makeWrapper unzip ];
2016-06-07 22:05:52 +01:00
2013-06-19 15:12:55 +01:00
# The -Xmx1000M comes suggested from their download page:
# http://www.cs.waikato.ac.nz/ml/weka/downloading.html
installPhase = ''
2018-04-05 19:21:16 +01:00
mkdir -pv $out/share/weka
2013-06-19 15:12:55 +01:00
cp -Rv * $out/share/weka
2016-06-07 22:05:52 +01:00
2018-04-05 19:21:16 +01:00
makeWrapper ${jre}/bin/java $out/bin/weka \
--add-flags "-Xmx1000M -jar $out/share/weka/weka.jar"
2013-06-19 15:12:55 +01:00
'';
2016-06-07 22:05:52 +01:00
2022-12-01 14:38:24 +00:00
meta = with lib; {
homepage = "http://www.cs.waikato.ac.nz/ml/weka/";
2013-06-19 15:12:55 +01:00
description = "Collection of machine learning algorithms for data mining tasks";
2022-12-01 14:38:24 +00:00
sourceProvenance = with sourceTypes; [ binaryBytecode ];
license = licenses.gpl2Plus;
maintainers = [ maintainers.mimame ];
platforms = platforms.unix;
2013-06-19 15:12:55 +01:00
};
}