nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 39 lines 995 B view raw
1{ 2 lib, 3 stdenv, 4 makeWrapper, 5 fetchurl, 6 jre, 7}: 8 9stdenv.mkDerivation (finalAttrs: { 10 pname = "cfr"; 11 version = "0.152"; 12 13 src = fetchurl { 14 url = "http://www.benf.org/other/cfr/cfr_${finalAttrs.version}.jar"; 15 sha256 = "sha256-9obo897Td9e8h9IWqQ6elRLfQVbnWwbGVaFmSK6HZbI="; 16 }; 17 18 nativeBuildInputs = [ makeWrapper ]; 19 20 buildCommand = '' 21 jar=$out/share/java/cfr_${finalAttrs.version}.jar 22 install -Dm444 $src $jar 23 makeWrapper ${jre}/bin/java $out/bin/cfr --add-flags "-jar $jar" 24 ''; 25 26 meta = { 27 description = "Another java decompiler"; 28 mainProgram = "cfr"; 29 longDescription = '' 30 CFR will decompile modern Java features - Java 8 lambdas (pre and post 31 Java beta 103 changes), Java 7 String switches etc, but is written 32 entirely in Java 6. 33 ''; 34 homepage = "http://www.benf.org/other/cfr/"; 35 sourceProvenance = with lib.sourceTypes; [ binaryBytecode ]; 36 license = lib.licenses.mit; 37 platforms = lib.platforms.all; 38 }; 39})