2012-01-08 19:50:06 +00:00
|
|
|
{ stdenv, fetchurl, zlib, xz }:
|
|
|
|
|
2014-03-12 05:34:42 +00:00
|
|
|
assert !(stdenv ? cross) -> zlib != null;
|
2012-01-08 19:50:06 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2014-03-13 21:32:17 +00:00
|
|
|
name = "libpng-1.2.51";
|
2012-01-08 19:50:06 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "mirror://sourceforge/libpng/${name}.tar.xz";
|
2014-03-13 21:32:17 +00:00
|
|
|
sha256 = "0jkdlmnvn72jwm94dp98pznm9fy7alvcr2zpfh2dgbr2n09vimy7";
|
2012-01-08 19:50:06 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [ zlib ];
|
|
|
|
|
2012-12-28 18:20:09 +00:00
|
|
|
nativeBuildInputs = [ xz ];
|
2012-01-08 19:50:06 +00:00
|
|
|
|
|
|
|
passthru = { inherit zlib; };
|
|
|
|
|
2014-03-12 05:34:42 +00:00
|
|
|
crossAttrs = stdenv.lib.optionalAttrs (stdenv.cross.libc == "libSystem") {
|
|
|
|
propagatedBuildInputs = [];
|
|
|
|
passthru = {};
|
|
|
|
};
|
|
|
|
|
2014-04-01 00:37:10 +01:00
|
|
|
configureFlags = "--enable-static";
|
|
|
|
|
2012-01-08 19:50:06 +00:00
|
|
|
meta = {
|
|
|
|
description = "The official reference implementation for the PNG file format";
|
|
|
|
homepage = http://www.libpng.org/pub/png/libpng.html;
|
2014-09-21 18:53:20 +01:00
|
|
|
license = stdenv.lib.licenses.libpng;
|
|
|
|
maintainers = with stdenv.lib.maintainers; [ fuuzetsu ];
|
2014-09-30 10:07:09 +01:00
|
|
|
branch = "1.2";
|
2012-01-08 19:50:06 +00:00
|
|
|
};
|
|
|
|
}
|