Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 fetchurl, 4 makeWrapper, 5 perl, 6 perlPackages, 7 stdenv, 8}: 9 10stdenv.mkDerivation (finalAttrs: { 11 pname = "imapsync"; 12 version = "2.290"; 13 14 src = fetchurl { 15 url = "https://imapsync.lamiral.info/dist/old_releases/${finalAttrs.version}/imapsync-${finalAttrs.version}.tgz"; 16 hash = "sha256-uFhTxnaUDP793isfpF/7T8d4AnXDL4uN6zU8igY+EFE="; 17 }; 18 19 postPatch = '' 20 sed -i -e s@/usr@$out@ Makefile 21 substituteInPlace INSTALL.d/prerequisites_imapsync --replace "PAR::Packer" "" 22 ''; 23 24 postInstall = '' 25 wrapProgram $out/bin/imapsync --set PERL5LIB $PERL5LIB 26 ''; 27 28 nativeBuildInputs = [ makeWrapper ]; 29 30 buildInputs = with perlPackages; [ 31 Appcpanminus 32 CGI 33 CryptOpenSSLRSA 34 DataUniqid 35 DistCheckConflicts 36 EncodeIMAPUTF7 37 FileCopyRecursive 38 FileTail 39 IOSocketINET6 40 IOTee 41 JSONWebToken 42 LWP 43 MailIMAPClient 44 ModuleImplementation 45 ModuleScanDeps 46 NetServer 47 NTLM 48 PackageStash 49 PackageStashXS 50 ProcProcessTable 51 Readonly 52 RegexpCommon 53 SysMemInfo 54 TermReadKey 55 TestDeep 56 TestFatal 57 TestMockGuard 58 TestMockObject 59 TestPod 60 TestRequires 61 UnicodeString 62 perl 63 ]; 64 65 meta = with lib; { 66 description = "Mail folder synchronizer between IMAP servers"; 67 mainProgram = "imapsync"; 68 homepage = "https://imapsync.lamiral.info/"; 69 license = licenses.nlpl; 70 maintainers = with maintainers; [ 71 pSub 72 motiejus 73 ]; 74 platforms = platforms.unix; 75 }; 76})