nixpkgs/pkgs/development/tools/java/visualvm/default.nix

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

48 lines
1.5 KiB
Nix
Raw Normal View History

{ stdenv, fetchzip, lib, makeWrapper, makeDesktopItem, jdk, gawk }:
2016-08-15 03:45:48 +00:00
stdenv.mkDerivation rec {
2022-01-20 05:57:29 +00:00
version = "2.1.2";
pname = "visualvm";
2016-08-15 03:45:48 +00:00
src = fetchzip {
2018-04-18 02:01:39 +00:00
url = "https://github.com/visualvm/visualvm.src/releases/download/${version}/visualvm_${builtins.replaceStrings ["."] [""] version}.zip";
2022-01-20 05:57:29 +00:00
sha256 = "sha256-khbXzdsC0PA10HEu/dIFQ87+QbKpctmTUTt/zEuxV6c=";
2018-04-18 02:01:39 +00:00
};
desktopItem = makeDesktopItem {
name = "visualvm";
exec = "visualvm";
comment = "Java Troubleshooting Tool";
desktopName = "VisualVM";
genericName = "Java Troubleshooting Tool";
categories = [ "Development" ];
2016-08-15 03:45:48 +00:00
};
nativeBuildInputs = [ makeWrapper ];
installPhase = ''
2018-04-18 02:01:39 +00:00
find . -type f -name "*.dll" -o -name "*.exe" -delete;
2016-08-15 03:45:48 +00:00
substituteInPlace etc/visualvm.conf \
--replace "#visualvm_jdkhome=" "visualvm_jdkhome=" \
--replace "/path/to/jdk" "${jdk.home}" \
cp -r . $out
'';
meta = with lib; {
2016-08-15 03:45:48 +00:00
description = "A visual interface for viewing information about Java applications";
longDescription = ''
VisualVM is a visual tool integrating several commandline JDK
tools and lightweight profiling capabilities. Designed for both
production and development time use, it further enhances the
capability of monitoring and performance analysis for the Java
SE platform.
'';
2019-10-12 00:13:45 +00:00
homepage = "https://visualvm.github.io";
2016-08-15 03:45:48 +00:00
license = licenses.gpl2ClasspathPlus;
platforms = platforms.all;
2018-04-18 02:01:39 +00:00
maintainers = with maintainers; [ michalrus moaxcp ];
2016-08-15 03:45:48 +00:00
};
}