worldpainter: init at 2.23.2 (#323644)

authored by Arne Keller and committed by GitHub e28794fb d5465afa

+75
+75
pkgs/by-name/wo/worldpainter/package.nix
··· 1 + { 2 + lib, 3 + stdenv, 4 + fetchurl, 5 + jre, 6 + makeWrapper, 7 + makeDesktopItem, 8 + copyDesktopItems, 9 + gnused, 10 + }: 11 + stdenv.mkDerivation rec { 12 + pname = "worldpainter"; 13 + version = "2.23.2"; 14 + 15 + src = fetchurl { 16 + url = "https://www.worldpainter.net/files/${pname}_${version}.tar.gz"; 17 + hash = "sha256-FhrfI2/mBeIZAg26Q8x8T2YU2ANwAkoC3h9Tgw6ggoY="; 18 + }; 19 + 20 + nativeBuildInputs = [ 21 + makeWrapper 22 + copyDesktopItems 23 + gnused 24 + ]; 25 + 26 + outputs = [ "out" ]; 27 + 28 + installPhase = '' 29 + runHook preInstall 30 + mkdir -p $out/{bin,lib,.install4j/user} 31 + 32 + install -Dm644 bin/* "$out/bin/" 33 + install -Dm644 lib/* "$out/lib/" 34 + install -Dm644 *.vmoptions "$out/" 35 + install -Dm755 worldpainter "$out/bin" 36 + install -Dm755 wpscript "$out/bin" 37 + find .install4j/ -maxdepth 1 -type f -exec install -Dm644 {} "$out/.install4j/" \; 38 + find .install4j/user/ -maxdepth 1 -type f -exec install -Dm644 {} "$out/.install4j/user/" \; 39 + 40 + mkdir -p $out/share/{pixmaps,applications} 41 + install -Dm644 .install4j/i4j_extf_8_jed6s0_1y6kkxa.png "$out/share/pixmaps/worldpainter.png" 42 + runHook postInstall 43 + ''; 44 + 45 + postInstall = '' 46 + sed -i 's/app_home=\./app_home=../' $out/bin/worldpainter 47 + sed -i 's/app_home=\./app_home=../' $out/bin/wpscript 48 + wrapProgram $out/bin/worldpainter --prefix PATH : "${jre}/bin" 49 + wrapProgram $out/bin/wpscript --prefix PATH : "${jre}/bin" 50 + ''; 51 + 52 + desktopItems = [ 53 + (makeDesktopItem { 54 + name = pname; 55 + desktopName = pname; 56 + exec = pname; 57 + icon = pname; 58 + terminal = false; 59 + type = "Application"; 60 + startupWMClass = pname; 61 + comment = "Paint your own Minecraft worlds"; 62 + categories = [ "Game" ]; 63 + }) 64 + ]; 65 + 66 + meta = { 67 + homepage = "https://www.worldpainter.net/"; 68 + description = "Interactive map generator for Minecraft"; 69 + longDescription = "WorldPainter is an interactive map generator for Minecraft. It allows you to \"paint\" landscapes using similar tools as a regular paint program. Sculpt and mould the terrain, paint materials, trees, snow and ice, etc. onto it, and much more"; 70 + license = with lib.licenses; [ gpl3 ]; 71 + maintainers = with lib.maintainers; [ eymeric ]; 72 + platforms = lib.platforms.linux; 73 + sourceProvenance = [ lib.sourceTypes.binaryBytecode ]; 74 + }; 75 + }