nixpkgs/pkgs/applications/misc/procmail/default.nix

29 lines
802 B
Nix
Raw Normal View History

{ stdenv, fetchurl }:
stdenv.mkDerivation {
name = "procmail-3.22";
buildInputs = [ stdenv.cc.libc ];
# getline is defined differently in glibc now. So rename it.
installPhase = "
mkdir -p \$out/bin
sed -e \"s%^RM.*$%RM=`type -f rm | awk '{print $3;}'` -f%\" -i Makefile
sed -e \"s%^BASENAME.*%\BASENAME=$out%\" -i Makefile
sed -e \"s%^LIBS=.*%LIBS=-lm%\" -i Makefile
sed -e \"s%getline%thisgetline%g\" -i src/*.c src/*.h
make DESTDIR=\$out install
";
2015-03-03 07:39:54 +00:00
phases = "unpackPhase patchPhase installPhase";
patches = [ ./CVE-2014-3618.patch ];
src = fetchurl {
url = ftp://ftp.fu-berlin.de/pub/unix/mail/procmail/procmail-3.22.tar.gz;
sha256 = "05z1c803n5cppkcq99vkyd5myff904lf9sdgynfqngfk9nrpaz08";
};
2015-02-26 11:33:24 +00:00
meta.homepage = "http://www.procmail.org/";
}