From 89f690790ae8638042a450a94d22d9bd94fd72d1 Mon Sep 17 00:00:00 2001 From: Emily Trau Date: Mon, 1 Aug 2022 03:10:32 +1000 Subject: [PATCH] stegsolve: init at 1.3 --- pkgs/tools/graphics/stegsolve/default.nix | 47 +++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 49 insertions(+) create mode 100644 pkgs/tools/graphics/stegsolve/default.nix diff --git a/pkgs/tools/graphics/stegsolve/default.nix b/pkgs/tools/graphics/stegsolve/default.nix new file mode 100644 index 000000000000..56ad908d41a2 --- /dev/null +++ b/pkgs/tools/graphics/stegsolve/default.nix @@ -0,0 +1,47 @@ +{ lib, stdenv, fetchurl, jre, makeWrapper, copyDesktopItems, makeDesktopItem }: + +stdenv.mkDerivation rec { + pname = "stegsolve"; + version = "1.3"; + + src = fetchurl { + # No versioned binary is published :( + url = "http://www.caesum.com/handbook/Stegsolve.jar"; + sha256 = "0np5zb28sg6yzkp1vic80pm8iiaamvjpbf5dxmi9kwvqcrh4jyq0"; + }; + + dontUnpack = true; + + desktopItems = [ + (makeDesktopItem { + type = "Application"; + name = pname; + desktopName = "Stegsolve"; + comment = "A steganographic image analyzer, solver and data extractor for challanges"; + exec = pname; + categories = [ "Graphics" ]; + }) + ]; + + nativeBuildInputs = [ makeWrapper copyDesktopItems ]; + + installPhase = '' + runHook preInstall + + export JAR=$out/share/java/stegsolve/stegsolve.jar + install -D $src $JAR + makeWrapper ${jre}/bin/java $out/bin/stegsolve \ + --add-flags "-jar $JAR" + + runHook postInstall + ''; + + meta = with lib; { + description = "A steganographic image analyzer, solver and data extractor for challanges"; + homepage = "http://www.caesum.com/handbook/stego.htm"; + sourceProvenance = with sourceTypes; [ binaryBytecode ]; + license = licenses.unfree; + maintainers = with maintainers; [ emilytrau ]; + platforms = platforms.all; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index eb54ec331072..09f8a37c07a0 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -21263,6 +21263,8 @@ with pkgs; stb = callPackage ../development/libraries/stb { }; + stegsolve = callPackage ../tools/graphics/stegsolve { }; + StormLib = callPackage ../development/libraries/StormLib { }; stxxl = callPackage ../development/libraries/stxxl { };