nixpkgs/pkgs/tools/graphics/pngcheck/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

41 lines
966 B
Nix
Raw Normal View History

{ lib, stdenv, fetchurl, zlib, installShellFiles }:
2014-12-01 16:05:20 +00:00
stdenv.mkDerivation rec {
pname = "pngcheck";
version = "3.0.2";
2014-12-01 16:05:20 +00:00
src = fetchurl {
url = "mirror://sourceforge/png-mng/pngcheck-${version}.tar.gz";
2021-02-05 14:48:13 +00:00
sha256 = "sha256-DX4mLyQRb93yhHqM61yS2fXybvtC6f/2PsK7dnYTHKc=";
2014-12-01 16:05:20 +00:00
};
hardeningDisable = [ "format" ];
2014-12-01 16:05:20 +00:00
postPatch = ''
substituteInPlace $makefile \
--replace "gcc" "$CC"
2021-11-15 06:58:37 +00:00
'';
2014-12-01 16:05:20 +00:00
makefile = "Makefile.unx";
makeFlags = [ "ZPATH=${zlib.static}/lib" ];
2014-12-01 16:05:20 +00:00
nativeBuildInputs = [ installShellFiles ];
2014-12-01 16:05:20 +00:00
buildInputs = [ zlib ];
installPhase = ''
runHook preInstall
install -Dm555 -t $out/bin/ pngcheck
installManPage $pname.1
runHook postInstall
2014-12-01 16:05:20 +00:00
'';
2021-11-15 06:58:37 +00:00
meta = with lib; {
homepage = "https://pmt.sourceforge.net/pngcrush";
2014-12-01 16:05:20 +00:00
description = "Verifies the integrity of PNG, JNG and MNG files";
2021-11-15 06:58:37 +00:00
license = licenses.free;
platforms = platforms.unix;
2021-11-15 06:59:06 +00:00
maintainers = with maintainers; [ starcraft66 ];
2014-12-01 16:05:20 +00:00
};
}