From f82d27593c58b56ce8dd2d34085171eb281e3b8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Llu=C3=ADs=20Batlle=20i=20Rossell?= Date: Mon, 15 Jun 2009 18:37:42 +0000 Subject: [PATCH] Adding imapsync, with the two needed perl packages. svn path=/nixpkgs/trunk/; revision=15967 --- pkgs/tools/networking/imapsync/default.nix | 24 ++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 5 +++-- pkgs/top-level/perl-packages.nix | 17 +++++++++++++++ 3 files changed, 44 insertions(+), 2 deletions(-) create mode 100644 pkgs/tools/networking/imapsync/default.nix diff --git a/pkgs/tools/networking/imapsync/default.nix b/pkgs/tools/networking/imapsync/default.nix new file mode 100644 index 00000000000..c2c1320988a --- /dev/null +++ b/pkgs/tools/networking/imapsync/default.nix @@ -0,0 +1,24 @@ +{stdenv, fetchurl, perl, openssl, MailIMAPClient}: + +stdenv.mkDerivation rec { + name = "imapsync-1.267"; + src = fetchurl { + url = http://www.linux-france.org/prj/imapsync/dist/imapsync-1.267.tgz; + sha256 = "0h9np2b4bdfnhn10cqkw66fki26480w0c8m3bxw0p76xkaggywdy"; + }; + patchPhase = '' + sed -i -e s@/usr@$out@ Makefile + ''; + + postInstall = '' + # Add Mail::IMAPClient to the runtime search path. + substituteInPlace $out/bin/imapsync --replace '/bin/perl' '/bin/perl -I${MailIMAPClient}/lib/perl5/site_perl'; + ''; + buildInputs = [perl openssl MailIMAPClient]; + + meta = { + homepage = "http://www.linux-france.org/prj/imapsync/"; + description = "Mail folder synchronizer between IMAP servers"; + license = "GPLv2+"; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index a265309db02..99c6a5649b7 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -859,8 +859,9 @@ let inherit fetchurl stdenv bison flex; }; - idutils = import ../tools/misc/idutils { - inherit fetchurl stdenv emacs; + imapsync = import ../tools/networking/imapsync { + inherit fetchurl stdenv perl openssl; + inherit (perlPackages) MailIMAPClient; }; inetutils = import ../tools/networking/inetutils { diff --git a/pkgs/top-level/perl-packages.nix b/pkgs/top-level/perl-packages.nix index 57a453dddcc..a8e56436e44 100644 --- a/pkgs/top-level/perl-packages.nix +++ b/pkgs/top-level/perl-packages.nix @@ -1256,6 +1256,15 @@ rec { propagatedBuildInputs = [URI HTMLParser HTMLTagset]; }; + MailIMAPClient = buildPerlPackage { + name = "Mail-IMAPClient-2.2.9"; + src = fetchurl { + url = mirror://cpan/authors/id/D/DJ/DJKERNEN/Mail-IMAPClient-2.2.9.tar.gz; + sha256 = "1jb04mn66d6022xjqmax49cdn55f2fdzp6knfnchmrcmf90a8rzs"; + }; + buildInputs = [ParseRecDescent]; + }; + MailTools = buildPerlPackage { name = "MailTools-2.04"; src = fetchurl { @@ -1396,6 +1405,14 @@ rec { }; }; + ParseRecDescent = buildPerlPackage { + name = "ParseRecDescent-1.96.0"; + src = fetchurl { + url = mirror://cpan/authors/id/D/DC/DCONWAY/Parse-RecDescent-1.96.0.tar.gz; + sha256 = "1hnsnpzdwcwpbnsspaz55gx7x7h1rpxdk7k1ninnqk1jximl3y9n"; + }; + }; + PathClass = buildPerlPackage { name = "Path-Class-0.16"; src = fetchurl {