Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at fix-function-merge 45 lines 1.1 kB view raw
1{ lib 2, stdenv 3, fetchzip 4, makeWrapper 5, jre 6}: 7 8stdenv.mkDerivation rec { 9 pname = "jacoco"; 10 version = "0.8.12"; 11 12 src = fetchzip { 13 url = "https://search.maven.org/remotecontent?filepath=org/jacoco/jacoco/${version}/jacoco-${version}.zip"; 14 stripRoot = false; 15 sha256 = "sha256-7bN68fcUycehJDJeBAyCloz8rb3SXgjwmC9zpob8YdI="; 16 }; 17 18 outputs = [ "out" "doc" ]; 19 20 nativeBuildInputs = [ makeWrapper ]; 21 22 installPhase = '' 23 runHook preInstall 24 25 mkdir -p $doc/share/doc $out/bin 26 27 cp -r doc $doc/share/doc/jacoco 28 install -Dm444 lib/* -t $out/share/java 29 30 makeWrapper ${jre}/bin/java $out/bin/jacoco \ 31 --add-flags "-jar $out/share/java/jacococli.jar" 32 33 runHook postInstall 34 ''; 35 36 meta = with lib; { 37 description = "Free code coverage library for Java"; 38 mainProgram = "jacoco"; 39 homepage = "https://www.jacoco.org/jacoco"; 40 changelog = "https://www.jacoco.org/jacoco/trunk/doc/changes.html"; 41 license = licenses.epl20; 42 platforms = platforms.all; 43 maintainers = with maintainers; [ figsoda ]; 44 }; 45}