2021-01-17 00:15:33 +00:00
|
|
|
{ lib, stdenv, fetchurl, jre, makeWrapper, substituteAll, coreutils }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "cytoscape";
|
2021-12-06 16:07:01 +00:00
|
|
|
version = "3.9.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2020-05-29 06:06:01 +00:00
|
|
|
url = "https://github.com/cytoscape/cytoscape/releases/download/${version}/${pname}-unix-${version}.tar.gz";
|
2021-12-06 16:07:01 +00:00
|
|
|
sha256 = "sha256-7YDmojzQujHrsDuB7WC0C3Z2srTd9QUveh1baod3KvU=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2020-05-29 06:06:01 +00:00
|
|
|
patches = [
|
|
|
|
# By default, gen_vmoptions.sh tries to store custom options in $out/share
|
|
|
|
# at run time. This patch makes sure $HOME is used instead.
|
|
|
|
(substituteAll {
|
|
|
|
src = ./gen_vmoptions_to_homedir.patch;
|
|
|
|
inherit coreutils;
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2021-03-09 03:18:52 +00:00
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
buildInputs = [ jre ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -pv $out/{share,bin}
|
|
|
|
cp -Rv * $out/share/
|
|
|
|
|
|
|
|
ln -s $out/share/cytoscape.sh $out/bin/cytoscape
|
|
|
|
|
|
|
|
wrapProgram $out/share/cytoscape.sh \
|
|
|
|
--set JAVA_HOME "${jre}" \
|
|
|
|
--set JAVA "${jre}/bin/java"
|
|
|
|
|
|
|
|
chmod +x $out/bin/cytoscape
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = "http://www.cytoscape.org";
|
|
|
|
description = "A general platform for complex network analysis and visualization";
|
2021-01-17 00:15:33 +00:00
|
|
|
license = lib.licenses.lgpl21;
|
|
|
|
maintainers = [lib.maintainers.mimame];
|
|
|
|
platforms = lib.platforms.unix;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|