2016-12-01 01:30:52 +01:00
|
|
|
{ stdenv, fetchurl, fetchpatch
|
2016-04-29 13:39:28 +02:00
|
|
|
, linkStatic ? (stdenv.system == "i686-cygwin")
|
|
|
|
}:
|
2011-12-12 18:06:31 +01:00
|
|
|
|
2016-04-29 13:39:28 +02:00
|
|
|
stdenv.mkDerivation rec {
|
2011-12-12 18:06:31 +01:00
|
|
|
name = "bzip2-${version}";
|
2016-04-29 13:39:28 +02:00
|
|
|
version = "1.0.6.0.1";
|
2010-10-07 15:14:25 +02:00
|
|
|
|
2016-04-29 13:39:28 +02:00
|
|
|
/* We use versions patched to use autotools style properly,
|
|
|
|
saving lots of trouble. */
|
2003-11-04 09:36:32 +01:00
|
|
|
src = fetchurl {
|
2016-04-29 13:39:28 +02:00
|
|
|
urls = map
|
|
|
|
(prefix: prefix + "/people/sbrabec/bzip2/tarballs/${name}.tar.gz")
|
|
|
|
[
|
|
|
|
"http://ftp.uni-kl.de/pub/linux/suse"
|
|
|
|
"ftp://ftp.hs.uni-hamburg.de/pub/mirrors/suse"
|
|
|
|
"ftp://ftp.mplayerhq.hu/pub/linux/suse"
|
|
|
|
"http://ftp.suse.com/pub" # the original patched version but slow
|
|
|
|
];
|
|
|
|
sha256 = "0b5b5p8c7bslc6fslcr1nj9136412v3qcvbg6yxi9argq9g72v8c";
|
2003-11-04 09:36:32 +01:00
|
|
|
};
|
2006-10-25 00:40:33 +02:00
|
|
|
|
2016-12-01 01:30:52 +01:00
|
|
|
patches = [
|
|
|
|
./CVE-2016-3189.patch
|
|
|
|
];
|
|
|
|
|
|
|
|
|
2016-02-11 13:56:38 +01:00
|
|
|
postPatch = ''
|
2016-04-29 13:39:28 +02:00
|
|
|
sed -i -e '/<sys\\stat\.h>/s|\\|/|' bzip2.c
|
2015-11-17 16:16:14 +01:00
|
|
|
'';
|
2010-12-06 18:48:52 +01:00
|
|
|
|
2016-12-01 01:30:52 +01:00
|
|
|
|
2016-08-29 02:30:01 +02:00
|
|
|
outputs = [ "bin" "dev" "out" "man" ];
|
2009-11-08 01:32:12 +01:00
|
|
|
|
2016-04-29 13:39:28 +02:00
|
|
|
configureFlags =
|
|
|
|
stdenv.lib.optionals linkStatic [ "--enable-static" "--disable-shared" ];
|
2010-10-07 15:14:25 +02:00
|
|
|
|
2008-01-31 11:11:09 +01:00
|
|
|
meta = {
|
2010-10-07 15:14:09 +02:00
|
|
|
homepage = "http://www.bzip.org";
|
2016-06-20 12:53:46 +02:00
|
|
|
description = "High-quality data compression program";
|
2010-10-07 15:14:09 +02:00
|
|
|
|
|
|
|
platforms = stdenv.lib.platforms.all;
|
|
|
|
maintainers = [];
|
2008-01-31 11:11:09 +01:00
|
|
|
};
|
2003-11-04 09:36:32 +01:00
|
|
|
}
|