nixpkgs-suyu/pkgs/development/tools/analysis/jdepend/default.nix
volth 46420bbaa3 treewide: name -> pname (easy cases) (#66585)
treewide replacement of

stdenv.mkDerivation rec {
  name = "*-${version}";
  version = "*";

to pname
2019-08-15 13:41:18 +01:00

35 lines
946 B
Nix

{ stdenv, fetchFromGitHub, ant, jdk, runtimeShell }:
stdenv.mkDerivation rec {
pname = "jdepend";
version = "2.9.1";
src = fetchFromGitHub {
owner = "clarkware";
repo = "jdepend";
rev = version;
sha256 = "1sxkgj4k4dhg8vb772pvisyzb8x0gwvlfqqir30ma4zvz3rfz60p";
};
nativeBuildInputs = [ ant jdk ];
buildPhase = "ant jar";
installPhase = ''
mkdir -p $out/bin $out/share
install dist/${pname}-${version}.jar $out/share
cat > "$out/bin/jdepend" <<EOF
#!${runtimeShell}
exec ${jdk.jre}/bin/java -classpath "$out/share/*" "\$@"
EOF
chmod a+x $out/bin/jdepend
'';
meta = with stdenv.lib; {
description = "Traverses Java class file directories and generates design quality metrics for each Java package";
homepage = http://www.clarkware.com/software/JDepend.html;
license = licenses.bsd3;
platforms = platforms.linux;
maintainers = with maintainers; [ pSub ];
};
}